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

add TZ SN event in comenv : this wasn't previously

picked up.
parent 20857774
No related branches found
No related tags found
No related merge requests found
...@@ -23,7 +23,7 @@ my $diff = "diff --suppress-blank-empty --ignore-trailing-space --ignore-space-c ...@@ -23,7 +23,7 @@ my $diff = "diff --suppress-blank-empty --ignore-trailing-space --ignore-space-c
my $waitkdiff : shared; my $waitkdiff : shared;
$waitkdiff = 0; $waitkdiff = 0;
my $q = robqueue->new( my $q = robqueue->new(
nthreads=>1, nthreads=>4,
command_queue=>0, command_queue=>0,
subr=>\&cfsystem, subr=>\&cfsystem,
prepend_thread_number_to_subroutine => 1 prepend_thread_number_to_subroutine => 1
...@@ -45,8 +45,8 @@ sub cfsystem ...@@ -45,8 +45,8 @@ sub cfsystem
my $events_off = `tbse separation 0 random_systems 1 use_events 0 log_filename /tmp/c_log2.$nthread.ref`; my $events_off = `tbse separation 0 random_systems 1 use_events 0 log_filename /tmp/c_log2.$nthread.ref`;
my $events_off_args = ($events_off=~/(--M_1.*)/)[0]; my $events_off_args = ($events_off=~/(--M_1.*)/)[0];
my $events_off_args = pop(@testsystems); #my $events_off_args = pop(@testsystems);
my $events_off = `tbse separation 0 random_systems 0 use_events 0 log_filename /tmp/c_log2.$nthread.ref $events_off_args | $grep `; #my $events_off = `tbse separation 0 random_systems 0 use_events 0 log_filename /tmp/c_log2.$nthread.ref $events_off_args | $grep `;
my $events_on = `tbse random_systems 0 $events_off_args use_events 1 log_filename /tmp/c_log2.$nthread.dat | $grep `; my $events_on = `tbse random_systems 0 $events_off_args use_events 1 log_filename /tmp/c_log2.$nthread.dat | $grep `;
......
...@@ -848,7 +848,7 @@ int common_envelope_evolution_BSE ( ...@@ -848,7 +848,7 @@ int common_envelope_evolution_BSE (
* If the secondary was a neutron star or black hole the outcome * If the secondary was a neutron star or black hole the outcome
* is an unstable Thorne-Zytkow object that leaves only the core. * is an unstable Thorne-Zytkow object that leaves only the core.
*/ */
//printf("TZ\n");
final_separation = 0.0; final_separation = 0.0;
if(POST_SN_OBJECT(accretor->stellar_type)) if(POST_SN_OBJECT(accretor->stellar_type))
{ {
...@@ -883,6 +883,16 @@ int common_envelope_evolution_BSE ( ...@@ -883,6 +883,16 @@ int common_envelope_evolution_BSE (
donor->age = 0.0; donor->age = 0.0;
donor->stellar_type = MASSLESS_REMNANT; donor->stellar_type = MASSLESS_REMNANT;
#endif #endif
/*
* Set the SN type for ensemble logging, and add a supernova
* event for the log
*/
star1->SN_type = SN_TZ;
struct star_t * news =
new_supernova(stardata,donor,accretor,NULL);
/* /*
* The envelope mass is not required in this case. * The envelope mass is not required in this case.
*/ */
...@@ -2524,7 +2534,7 @@ end_section: ...@@ -2524,7 +2534,7 @@ end_section:
stardata->common.orbit.eccentricity)*1e-6; stardata->common.orbit.eccentricity)*1e-6;
Append_logstring(LOG_COMENV_POST, Append_logstring(LOG_COMENV_POST,
"post-COMENV M=%g(Mc=%g,Menv=%g,st=%d,Teff=%g) + M=%g(Mc=%g,Menv=%g,st=%d,Teff=%g) a_out=%g P_out=%g (%g d) R1=%g RL1=%g (R1/RL1 = %g) R2=%g RL2=%g (R2/RL2 = %g) SN? %d %d Single? %d : merge in %g Gy at t = %g Gy", "post-COMENV M=%g(Mc=%g,Menv=%g,st=%d,Teff=%g) + M=%g(Mc=%g,Menv=%g,st=%d,Teff=%g) a_out=%g P_out=%g (%g d) R1=%g RL1=%g (R1/RL1 = %g) R2=%g RL2=%g (R2/RL2 = %g) SN? %d %d Single? %d : merge in %g Gy at t = %g Gy, events pending? %d",
stardata->star[0].mass, stardata->star[0].mass,
stardata->star[0].core_mass, stardata->star[0].core_mass,
stardata->star[0].mass - stardata->star[0].core_mass, stardata->star[0].mass - stardata->star[0].core_mass,
...@@ -2548,7 +2558,8 @@ end_section: ...@@ -2548,7 +2558,8 @@ end_section:
accretor->SN_type, accretor->SN_type,
System_is_single, System_is_single,
dtmerge*1e-3, dtmerge*1e-3,
(stardata->model.time + dtmerge) * 1e-3 (stardata->model.time + dtmerge) * 1e-3,
events_pending(stardata)
); );
......
...@@ -634,6 +634,7 @@ void nucsyn_gce_log(struct stardata_t * RESTRICT stardata, ...@@ -634,6 +634,7 @@ void nucsyn_gce_log(struct stardata_t * RESTRICT stardata,
supernova_luminous_energy(star); supernova_luminous_energy(star);
break; break;
case SN_TZ: case SN_TZ:
printf("SN TZ ensemble at %g\n",stardata->model.time);
ensemble_weight[NUCSYN_ENSEMBLE_SN_TZ]=1.0; ensemble_weight[NUCSYN_ENSEMBLE_SN_TZ]=1.0;
break; break;
case SN_AIC_BH: case SN_AIC_BH:
......
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