def demo(): planet = Planet(J=0.00, rp_over_rs=0.1, rsum_over_a=1.0/20.0, cosi=0.000, q=0.000, period=1.58, t0=2456000.0, esinw=0.0, ecosw=0.0) star = Star(u1=0.3, u2=0.3, gd=0.32, albedo=0) tm = TM(planet=planet, star=star) (p1, p4, s1, s4) = planet.contacts() print planet.contacts() duration = (p4 - p1 + 1)*planet.period.value t = np.linspace(planet.t0.value - duration, planet.t0.value + duration, 1000) uncertainty = 0.003*np.ones_like(t) tlc = TLC(t, tm.model(t) + np.random.normal(len(t))*uncertainty, uncertainty) tlc.plot()