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

comenv updates

parent 77860a96
No related branches found
No related tags found
No related merge requests found
......@@ -7,7 +7,8 @@ my $args0 = `tbse echo`;
chomp $args0;
#print "Args 0 $args0\n";
my @executables = defined $ARGV[0] ? @ARGV : ('binary_c-ref','binary_c');
my @executables = ('binary_c-ref','binary_c');
my @firstargs = @ARGV;
my %out;
threads::shared::share(%out);
my $n=0;
......@@ -30,29 +31,32 @@ while(1)
);
%out=();
my $args = $args0;
my $extra;
# fix idum
$extra .= ' --idum -'.int(65000*rand()).' ';
# randomize M1, M2, per etc.
my $m1 = randval(0.1,100,1);
$extra .= " --M_1 $m1 ";
$extra .= ' --M_2 '.randval(0.1,$m1,1).' ';
$extra .= ' --orbital_period '.randval(0.1,100,1).' --separation 0 ';
$extra .= ' --metallicity '.randval(1e-4,0.03,1).' ';
my $extra = shift @firstargs;
# common envelope
my $comenv = rand()>0.5 ? 0 : 1;
$extra .= ' --comenv_prescription '.$comenv.' ';
$extra .= ' --alpha_ce '.randval(0.0,5.0,0).' ';
$extra .= ' --lambda_ce '.(rand()>0.5 ? -1 : randval(0,1,0)).' ';
if($comenv == 1)
if(!defined $extra)
{
$extra .= ' --nelemans_gamma '.randval(1,2,0).' --nelemans_n_comenvs 1 ';
}
# fix idum
$extra .= ' --idum -'.int(65000*rand()).' ';
# randomize M1, M2, per etc.
my $m1 = randval(0.1,100,1);
$extra .= " --M_1 $m1 ";
$extra .= ' --M_2 '.randval(0.1,$m1,1).' ';
$extra .= ' --orbital_period '.randval(0.1,100,1).' --separation 0 ';
$extra .= ' --metallicity '.randval(1e-4,0.03,1).' ';
# common envelope
my $comenv = rand()>0.5 ? 0 : 1;
$extra .= ' --comenv_prescription '.$comenv.' ';
$extra .= ' --alpha_ce '.randval(0.0,5.0,0).' ';
$extra .= ' --lambda_ce '.(rand()>0.5 ? -1 : randval(0,1,0)).' ';
if($comenv == 1)
{
$extra .= ' --nelemans_gamma '.randval(1,2,0).' --nelemans_n_comenvs 1 ';
}
}
print "$extra\n";
# append extra args
......
......@@ -14,10 +14,11 @@
todo
tm1,tm2
tn
tscls
lums
GB
check all pointers to original vars
./src/perl/scripts/compare_versions.pl " --idum -60345 --M_1 83.8543 --M_2 2.08927 --orbital_period 14.9016 --separation 0 --metallicity 0.000132728 --comenv_prescription 0 --alpha_ce 1.27633 --lambda_ce 0.406764"
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