ru.sscc.spline.polynomial
Class OddSplinePreparator
java.lang.Object
|
+--ru.sscc.spline.creator.SmoothingPreparator
|
+--ru.sscc.spline.polynomial.OddSplinePreparator
- public class OddSplinePreparator
- extends SmoothingPreparator
The implementation of SmoothingPreparator for a polynomail
spline of odd degree.
- See Also:
- Serialized Form
Methods inherited from class java.lang.Object |
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
preparator
protected MatrixPreparator preparator
- Preparator used for matrices calculation.
solver
protected CholeskyBandSolver solver
- Solver used for calculation.
OddSplinePreparator
public OddSplinePreparator(SimpleMesh mesh,
int order)
- Constructor.
- Parameters:
mesh
- a mesh of nodesorder
- a difference order
clone
public java.lang.Object clone()
- Returns a nonprepared clone.
- Overrides:
- clone in class SmoothingPreparator
getH
public RectBandedMatrix getH()
- Returns the finite differences' matrix.
prepareSolver
public void prepareSolver(double alpha)
throws CalculatingException
- Prepares a solver (
CholeskyBandSolver
in this case)
for calculations with specified alpha.
The value alpha = Double.POSITIVE_INFINITY is permitted.
- Overrides:
- prepareSolver in class SmoothingPreparator
getSolver
public final CholeskyBandSolver getSolver()
- Returns the solver used in the preparator or null if the solver
is not prepared yet.
solve
public void solve(RealVector values,
RealVector data,
RealVector residual)
- Calculates spline coefficients and smoothing residual
by interpolation values.
- Overrides:
- solve in class SmoothingPreparator
- Parameters:
values
- interpolation values at mesh nodesdata
- a vector to store spline coefficientsresidual
- a vector to store residual (if it is equal to null,
the residual is not needed)
calculationCost
public double calculationCost()
- Returns a number of arithmetic operations needed for
calculation of spline coefficients.
- Overrides:
- calculationCost in class SmoothingPreparator