    ## Fit exponential decay functions

Purpose
Description
Tips
Macro Synopsis
Modules
Related Functions
References

### Purpose

Marquardt-Levenberg fitting to exponential functions

### Description

"Fit exponential decay functions" performs a nonlinear fitting of the given signal to a sum of two exponential functions of the form by using nonlinear Marquardt-Levenberg optimization. It is necessary to give starting values that can either be fitted or held fixed.

If at least one parameter is to be fitted, the progress of the fitting can be observed in the Dataplore ® message window, where the current estimations of the parameters are displayed.

The signal returned from this function corresponds to the fitting function with parameters that give the best fit for the input singal.

This function takes either one or two signals as input; if two signals are given, the second one is used as a weighting function consisting of the individual standard deviations of the input signal samples. Note that both signals must be equal in size, scale and shift.

Otherwise, if a single signal is given, all signal samples are weighted equally.

Parameters of "Fit exponential decay functions" are

• the offset, corresponding to • a flag denoting if the offset is to be fitted (1) or to be held fixed (0)
• the first coefficient a
• a flag denoting if a is to be fitted (1) or to be held fixed (0)
• the second coefficient b
• a flag denoting if b is to be fitted (1) or to be held fixed(0)
• the first time constant tau1
• a flag denoting if tau1 is to be fitted (1) or to be held fixed (0)
• the second time constant tau2
• a flag denoting if tau2 is to be fitted (1) or to be held fixed (0).

If fitting flags are omitted, Dataplore ® defaults to fit(1) the corresponding values.

### Tips

In order to achieve satisfying fitting results, try to give start parameters that are not too far away from the expected resulting values. To that end, you can try to successively fit single parameters while holding fixed other parameters whose estimations already seem to be good enough.

### Macro Synopsis

y = ExpDecFit(x,offset,a,aflag,b,bflag,tau1,tau1flag,tau2,tau2flag);
y = ExpDecFit([x,weight],offset,a,aflag,b,bflag,tau1,tau1flag,tau2,tau2flag);
signal x,y,weight;
int order;
string offset,a,aflag,b,bflag,tau1,tau1flag,tau2,tau2flag;

Note that x can be a standard or an XY plot signal.

Statistics

### Related Functions

Fit Boltzmann functions, Fit Bradley model, Fit Chapman model, Fit Gunary model, Fit Farazdaghi-Harris model, Fit Hill functions, Fit hyperbola functions, Fit logarithm function, Fit logistic functions, Fit Lorentz functions, Fit monomolecular growth model, Fit Nelder model, Fit Pareto functions, Fit polynomial functions, Fit ratio of polynomial functions, Fit Richards growth model, Fit sine functions, Fit damped sine functions, Fit Weibull functions

Marquardt