You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Make sure to enforce that t1 and t2 are floats other wise you get inaccurate results
def planck_taper(tlist, t1, t2):
"""tlist: array of times
t1. for t<=t1 then return 0
t2. for t>=t2 then return 1
else return 1./(np.exp((t2-t1)/(t-t1)+(t2-t1)/(t-t2))+1)"""
tout = []
for t in tlist:
if t<=t1:
tout.append(0.)
elif t>=t2:
tout.append(1.)
else:
tout.append(1./(exp((t2-t1)/(t-t1)+(t2-t1)/(t-t2))+1))
return asarray(tout)
The text was updated successfully, but these errors were encountered:
Make sure to enforce that t1 and t2 are floats other wise you get inaccurate results
The text was updated successfully, but these errors were encountered: