Skip to content

Commit

Permalink
Merge branch 'dev' into bands_jm
Browse files Browse the repository at this point in the history
  • Loading branch information
jhmatthews committed Sep 18, 2024
2 parents 187ff5d + 4f5f6e4 commit 08192a9
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 20 deletions.
10 changes: 5 additions & 5 deletions source/parse.c
Original file line number Diff line number Diff line change
Expand Up @@ -154,13 +154,13 @@ parse_command_line (argc, argv)
Log ("Using special relativity for Doppler shifts, etc., and including co-moving frame effects.\n");
j = i;
}
else if (strcmp (argv[i], "-srclassic") == 0)
else if (strcmp (argv[i], "-sr_doppler_only") == 0)
{
rel_mode = REL_MODE_SR_FREQ;
Log ("Using full special relativity only for Doppler shifts, etc., and not considering co-moving frame effects.");
j = i;
}
else if (strcmp (argv[i], "-classic") == 0)
else if (strcmp (argv[i], "-nonrel") == 0)
{
rel_mode = REL_MODE_LINEAR;
Log ("Using only old approach with linear Doppler shifts, etc. and not considering co-moving frame effects.\n");
Expand Down Expand Up @@ -352,7 +352,7 @@ help ()
\n\
This program simulates radiative transfer in a (biconical) CV, YSO, quasar, TDE or (spherical) stellar wind \n\
\n\
Usage: py [-h] [-r] [-t time_max] [-v n] [--dry-run] [-i] [--version] [--rseed] [-p n_steps] [-classic] [-srclassic] xxx or simply py \n\
Usage: py [-h] [-r] [-t time_max] [-v n] [--dry-run] [-i] [--version] [--rseed] [-p n_steps] [-nonrel] [-sr_doppler_only] xxx or simply py \n\
\n\
where xxx is the rootname or full name of a parameter file, e. g. test.pf \n\
\n\
Expand Down Expand Up @@ -387,9 +387,9 @@ These are largely diagnostic or for special cases. These include\n\
Range is in powers of 10, the difference beween the number of photons in the first cycle \n\
compared to the last. If range is missing, range is assumed to be 1, in which case the \n\
number of photons will in the first cycle will be one order of magniude less than in the last cycle \n\
-classic Use Python in its classic configuration, with linear Doppler shifts, etc., and where co-moving frame\n\
-nonrel Use Python in its old non-relativistic configuration, with linear Doppler shifts, etc., and where co-moving frame\n\
effects are not taken into account.\n\
-srclassic Use Python with full special relativity for Doppler shifts, etc., but do not include any co-moving frame\n\
-sr_doppler_only Use Python with full special relativity for Doppler shifts, etc., but do not include any co-moving frame\n\
effects.\n\
-ignore_partial_cells Ignore wind cells that are only partially filled by the wind (This is now the default) \n\
-include_partial_cells Include wind cells that are only partially filled by the wind \n\
Expand Down
8 changes: 4 additions & 4 deletions source/py_optd.c
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,7 @@ print_help (void)
"A utility program to analyse the optical depth in a Python model.\n\n"
"usage: py_optical_depth [-h] [-d ndom] [-p tau_stop] [-cion nion] \n"
" [-freq_min min] [-freq_max max] [-i i1 i2 ...]\n"
" [--classic] [--smax frac] [--no-es] [--version]\n"
" [--nonrel] [--smax frac] [--no-es] [--version]\n"
" root\n\n"
"This program can be used in multiple ways. By default, the integrated continuum\n"
"optical depth along the defined observer lines of sight for the model are returned.\n"
Expand All @@ -360,8 +360,8 @@ print_help (void)
"-freq_min min The lower frequency boundary for optical depth spectra\n"
"-freq_max max The upper frequency boundary for optical depth spectra\n"
"-i i1 i2 i3 ... Calculate the optical depth for the given space seperated list of sight lines\n"
"--classic Use linear frequency transforms, to be used when Python was run\n"
" in classic mode\n"
"--nonrel Use linear frequency transforms, to be used when Python was run\n"
" in non-relativistic mode\n"
"--smax frac Set the maximum fraction a photon can move in terms of cell distances\n"
"--no-es Do not include opacity contributions from electron scattering\n"
"--version Print the version information and exit.\n";
Expand Down Expand Up @@ -426,7 +426,7 @@ get_arguments (int argc, char *argv[])
print_help ();
exit (EXIT_SUCCESS);
}
else if (!strcmp (argv[i], "--classic")) //NOTE: use linear frequency transforms
else if (!strcmp (argv[i], "--nonrel")) //NOTE: use linear frequency transforms
{
printf ("Using linear approximations for Doppler shifts\n");
rel_mode = REL_MODE_LINEAR;
Expand Down
22 changes: 11 additions & 11 deletions source/setup_line_transfer.c
Original file line number Diff line number Diff line change
Expand Up @@ -73,58 +73,58 @@ get_line_transfer_mode ()

if (user_line_mode == LINE_MODE_ABSORB)
{
Log ("Line_transfer mode: Simple, pure absorption, no scattering\n");
Log ("Line_transfer mode: Classic, pure absorption, no scattering\n");
geo.line_mode = user_line_mode;
}
else if (user_line_mode == LINE_MODE_SCAT)
{
Log ("Line_transfer mode: Simple, pure scattering, no absoprtion\n");
Log ("Line_transfer mode: Classic, pure scattering, no absoprtion\n");
geo.line_mode = user_line_mode;
}
else if (user_line_mode == LINE_MODE_SINGLE_SCAT)
{
Log ("Line_transfer mode: Simple, single scattering, with absorption, but without escape probality treatment\n");
Log ("Line_transfer mode: Classic, single scattering, with absorption, but without escape probality treatment\n");
geo.line_mode = user_line_mode;
}
else if (user_line_mode == LINE_MODE_ESC_PROB)
{
Log ("Line_transfer mode: Simple, isotropic scattering, escape probabilities\n");
Log ("Line_transfer mode: Classic, isotropic scattering, escape probabilities\n");
geo.line_mode = user_line_mode;
}
else if (user_line_mode == 5)
{
Log ("Line_transfer mode: Simple, thermal trapping, Single scattering \n");
Log ("Line_transfer mode: Classic, thermal trapping, Single scattering \n");
geo.scatter_mode = SCATTER_MODE_THERMAL; // Thermal trapping model
geo.line_mode = LINE_MODE_ESC_PROB;
geo.rt_mode = RT_MODE_2LEVEL; // Not macro atom (SS)
}
else if (user_line_mode == 6)
{
Log ("Line_transfer mode: macro atoms, isotropic scattering \n");
Log ("Line_transfer mode: Macro, isotropic scattering \n");
geo.scatter_mode = SCATTER_MODE_ISOTROPIC;
geo.line_mode = LINE_MODE_ESC_PROB;
geo.rt_mode = RT_MODE_MACRO; // Identify macro atom treatment (SS)
geo.macro_simple = FALSE; // We don't want the all simple case (SS)
}
else if (user_line_mode == 7)
{
Log ("Line_transfer mode: macro atoms, anisotropic scattering \n");
Log ("Line_transfer mode: Macro, anisotropic scattering \n");
geo.scatter_mode = SCATTER_MODE_THERMAL; // thermal trapping
geo.line_mode = LINE_MODE_ESC_PROB;
geo.rt_mode = RT_MODE_MACRO; // Identify macro atom treatment (SS)
geo.macro_simple = FALSE; // We don't want the all simple case (SS)
}
else if (user_line_mode == 8)
{
Log ("Line_transfer mode: simple macro atoms, isotropic scattering \n");
Log ("Line_transfer mode: Macro, isotropic scattering \n");
geo.scatter_mode = SCATTER_MODE_ISOTROPIC;
geo.line_mode = LINE_MODE_ESC_PROB;
geo.rt_mode = RT_MODE_MACRO; // Identify macro atom treatment i.e. indivisible packets
geo.macro_simple = TRUE; // This is for test runs with all simple ions (SS)
}
else if (user_line_mode == 9)
{
Log ("Line_transfer mode: simple macro atoms, anisotropic scattering \n");
Log ("Line_transfer mode: Macro, anisotropic scattering \n");
geo.scatter_mode = SCATTER_MODE_THERMAL; // thermal trapping
geo.line_mode = LINE_MODE_ESC_PROB;
geo.rt_mode = RT_MODE_MACRO; // Identify macro atom treatment i.e. indivisible packets
Expand Down Expand Up @@ -225,8 +225,8 @@ Available line transfer modes and descriptions are: \n\
8(deprecated) Indivisible energy packets, force all simple-atoms, anisotropic scattering\n\
9(deprecated) Indivisible energy packets, force all simple-atoms, anisotropic scattering\n\
\n\
Standard mode is thermal_trapping for runs involving weight reduction and no macro-atoms\n\
Standard macro-atom mode is macro_atoms_thermal_trapping\n\
Classic mode is thermal_trapping for runs involving weight reduction and no macro-atoms\n\
Hybrid macro-atom mode is macro_atoms_thermal_trapping\n\
\n\
See this web address for more information: https://github.com/agnwinds/python/wiki/Line-Transfer-and-Scattering\n\
\n\
Expand Down

0 comments on commit 08192a9

Please sign in to comment.