Fitting Light Curves
A C-program called transit will simulate a lightcurve based on input parameters for both a planet orbiting a star or an eclipsing binary star system including blends. Duane is in the process of writing a program that will simulate a planet transit in an eclipsing binary system.
To run the transit.c program, you will need a directory with the transit.c code and a lightcurve from the 40" or APT data. The program will call on this file and use the times (JD) to make a new lc.
Within the astro directory, type idl (idl is on astro only)
For a planet transit
syncurve, R1=#, R2=#, M1=#, M2=#, inc=#, P=#, Tc=#, RMS=#, limb=#, seclimb=#,
F=#, binary=#, Tratio=#, input='name.lc', output='new_name.lc'
M1 = Mass of star (in Solar units)
M2 = Mass of planet (in Jupiter units)
R1 = Radius of star (in Solar units)
R2 = Radius of planet (in Jupiter units)
P = Period in days
inc = Orbital inclination in degrees
Tc = Transit centre in JD
RMS = Noise in mmag
limb = Limb darkening coefficient of main body (between 0 and 1)
seclimb = Limb darkening coefficient of secondary body (between 0 and 1)
F = flux relative to flux of binary (0 for nothing, 1 for second star of equal flux in aperture, etc).
binary = 1 for EB, 0 for planet (default is 0 for planet)
Tratio = Ratio of secondary to primary (0 equiv to planet) 0 < Tratio < # (default is one)
For EC, secondary star will transit first.
If you do not input these parameters, it will plot using default parameters and a default .lc file.
The new .lc file must then be copied to TheMachine so flc and myplot can be used.
Defaults (if you simply run syncurve, input='name.lc', output='new_name.lc', it will use the defaults)
Ms = 1
Mp = 1
Rs = 1
Rp = 1
P = 1
inc = 90
Tc = First JD of night
RMS = Noise in file
limb = 0.5
F = 0
Old Code
emacs the transit.c file and change the parameters to what you want
(keeping in mind what parameters a physical planet would have (eg Rp < 13.5).
Run make transit. This compiles C the program to be run
Run ./transit tin=00010.lc > new_lc_name.lc This will use the times from the 00010.lc
(or whatever name it has) and make a new lc file with the new name you give it.
Run flc new_name This will bring up a lightcurve just as in the APT data.
The new name must be a 5 digit number. If the first digit is 0, just put the last 4 digits.
syncurve, R1=0.29, R2=0.1272, M1=0.31, M2=0.05233, inc=90, P=5.366, limb=0.3, output='00100.lc'
