pint.fitter
Objects for managing the procedure of fitting models to TOAs.
The objects defined here can be used to set up a fitting problem and carry out the fit, adjust the model, and repeat the fit as necessary.
The primary objects of interest will be pint.fitter.WLSFitter
for
basic fitting, pint.fitter.GLSFitter
for fitting with noise models
that imply correlated errors, and pint.fitter.WidebandTOAFitter
for
TOAs that contain DM information. However, the Downhill fitter variants may offer better convergence.
Fitters in use:
>>> fitter = WLSFitter(toas, model)
>>> fitter.fit_toas()
59.57431562376629118
>>> fitter.print_summary()
Fitted model using weighted_least_square method with 5 free parameters to 62 TOAs
Prefit residuals Wrms = 1090.5802622239905 us, Postfit residuals Wrms = 21.182038012901092 us
Chisq = 59.574 for 56 d.o.f. for reduced Chisq of 1.064
PAR Prefit Postfit Units
=================== ==================== ============================ =====
PSR 1748-2021E None
EPHEM DE421 None
UNITS TDB None
START 53478.3 d
FINISH 54187.6 d
POSEPOCH 53750 d
PX 0 mas
RAJ 17h48m52.75s 17h48m52.8003s +/- 0.00014 hourangle_second
DECJ -20d21m29s -20d21m29.3833s +/- 0.033 arcsec
PMRA 0 mas / yr
PMDEC 0 mas / yr
F0 61.4855 61.485476554373(18) Hz
F1 -1.181e-15 -1.1813(14)x10-15 Hz / s
PEPOCH 53750 d
CORRECT_TROPOSPHERE N None
PLANET_SHAPIRO N None
NE_SW 0 1 / cm3
SWM 0
DM 223.9 224.114(35) pc / cm3
DM1 0 pc / (cm3 yr)
TZRMJD 53801.4 d
TZRSITE 1 None
TZRFRQ 1949.61 MHz
Derived Parameters:
Period = 0.01626400340437608 s +/- 4.784091376048965e-15 s
Pdot = 3.1248325489308735e-19 +/- 3.8139606793005067e-22
Characteristic age = 8.246e+08 yr (braking index = 3)
Surface magnetic field = 2.28e+09 G
Magnetic field at light cylinder = 4806 G
Spindown Edot = 2.868e+33 erg / s (I=1e+45 cm2 g)
To automatically select a fitter based on the properties of the data and model:
>>> fitter = Fitter.auto(toas, model)
Classes
|
Abstract base class for downhill fitters. |
|
Fitter that uses the shortening-step procedure for GLS fits. |
|
Fitter that uses the shortening-step procedure for WLS fits. |
|
Base class for objects encapsulating fitting problems. |
|
Generalized least-squares fitting. |
|
|
|
|
|
Record a model state and cache calculations |
|
A fitter that demonstrates how to work with a generic fitting function. |
|
Weighted Least Squares fitter. |
|
|
|
Fitter that uses the shortening-step procedure for wideband GLS fits. |
|
Fitter for wideband data based on Levenberg-Marquardt. |
|
|
|
A class to for fitting TOAs and other independent measured data. |