File: MPREADME

package info (click to toggle)
mpfit 1.85%2B2017.01.03-4
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, sid, trixie
  • size: 788 kB
  • sloc: python: 126; makefile: 16; sh: 13
file content (118 lines) | stat: -rw-r--r-- 4,116 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118

MPFIT PACKAGE
MARKWARDT IDL PROGRAMS

Craig Markwardt
Craig.Markwardt@gmail.com
22 Nov 2009

The following instructions apply to the MPFIT and TNMIN packages of
functions for curve fitting under IDL, available from the Markwardt
IDL Library.

MPFIT is a set of routines for robust least-squares minimization
(curve fitting), using arbitrary user written IDL functions or
procedures.  MPFIT is based on the well-known and tested MINPACK-1
FORTRAN package of routines available at www.netlib.org.  The relevant
sections of code have been translated almost directly from the FORTRAN
equivalent.

MPFIT functions are designed for consistent usage and have some
special features not found in the standard IDL routines.  MPFIT
functions permit you to fix any function parameters, as well as to set
simple upper and lower parameter bounds.  See the documentation under
PARINFO for instructions on how to use this facility.

When referring to MPFIT in your scientific papers, please cite
the following paper.  You can use the NASA ADS link below to get
a citation in the preferred format for your journal.

   Markwardt, C. B. 2008, "Non-Linear Least Squares Fitting in IDL
     with MPFIT," in proc. Astronomical Data Analysis Software and
     Systems XVIII, Quebec, Canada, ASP Conference Series, Vol. XXX, eds.
     D. Bohlender, P. Dowler & D. Durand (Astronomical Society of the
     Pacific: San Francisco), p. 251-254 (ISBN: 978-1-58381-702-5)
       http://arxiv.org/abs/0902.2850
       Link to NASA ADS: http://adsabs.harvard.edu/abs/2009ASPC..411..251M
       Link to ASP: http://aspbooks.org/a/volumes/table_of_contents/411

Refer to the MPFIT website as:
     http://purl.com/net/mpfit


TNMIN

TNMIN solves general minimization problems (generally not curve
fitting), and has similar features to the MPFIT family of functions.
As of this writing, TNMIN requires the user function to supply
derivatives.


DOWNLOADING

Download new versions of from Craig Markwardt's web page:

http://purl.com/net/mpfit

Program modification dates appear on the web page, which you can
compare agains your own copy.  You can also check the modification
history of the file itself to see how recent it is.

Please see the file INSTALL for installation instructions.


MANIFEST

The following functions are included:

 INSTALL     - installation instructions
 MPREADME    - this file

 MPFIT       - main fitting engine, required for other driver functions
 MPFITFUN    - driver function for 1D function fitting
 MPFIT2DFUN  - driver function for 2D function fitting (images)
 MPCURVEFIT  - drop-in replacement for IDL's CURVEFIT, requires MPFIT
 MPFITEXPR   - driver function for fitting expressions interactively
 MPFITPEAK   - driver function for fitting Gaussian, Lorentzian or Moffat peaks
 MPFIT2DPEAK - driver function for fitting 2D peaks

 GAUSS1      - example 1D gaussian function
 GAUSS1P     - example 2D gaussian *procedure*
 fakedata.sav - example 1D gaussian data 


USAGE

The general theory of curve fitting is beyond the scope of this
document.  However, I can offer you a few suggestions.  First, read
the fitting tutorial found on my web page here:

http://purl.com/net/mpfit

(and click through to the Fitting section).  This should get you
started on the basics of 1D fitting, and in fact 2D fitting too since
the principles are almost the same.

Second, read the documentation!  Each of the program files is
extensively self-documented in their comment headers.  You can either
read the files directly or download the documentation from my web page
in the documentation section.

Finally, don't be afraid to experiment.


RECOMMENDATIONS

There are a lot of fitting functions available, each one optimized for
a specific task.  Allow me to suggest which one to use:

 * For 1D curve fitting, use MPFITFUN;
 * For 2D surface fitting, use MPFIT2DFUN;
 * For existing programs which already use CURVEFIT, use MPCURVEFIT;
 * For general non-linear minimization problems, use TNMIN

The main engine, MPFIT, is required in all cases, since the driver
functions call it.

IDL is a registered trademark of RSI