Skip to content

Commit

Permalink
fix pathological transit depth case
Browse files Browse the repository at this point in the history
  • Loading branch information
Laura Kreidberg authored and Laura Kreidberg committed Nov 25, 2017
1 parent c37f44e commit e3caa93
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion c_src/common.h
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,8 @@ void calc_limb_darkening(double* f_array, double* d_array, int N, double rprs, d
double x_in = MAX(d - rprs, 0.); //lower bound for integration
double x_out = MIN(d + rprs, 1.0); //upper bound for integration

if(x_in >= 1.) f_array[i] = 1.0; //flux = 1. if the planet is not transiting
if(x_in >= 1.) f_array[i] = 1.0; //flux = 1. if the planet is not transiting
else if(x_out - x_in < 1.e-7) f_array[i] = 1.0; //pathological case
else
{
double delta = 0.; //variable to store the integrated intensity, \int I dA
Expand Down

0 comments on commit e3caa93

Please sign in to comment.