casa  $Rev:20696$
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Member Functions | Protected Member Functions | Private Attributes
casa::NonLinearFitLM< T > Class Template Reference

Solve non-linear fit with Levenberg-Marquardt method.
More...

#include <NonLinearFitLM.h>

Inheritance diagram for casa::NonLinearFitLM< T >:
casa::NonLinearFit< T > casa::GenericL2Fit< T > casa::LSQaips casa::LSQFit

List of all members.

Public Member Functions

 NonLinearFitLM (Bool svd=False)
 Create a fitter: the normal way to generate a fitter object.
 NonLinearFitLM (const NonLinearFitLM &other)
 Copy constructor (deep copy)
NonLinearFitLMoperator= (const NonLinearFitLM &other)
 Assignment (deep copy)
virtual ~NonLinearFitLM ()
 Destructor.

Protected Member Functions

virtual Bool fitIt (Vector< typename FunctionTraits< T >::BaseType > &sol, const Array< typename FunctionTraits< T >::BaseType > &x, const Vector< typename FunctionTraits< T >::BaseType > &y, const Vector< typename FunctionTraits< T >::BaseType > *const sigma, const Vector< Bool > *const mask=0)
 Generalised fitter.

Private Attributes

Double lamda_p
 The parameter that makes this the Levenberg-Marquardt method.
Double fitit_p
 The current fit state.

Detailed Description

template<class T>
class casa::NonLinearFitLM< T >

Solve non-linear fit with Levenberg-Marquardt method.

Review Status

Reviewed By:
wbrouw
Date Reviewed:
2004/06/15
Test programs:
tNonLinearFitLM

Prerequisite

Etymology

This class uses the Levenberg-Marquardt method to solve the non-linear least-squares fit problem hence NonLinearFitLM

Synopsis

NOTE: Constraints added. Documentation out of date at moment, check the tLinearFitSVD and tNonLinearFirLM programs for examples.

See the NonLinearFit class for a general description.

This class is derived from the general NonLinearFit class. It does a non-linear least-squares fit using the Levenberg-Marquardt method.

See Numerical Recipes for more information on the Levenberg-Marquardt method.

Template Type Argument Requirements (T)

Motivation

Levenberg-Marquardt method is a standard method for non-linear least-squares fits. It works well in practice over a wide range of problems.

Example

Definition at line 87 of file NonLinearFitLM.h.


Constructor & Destructor Documentation

template<class T>
casa::NonLinearFitLM< T >::NonLinearFitLM ( Bool  svd = False) [explicit]

Create a fitter: the normal way to generate a fitter object.

Necessary data will be deduced from the Functional provided with setFunction(). Optionally, a fitter with SVD behaviour

template<class T>
casa::NonLinearFitLM< T >::NonLinearFitLM ( const NonLinearFitLM< T > &  other)

Copy constructor (deep copy)

template<class T>
virtual casa::NonLinearFitLM< T >::~NonLinearFitLM ( ) [virtual]

Destructor.


Member Function Documentation

template<class T>
virtual Bool casa::NonLinearFitLM< T >::fitIt ( Vector< typename FunctionTraits< T >::BaseType > &  sol,
const Array< typename FunctionTraits< T >::BaseType > &  x,
const Vector< typename FunctionTraits< T >::BaseType > &  y,
const Vector< typename FunctionTraits< T >::BaseType > *const  sigma,
const Vector< Bool > *const  mask = 0 
) [protected, virtual]

Generalised fitter.

Implements casa::NonLinearFit< T >.

template<class T>
NonLinearFitLM& casa::NonLinearFitLM< T >::operator= ( const NonLinearFitLM< T > &  other)

Assignment (deep copy)


Member Data Documentation

template<class T>
Double casa::NonLinearFitLM< T >::fitit_p [private]

The current fit state.

Definition at line 119 of file NonLinearFitLM.h.

template<class T>
Double casa::NonLinearFitLM< T >::lamda_p [private]

The parameter that makes this the Levenberg-Marquardt method.

Definition at line 117 of file NonLinearFitLM.h.


The documentation for this class was generated from the following file: