Search in sources :

Example 1 with ArithmeticProgression

use of org.apache.hadoop.examples.pi.math.ArithmeticProgression in project hadoop by apache.

the class SummationWritable method readFields.

/** {@inheritDoc} */
@Override
public void readFields(DataInput in) throws IOException {
    final ArithmeticProgression N = ArithmeticProgressionWritable.read(in);
    final ArithmeticProgression E = ArithmeticProgressionWritable.read(in);
    sigma = new Summation(N, E);
    if (in.readBoolean()) {
        sigma.setValue(in.readDouble());
    }
}
Also used : Summation(org.apache.hadoop.examples.pi.math.Summation) ArithmeticProgression(org.apache.hadoop.examples.pi.math.ArithmeticProgression)

Aggregations

ArithmeticProgression (org.apache.hadoop.examples.pi.math.ArithmeticProgression)1 Summation (org.apache.hadoop.examples.pi.math.Summation)1