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
5c66158b
Commit
5c66158b
authored
Jun 24, 2019
by
Matthieu Schaller
Browse files
Corrected typos in the EAGLE black hole code that Yannick reported.
parent
790d13bb
Changes
11
Hide whitespace changes
Inline
Side-by-side
examples/EAGLE_ICs/EAGLE_12/eagle_12.yml
View file @
5c66158b
...
...
@@ -165,7 +165,7 @@ EAGLEFeedback:
EAGLEAGN
:
subgrid_seed_mass_Msun
:
1.5e5
# Black hole subgrid mass at creation time in solar masses.
max_eddington_fraction
:
1.
# Maximal allowed accretion rate in units of the Eddington rate.
visc
u
ous_alpha
:
1e6
# Normalisation constant of the Bondi viscuous time-scale accretion reduction term
viscous_alpha
:
1e6
# Normalisation constant of the Bondi viscuous time-scale accretion reduction term
radiative_efficiency
:
0.1
# Fraction of the accreted mass that gets radiated.
coupling_efficiency
:
0.15
# Fraction of the radiated energy that couples to the gas in feedback events.
AGN_delta_T_K
:
3.16228e8
# Change in temperature to apply to the gas particle in an AGN feedback event in Kelvin.
...
...
examples/EAGLE_ICs/EAGLE_25/eagle_25.yml
View file @
5c66158b
...
...
@@ -166,7 +166,7 @@ EAGLEFeedback:
EAGLEAGN
:
subgrid_seed_mass_Msun
:
1.5e5
# Black hole subgrid mass at creation time in solar masses.
max_eddington_fraction
:
1.
# Maximal allowed accretion rate in units of the Eddington rate.
visc
u
ous_alpha
:
1e6
# Normalisation constant of the Bondi viscuous time-scale accretion reduction term
viscous_alpha
:
1e6
# Normalisation constant of the Bondi viscuous time-scale accretion reduction term
radiative_efficiency
:
0.1
# Fraction of the accreted mass that gets radiated.
coupling_efficiency
:
0.15
# Fraction of the radiated energy that couples to the gas in feedback events.
AGN_delta_T_K
:
3.16228e8
# Change in temperature to apply to the gas particle in an AGN feedback event in Kelvin.
...
...
examples/EAGLE_ICs/EAGLE_50/eagle_50.yml
View file @
5c66158b
...
...
@@ -166,7 +166,7 @@ EAGLEFeedback:
EAGLEAGN
:
subgrid_seed_mass_Msun
:
1.5e5
# Black hole subgrid mass at creation time in solar masses.
max_eddington_fraction
:
1.
# Maximal allowed accretion rate in units of the Eddington rate.
visc
u
ous_alpha
:
1e6
# Normalisation constant of the Bondi viscuous time-scale accretion reduction term
viscous_alpha
:
1e6
# Normalisation constant of the Bondi viscuous time-scale accretion reduction term
radiative_efficiency
:
0.1
# Fraction of the accreted mass that gets radiated.
coupling_efficiency
:
0.15
# Fraction of the radiated energy that couples to the gas in feedback events.
AGN_delta_T_K
:
3.16228e8
# Change in temperature to apply to the gas particle in an AGN feedback event in Kelvin.
...
...
examples/EAGLE_low_z/EAGLE_12/eagle_12.yml
View file @
5c66158b
...
...
@@ -157,7 +157,7 @@ EAGLEFeedback:
EAGLEAGN
:
subgrid_seed_mass_Msun
:
1.5e5
# Black hole subgrid mass at creation time in solar masses.
max_eddington_fraction
:
1.
# Maximal allowed accretion rate in units of the Eddington rate.
visc
u
ous_alpha
:
1e6
# Normalisation constant of the Bondi viscuous time-scale accretion reduction term
viscous_alpha
:
1e6
# Normalisation constant of the Bondi viscuous time-scale accretion reduction term
radiative_efficiency
:
0.1
# Fraction of the accreted mass that gets radiated.
coupling_efficiency
:
0.15
# Fraction of the radiated energy that couples to the gas in feedback events.
AGN_delta_T_K
:
3.16228e8
# Change in temperature to apply to the gas particle in an AGN feedback event in Kelvin.
...
...
examples/EAGLE_low_z/EAGLE_25/eagle_25.yml
View file @
5c66158b
...
...
@@ -164,7 +164,7 @@ EAGLEFeedback:
EAGLEAGN
:
subgrid_seed_mass_Msun
:
1.5e5
# Black hole subgrid mass at creation time in solar masses.
max_eddington_fraction
:
1.
# Maximal allowed accretion rate in units of the Eddington rate.
visc
u
ous_alpha
:
1e6
# Normalisation constant of the Bondi viscuous time-scale accretion reduction term
viscous_alpha
:
1e6
# Normalisation constant of the Bondi viscuous time-scale accretion reduction term
radiative_efficiency
:
0.1
# Fraction of the accreted mass that gets radiated.
coupling_efficiency
:
0.15
# Fraction of the radiated energy that couples to the gas in feedback events.
AGN_delta_T_K
:
3.16228e8
# Change in temperature to apply to the gas particle in an AGN feedback event in Kelvin.
...
...
examples/EAGLE_low_z/EAGLE_50/eagle_50.yml
View file @
5c66158b
...
...
@@ -156,7 +156,7 @@ EAGLEFeedback:
EAGLEAGN
:
subgrid_seed_mass_Msun
:
1.5e5
# Black hole subgrid mass at creation time in solar masses.
max_eddington_fraction
:
1.
# Maximal allowed accretion rate in units of the Eddington rate.
visc
u
ous_alpha
:
1e6
# Normalisation constant of the Bondi viscuous time-scale accretion reduction term
viscous_alpha
:
1e6
# Normalisation constant of the Bondi viscuous time-scale accretion reduction term
radiative_efficiency
:
0.1
# Fraction of the accreted mass that gets radiated.
coupling_efficiency
:
0.15
# Fraction of the radiated energy that couples to the gas in feedback events.
AGN_delta_T_K
:
3.16228e8
# Change in temperature to apply to the gas particle in an AGN feedback event in Kelvin.
...
...
examples/EAGLE_low_z/EAGLE_6/eagle_6.yml
View file @
5c66158b
...
...
@@ -166,7 +166,7 @@ EAGLEFeedback:
EAGLEAGN
:
subgrid_seed_mass_Msun
:
1.5e5
# Black hole subgrid mass at creation time in solar masses.
max_eddington_fraction
:
1.
# Maximal allowed accretion rate in units of the Eddington rate.
visc
u
ous_alpha
:
1e6
# Normalisation constant of the Bondi viscuous time-scale accretion reduction term
viscous_alpha
:
1e6
# Normalisation constant of the Bondi viscuous time-scale accretion reduction term
radiative_efficiency
:
0.1
# Fraction of the accreted mass that gets radiated.
coupling_efficiency
:
0.15
# Fraction of the radiated energy that couples to the gas in feedback events.
AGN_delta_T_K
:
3.16228e8
# Change in temperature to apply to the gas particle in an AGN feedback event in Kelvin.
...
...
examples/parameter_example.yml
View file @
5c66158b
...
...
@@ -396,7 +396,7 @@ EAGLEFeedback:
EAGLEAGN
:
subgrid_seed_mass_Msun
:
1.5e5
# Black hole subgrid mass at creation time in solar masses.
max_eddington_fraction
:
1.
# Maximal allowed accretion rate in units of the Eddington rate.
visc
u
ous_alpha
:
1e6
# Normalisation constant of the Bondi viscuous time-scale accretion reduction term
viscous_alpha
:
1e6
# Normalisation constant of the Bondi viscuous time-scale accretion reduction term
radiative_efficiency
:
0.1
# Fraction of the accreted mass that gets radiated.
coupling_efficiency
:
0.15
# Fraction of the radiated energy that couples to the gas in feedback events.
AGN_delta_T_K
:
3.16228e8
# Change in temperature to apply to the gas particle in an AGN feedback event in Kelvin.
...
...
src/black_holes/EAGLE/black_holes.h
View file @
5c66158b
...
...
@@ -331,10 +331,10 @@ __attribute__((always_inline)) INLINE static void black_holes_prepare_feedback(
v_diff_peculiar
[
1
]
*
v_diff_peculiar
[
1
]
+
v_diff_peculiar
[
2
]
*
v_diff_peculiar
[
2
];
/* Norm of the cir
e
cular velocity of the gas around the BH */
/* Norm of the circular velocity of the gas around the BH */
const
double
tangential_velocity2
=
gas_v_circular
[
0
]
*
gas_v_circular
[
0
]
+
gas_v_circular
[
0
]
*
gas_v_circular
[
0
]
+
gas_v_circular
[
0
]
*
gas_v_circular
[
0
];
gas_v_circular
[
1
]
*
gas_v_circular
[
1
]
+
gas_v_circular
[
2
]
*
gas_v_circular
[
2
];
const
double
tangential_velocity
=
sqrt
(
tangential_velocity2
);
/* We can now compute the Bondi accretion rate (internal units) */
...
...
src/black_holes/EAGLE/black_holes_iact.h
View file @
5c66158b
...
...
@@ -87,7 +87,7 @@ __attribute__((always_inline)) INLINE static void runner_iact_nonsym_bh_density(
/* Contribution to the circular valocity */
const
float
dv
[
3
]
=
{
bi
->
v
[
0
]
-
vj
[
0
],
bi
->
v
[
1
]
-
vj
[
1
],
bi
->
v
[
2
]
-
vj
[
2
]};
bi
->
circular_velocity_gas
[
0
]
+=
mj
*
wi
*
(
dx
[
1
]
*
dv
[
2
]
-
dx
[
2
]
*
dv
[
1
]);
bi
->
circular_velocity_gas
[
1
]
+=
mj
*
wi
*
(
dx
[
0
]
*
dv
[
2
]
-
dx
[
2
]
*
dv
[
0
]);
bi
->
circular_velocity_gas
[
1
]
+=
mj
*
wi
*
(
dx
[
2
]
*
dv
[
0
]
-
dx
[
0
]
*
dv
[
2
]);
bi
->
circular_velocity_gas
[
2
]
+=
mj
*
wi
*
(
dx
[
0
]
*
dv
[
1
]
-
dx
[
1
]
*
dv
[
0
]);
#ifdef DEBUG_INTERACTIONS_BH
...
...
src/black_holes/EAGLE/black_holes_properties.h
View file @
5c66158b
...
...
@@ -147,7 +147,7 @@ INLINE static void black_holes_props_init(struct black_holes_props *bp,
parser_get_param_float
(
params
,
"EAGLEAGN:radiative_efficiency"
);
bp
->
epsilon_f
=
parser_get_param_float
(
params
,
"EAGLEAGN:coupling_efficiency"
);
bp
->
alpha_visc
=
parser_get_param_float
(
params
,
"EAGLEAGN:visc
u
ous_alpha"
);
bp
->
alpha_visc
=
parser_get_param_float
(
params
,
"EAGLEAGN:viscous_alpha"
);
/* Feedback parameters ---------------------------------- */
...
...
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