vec_math
Class MultipleFrequencyFit.FourierComponents

java.lang.Object
  extended by vec_math.AbstractDataModel
      extended by vec_math.AbstractGradientModel
          extended by vec_math.MultipleFrequencyFit.FourierComponents
All Implemented Interfaces:
DataModel, GradientModel
Enclosing class:
MultipleFrequencyFit

 class MultipleFrequencyFit.FourierComponents
extends AbstractGradientModel


Nested Class Summary
 
Nested classes/interfaces inherited from class vec_math.AbstractDataModel
AbstractDataModel.Construct, AbstractDataModel.LocalM
 
Field Summary
(package private)  int dimension
           
 
Fields inherited from class vec_math.AbstractDataModel
sigma, x, y
 
Constructor Summary
protected MultipleFrequencyFit.FourierComponents(int count, VectorG[] times, double[] y, double[] err)
           
 
Method Summary
 double evaluateModel(VectorG tup3, VectorG x1)
          Evaluates the data model on a single point in the independant parameter space, normally the time.
 Matrix getGradientMatrix(VectorG tup3)
          Returns the gradient of the model for all measures.
 int getParameterCount()
          The number of model parameters should be less than the number of data points in the model, otherwise you fit a underdetermined problem.
 
Methods inherited from class vec_math.AbstractGradientModel
check, check, getNegativeChi2HalfGradient, getNegativeChi2HalfGradient, getPseudoHessian, getPseudoHessian, LevenbergMarquardtSolver
 
Methods inherited from class vec_math.AbstractDataModel
getChiSquareModel, getChiSquareModel, getLorentzianModel, getMeasureCount, getMeasurementErrors, getMeasures, getModel, getModel, getResiduals, getResiduals, getRms, getRobustModel, getTimes, getTotalErrors, LorentzianSolver, RobustSolver, SimplexSolver
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface vec_math.DataModel
getMeasureCount, getMeasurementErrors, getMeasures, getModel, getResiduals, getTimes, getTotalErrors
 

Field Detail

dimension

int dimension
Constructor Detail

MultipleFrequencyFit.FourierComponents

protected MultipleFrequencyFit.FourierComponents(int count,
                                                 VectorG[] times,
                                                 double[] y,
                                                 double[] err)
Method Detail

getParameterCount

public int getParameterCount()
Description copied from interface: DataModel
The number of model parameters should be less than the number of data points in the model, otherwise you fit a underdetermined problem.

Returns:
The number of parameters in the model. This equals the dimension of the input vector in DataModel.getModel(vec_math.VectorG).

evaluateModel

public double evaluateModel(VectorG tup3,
                            VectorG x1)
Description copied from interface: DataModel
Evaluates the data model on a single point in the independant parameter space, normally the time. Note that the model can be evaluated also at times not identically to the measurement times.

Parameters:
tup3 - The model parameters
x1 - The (one)dimensional vector of independant variables.

getGradientMatrix

public Matrix getGradientMatrix(VectorG tup3)
Description copied from interface: GradientModel
Returns the gradient of the model for all measures. The measure index is the row of the Matrix, the columns are the derivatives of the model with respect to the parameters. Thus, the Matrix.columns() equals DataModel.getParameterCount(), and Matrix.rows() equals DataModel.getMeasureCount().