Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
SWIFT
SWIFTsim
Commits
8266849a
Commit
8266849a
authored
Jan 03, 2019
by
Matthieu Schaller
Browse files
More naming convention improvements in the EAGLE cooling section of the YAML file.
parent
b7e1269e
Changes
11
Hide whitespace changes
Inline
Side-by-side
doc/RTD/source/SubgridModels/EAGLE/index.rst
View file @
8266849a
...
...
@@ -208,19 +208,19 @@ implicit problem. A valid section of the YAML file looks like:
.. code:: YAML
EAGLECooling:
dirname:
/path/to/the/Wiersma/tables/directory # Absolute or relative path
dir
_
name: /path/to/the/Wiersma/tables/directory # Absolute or relative path
H_reion_z: 11.5 # Redhift of Hydrogen re-ionization
He_reion_z_centre: 3.5 # Centre of the Gaussian used for Helium re-ionization
He_reion_z_sigma: 0.5 # Width of the Gaussian used for Helium re-ionization
He_reion_e
v
_pH:
2.0 # Energy injected in eV per Hydrogen atom for Helium re-ionization.
He_reion_e
V
_p
_
H: 2.0 # Energy injected in eV per Hydrogen atom for Helium re-ionization.
T
he optional parameters are:
And t
he optional parameters are:
.. code:: YAML
EAGLECooling:
Ca
lciumO
verSi
liconInSolar:
1.0 # (Optional) Value of the Calcium abundance ratio to solar in units of the Silicon ratio to solar. Default value: 1.
S
ulphurO
verSi
liconInSolar:
1.0 # (Optional) Value of the Sulphur abundance ratio to solar in units of the Silicon ratio to solar. Default value: 1.
Ca
_o
ver
_
Si
_in_solar:
1.0 # (Optional) Value of the Calcium
mass
abundance ratio to solar in units of the Silicon ratio to solar. Default value: 1.
S
_o
ver
_
Si
_in_solar:
1.0 # (Optional) Value of the Sulphur
mass
abundance ratio to solar in units of the Silicon ratio to solar. Default value: 1.
newton_integration: 0 # (Optional) Set to 1 to use the Newton-Raphson scheme for the explicit cooling problem.
...
...
examples/CoolingBox/coolingBox.yml
View file @
8266849a
...
...
@@ -53,11 +53,11 @@ GrackleCooling:
ConvergenceLimit
:
1e-2
EAGLECooling
:
dirname
:
/co
sma5/data/Eagle/BG_Tables/Co
oling
T
ables/
dir
_
name
:
.
/cooling
t
ables/
H_reion_z
:
11.5
h
e_reion_z_center
:
3.5
h
e_reion_z_sigma
:
0.5
h
e_reion_e
v
_pH
:
2.0
H
e_reion_z_center
:
3.5
H
e_reion_z_sigma
:
0.5
H
e_reion_e
V
_p
_
H
:
2.0
EAGLEChemistry
:
InitMetallicity
:
0.014
...
...
examples/CoolingRates/cooling_rates.yml
View file @
8266849a
...
...
@@ -28,9 +28,9 @@ EAGLEChemistry:
InitAbundance_Iron
:
1.1032152e-3
EAGLECooling
:
dirname
:
./coolingtables/
dir
_
name
:
./coolingtables/
H_reion_z
:
11.5
He_reion_z_centre
:
3.5
He_reion_z_sigma
:
0.5
He_reion_e
v
_pH
:
2.0
He_reion_e
V
_p
_
H
:
2.0
examples/EAGLE_12/eagle_12.yml
View file @
8266849a
...
...
@@ -70,8 +70,8 @@ EAGLEChemistry: # Solar abundances
InitAbundance_Iron
:
1.1032152e-3
EAGLECooling
:
dirname
:
./coolingtables/
dir
_
name
:
./coolingtables/
H_reion_z
:
11.5
He_reion_z_centre
:
3.5
He_reion_z_sigma
:
0.5
He_reion_e
v
_pH
:
2.0
He_reion_e
V
_p
_
H
:
2.0
examples/EAGLE_25/eagle_25.yml
View file @
8266849a
...
...
@@ -79,9 +79,9 @@ EAGLEChemistry: # Solar abundances
InitAbundance_Iron
:
1.1032152e-3
EAGLECooling
:
dirname
:
./coolingtables/
dir
_
name
:
./coolingtables/
H_reion_z
:
11.5
He_reion_z_centre
:
3.5
He_reion_z_sigma
:
0.5
He_reion_e
v
_pH
:
2.0
He_reion_e
V
_p
_
H
:
2.0
examples/EAGLE_50/eagle_50.yml
View file @
8266849a
...
...
@@ -72,8 +72,8 @@ EAGLEChemistry: # Solar abundances
InitAbundance_Iron
:
1.1032152e-3
EAGLECooling
:
dirname
:
./coolingtables/
dir
_
name
:
./coolingtables/
H_reion_z
:
11.5
He_reion_z_centre
:
3.5
He_reion_z_sigma
:
0.5
He_reion_ev_pH
:
2.0
\ No newline at end of file
He_reion_eV_p_H
:
2.0
\ No newline at end of file
examples/EAGLE_6/eagle_6.yml
View file @
8266849a
...
...
@@ -83,8 +83,8 @@ EAGLEChemistry: # Solar abundances
InitAbundance_Iron
:
1.1032152e-3
EAGLECooling
:
dirname
:
./coolingtables/
dir
_
name
:
./coolingtables/
H_reion_z
:
11.5
He_reion_z_centre
:
3.5
He_reion_z_sigma
:
0.5
He_reion_ev_pH
:
2.0
\ No newline at end of file
He_reion_eV_p_H
:
2.0
examples/SantaBarbara/santa_barbara.yml
View file @
8266849a
...
...
@@ -72,9 +72,9 @@ EAGLEChemistry:
InitAbundance_Iron
:
0.0
EAGLECooling
:
dirname
:
/co
sma5/data/Eagle/BG_Tables/Co
oling
T
ables/
dir
_
name
:
.
/cooling
t
ables/
H_reion_z
:
11.5
h
e_reion_z_cent
e
r
:
3.5
h
e_reion_z_sigma
:
0.5
h
e_reion_e
v
_pH
:
2.0
H
e_reion_z_centr
e
:
3.5
H
e_reion_z_sigma
:
0.5
H
e_reion_e
V
_p
_
H
:
2.0
examples/SmallCosmoVolume_cooling/small_cosmo_volume.yml
View file @
8266849a
...
...
@@ -68,7 +68,7 @@ EAGLECooling:
H_reion_z
:
11.5
He_reion_z_centre
:
3.5
He_reion_z_sigma
:
0.5
He_reion_e
v
_pH
:
2.0
He_reion_e
V
_p
_
H
:
2.0
# Impose primoridal metallicity
EAGLEChemistry
:
...
...
examples/parameter_example.yml
View file @
8266849a
...
...
@@ -250,13 +250,14 @@ LambdaCooling:
# Parameters of the EAGLE cooling model (Wiersma+08 cooling tables).
EAGLECooling
:
dirname
:
./coolingtables/
# Location of the Wiersma+08 cooling tables
dir
_
name
:
./coolingtables/
# Location of the Wiersma+08 cooling tables
H_reion_z
:
8.5
# Redshift of Hydrogen re-ionization
He_reion_z_centre
:
3.5
# Redshift of the centre of the Helium re-ionization Gaussian
He_reion_z_sigma
:
0.5
# Spread in redshift of the Helium re-ionization Gaussian
He_reion_ev_pH
:
2.0
# Energy inject by Helium re-ionization in electron-volt per Hydrogen atom
CalciumOverSiliconInSolar
:
1.
# (Optional) Ratio of Ca/Si to use in units of solar. If set to 1, the code uses [Ca/Si] = 0, i.e. Ca/Si = 0.0941736.
SulphurOverSiliconInSolar
:
1.
# (Optional) Ratio of S/Si to use in units of solar. If set to 1, the code uses [S/Si] = 0, i.e. S/Si = 0.6054160.
He_reion_eV_p_H
:
2.0
# Energy inject by Helium re-ionization in electron-volt per Hydrogen atom
newton_integration
:
0
# (Optional) Set to 1 to use the Newton-Raphson method to solve the xplicit cooling problem.
Ca_over_Si_in_solar
:
1.
# (Optional) Ratio of Ca/Si to use in units of solar. If set to 1, the code uses [Ca/Si] = 0, i.e. Ca/Si = 0.0941736.
S_over_Si_in_solar
:
1.
# (Optional) Ratio of S/Si to use in units of solar. If set to 1, the code uses [S/Si] = 0, i.e. S/Si = 0.6054160.
# Cooling with Grackle 3.0
GrackleCooling
:
...
...
src/cooling/EAGLE/cooling.c
View file @
8266849a
...
...
@@ -738,21 +738,23 @@ void cooling_init_backend(struct swift_params *parameter_file,
struct
cooling_function_data
*
cooling
)
{
/* read some parameters */
parser_get_param_string
(
parameter_file
,
"EAGLECooling:dirname"
,
parser_get_param_string
(
parameter_file
,
"EAGLECooling:dir
_
name"
,
cooling
->
cooling_table_path
);
cooling
->
H_reion_z
=
parser_get_param_float
(
parameter_file
,
"EAGLECooling:H_reion_z"
);
cooling
->
Ca_over_Si_ratio_in_solar
=
parser_get_opt_param_float
(
parameter_file
,
"EAGLECooling::CalciumOverSiliconInSolar"
,
1
.
f
);
cooling
->
S_over_Si_ratio_in_solar
=
parser_get_opt_param_float
(
parameter_file
,
"EAGLECooling::SulphurOverSiliconInSolar"
,
1
.
f
);
cooling
->
He_reion_z_centre
=
parser_get_param_float
(
parameter_file
,
"EAGLECooling:He_reion_z_centre"
);
cooling
->
He_reion_z_sigma
=
parser_get_param_float
(
parameter_file
,
"EAGLECooling:He_reion_z_sigma"
);
cooling
->
He_reion_heat_cgs
=
parser_get_param_float
(
parameter_file
,
"EAGLECooling:He_reion_ev_pH"
);
parser_get_param_float
(
parameter_file
,
"EAGLECooling:He_reion_ev_p
_
H"
);
/* Optional parameters to correct the abundances */
cooling
->
Ca_over_Si_ratio_in_solar
=
parser_get_opt_param_float
(
parameter_file
,
"EAGLECooling:Ca_over_Si_in_solar"
,
1
.
f
);
cooling
->
S_over_Si_ratio_in_solar
=
parser_get_opt_param_float
(
parameter_file
,
"EAGLECooling:S_over_Si_in_solar"
,
1
.
f
);
/* convert to cgs */
cooling
->
He_reion_heat_cgs
*=
phys_const
->
const_electron_volt
*
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment