stella.math
Class ParabolicExtrapolation

java.lang.Object
  extended by stella.math.Extrapolation
      extended by stella.math.ParabolicExtrapolation

public class ParabolicExtrapolation
extends Extrapolation

Uses parabolic extrapolation to predict STELLA-sensor data.


Nested Class Summary
static class ParabolicExtrapolation.StepTest
          Test class for stepping forward and backward.
 
Field Summary
private static int DEGREE
          The degree of the extrapolation polynom.
 
Fields inherited from class stella.math.Extrapolation
extrapolate, sum, yk, yk2sum
 
Constructor Summary
ParabolicExtrapolation()
          Constructs a new linear extrapolation object.
ParabolicExtrapolation(double[] data)
          Constructs a new linear extrapolation object.
 
Method Summary
protected  Polynom calcPolynom()
          Calculates the extrapolating polynom.
 double getChi2()
          Calculates the discrepancy as the sum of the squared residuals.
protected  Polynom updatePolynom()
          Calculates the extrapolating polynom assuming that all values and sums are in a coherent state.
 
Methods inherited from class stella.math.Extrapolation
calcSum, getN, getPolynom, predict, setData, shiftBackward, shiftForward
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEGREE

private static final int DEGREE
The degree of the extrapolation polynom.

See Also:
Constant Field Values
Constructor Detail

ParabolicExtrapolation

public ParabolicExtrapolation()
Constructs a new linear extrapolation object. Use Extrapolation.setData(double[]) to set the measurements.


ParabolicExtrapolation

public ParabolicExtrapolation(double[] data)
Constructs a new linear extrapolation object. The measurements are immediately set.

Method Detail

calcPolynom

protected Polynom calcPolynom()
Calculates the extrapolating polynom. To calculate the partial sums, the Extrapolation.calcSum(int) method of the abstract parent class is used.

Specified by:
calcPolynom in class Extrapolation

updatePolynom

protected Polynom updatePolynom()
Calculates the extrapolating polynom assuming that all values and sums are in a coherent state.

Specified by:
updatePolynom in class Extrapolation

getChi2

public double getChi2()
Calculates the discrepancy as the sum of the squared residuals.

Specified by:
getChi2 in class Extrapolation
Returns:
-1. if invalid.