astro.fits
Class Overscan.WifsipOverscan

java.lang.Object
  extended by vec_math.AbstractDataModel
      extended by vec_math.AbstractGradientModel
          extended by astro.fits.Overscan.WifsipOverscan
All Implemented Interfaces:
PropertyAware, DataModel, GradientModel
Enclosing class:
Overscan

public static class Overscan.WifsipOverscan
extends AbstractGradientModel
implements PropertyAware

A non-linear model for fitting the exponentially glow in WiFSIP data. We use a double-exponential to model the overscan region from pixel row zero to approximately 350. The characteristic fall-off length, the two non-linear parameters in the model, have been fitted on an averaged twenty-second dark over five individual exposures.


Nested Class Summary
 
Nested classes/interfaces inherited from class vec_math.AbstractDataModel
AbstractDataModel.Construct
 
Field Summary
private  int decay
          Number of exponential decays with different tau that overlap.
private static int DEFDECAYCOUNT
          Number of exponential decays overlapping.
static String KEY_DECAYCOUNT
          The number of decaying exp-f we overlay in the non-linear fit.
static String KEY_STARTROW
          If we are not stating at row zero.
private  double start
          Starting row number, zero in most cases.
 
Fields inherited from class vec_math.AbstractDataModel
sigma, x, y
 
Constructor Summary
Overscan.WifsipOverscan(VectorG[] row, double[] aduav, double[] aduerr)
          The array of VectorGs actually only contains the row number of the fit, i.e.
Overscan.WifsipOverscan(VectorG[] row, double[] aduav, double[] aduerr, int exp)
          The array of VectorGs actually only contains the row number of the fit, i.e.
 
Method Summary
 double evaluateModel(VectorG curfit, VectorG t)
          Returns the model adu for the queried row in vector t, which again is a Vector1D, t.a0 = row.
 Matrix getGradientMatrix(VectorG curfit)
          Returns the matrix that is the gradient to the two-exponential model.
 int getParameterCount()
          The number of parameters is fixed to five.
 void setComposedProperties(PropertySupplying prop)
          If we have the KEY_DECAYCOUNT property set, we record the number of exponential decay laws.
 
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

KEY_DECAYCOUNT

public static final String KEY_DECAYCOUNT
The number of decaying exp-f we overlay in the non-linear fit.

See Also:
Constant Field Values

KEY_STARTROW

public static final String KEY_STARTROW
If we are not stating at row zero.

See Also:
Constant Field Values

DEFDECAYCOUNT

private static final int DEFDECAYCOUNT
Number of exponential decays overlapping.

See Also:
Constant Field Values

decay

private int decay
Number of exponential decays with different tau that overlap.


start

private double start
Starting row number, zero in most cases.

Constructor Detail

Overscan.WifsipOverscan

public Overscan.WifsipOverscan(VectorG[] row,
                               double[] aduav,
                               double[] aduerr)
The array of VectorGs actually only contains the row number of the fit, i.e. VectorG[i] = Vector1D.a0=i.


Overscan.WifsipOverscan

public Overscan.WifsipOverscan(VectorG[] row,
                               double[] aduav,
                               double[] aduerr,
                               int exp)
The array of VectorGs actually only contains the row number of the fit, i.e. VectorG[i] = Vector1D.a0=i.

Method Detail

setComposedProperties

public void setComposedProperties(PropertySupplying prop)
If we have the KEY_DECAYCOUNT property set, we record the number of exponential decay laws.

Specified by:
setComposedProperties in interface PropertyAware

getParameterCount

public int getParameterCount()
The number of parameters is fixed to five.

Specified by:
getParameterCount in interface DataModel
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 curfit,
                            VectorG t)
Returns the model adu for the queried row in vector t, which again is a Vector1D, t.a0 = row. The model we fit has the following formular
 ADU(r=row) = a0 + a1*exp(-a3*r) + a2*exp(-a4*r)+...
 
where the number of exponentials that are overlayed is stored in decay

Specified by:
evaluateModel in interface DataModel
Parameters:
curfit - The model parameters
t - The (one)dimensional vector of independant variables.

getGradientMatrix

public Matrix getGradientMatrix(VectorG curfit)
Returns the matrix that is the gradient to the two-exponential model.

Specified by:
getGradientMatrix in interface GradientModel