Skip to content
Snippets Groups Projects
Commit 0f02c4c5 authored by Izzard, Robert Dr (Maths & Physics)'s avatar Izzard, Robert Dr (Maths & Physics)
Browse files

make the rejection test for gaiahrd a bit less strict: this greatly improves...

make the rejection test for gaiahrd a bit less strict: this greatly improves performance and the results are very similar
parent 892a41f0
No related branches found
No related tags found
No related merge requests found
......@@ -119,8 +119,9 @@ void evolution_rejection_tests(struct stardata_t * RESTRICT const stardata)
* When constructing Gaia-like HRDs, do not let
* Teff,L change too quickly
*/
const double max_dL = stardata->preferences->gaia_L_binwidth;
const double max_dTeff = stardata->preferences->gaia_Teff_binwidth;
const double f = 1.99;
const double max_dL = f * stardata->preferences->gaia_L_binwidth;
const double max_dTeff = f * stardata->preferences->gaia_Teff_binwidth;
/*
* Get the next Gaia data
......@@ -148,11 +149,21 @@ void evolution_rejection_tests(struct stardata_t * RESTRICT const stardata)
*/
if(fabs(L - stardata->common.gaia_L) > max_dL)
{
/*
printf("L = %g vs gaia_L = %g : reject lum\n",
L,
stardata->common.gaia_L);
*/
stardata->star[0].reject = REJECT_LUMINOSITY;
reject_HRD = TRUE;
}
else if(fabs(Teff - stardata->common.gaia_Teff) > max_dTeff)
{
/*
printf("Teff = %g vs gaia_Teff = %g : reject Teff\n",
Teff,
stardata->common.gaia_Teff);
*/
stardata->star[0].reject = REJECT_TEFF;
reject_HRD = TRUE;
}
......
......@@ -91,7 +91,18 @@ void gaia_log(struct stardata_t * const stardata,
* L = bin_data(log10(Lgaia),Lbin);
* primary = k;
* do_log = TRUE;
/*
if(0)printf("GAIA Teff = (%g * %g + %g * %g) / %g = %g, L = %g, primary = %d, do_log = %s\n",
stardata->star[0].luminosity,
Teff(0),
stardata->star[1].luminosity,
Teff(1),
Sum(luminosity),
log10(weighted_Teff),
log10(Lgaia),
*primary,
Yesno(*do_log));
*/
}
else
{
......
......@@ -58,7 +58,7 @@ $population->parse_args();
#
# duplicity is 0 for single stars, 1 for binary stars
# and 2 for a mixed population sampled at equal times
my $duplicity = 0;
my $duplicity = 1;
if($duplicity == 0)
{
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment