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
cf032f6f
Commit
cf032f6f
authored
May 01, 2019
by
Folkert Nobels
Browse files
Code formatting
parent
6472796b
Changes
3
Hide whitespace changes
Inline
Side-by-side
src/runner.c
View file @
cf032f6f
...
...
@@ -735,8 +735,8 @@ void runner_do_star_formation(struct runner *r, struct cell *c, int timer) {
/* Copy the properties of the gas particle to the star particle */
star_formation_copy_properties
(
p
,
xp
,
sp
,
e
,
sf_props
,
cosmo
,
with_cosmology
,
phys_const
,
hydro_props
,
us
,
cooling
);
with_cosmology
,
phys_const
,
hydro_props
,
us
,
cooling
);
/* Update the Star formation history */
star_formation_logger_log_new_spart
(
sp
,
&
c
->
stars
.
sfh
);
...
...
@@ -1655,10 +1655,10 @@ void runner_do_ghost(struct runner *r, struct cell *c, int timer) {
if
(((
p
->
h
>=
hydro_h_max
)
&&
(
f
<
0
.
f
))
||
((
p
->
h
<=
hydro_h_min
)
&&
(
f
>
0
.
f
)))
{
/* We have a particle whose smoothing length is already set (wants
* to be larger but has already hit the maximum OR wants to be
* smaller but has already reached the minimum). So, just tidy up as
* if the smoothing length had converged correctly */
/* We have a particle whose smoothing length is already set (wants
* to be larger but has already hit the maximum OR wants to be
* smaller but has already reached the minimum). So, just tidy up as
* if the smoothing length had converged correctly */
#ifdef EXTRA_HYDRO_LOOP
...
...
src/star_formation/EAGLE/star_formation.h
View file @
cf032f6f
...
...
@@ -244,10 +244,9 @@ INLINE static int star_formation_is_star_forming(
/* Calculate the entropy of the particle */
const
double
entropy
=
hydro_get_physical_entropy
(
p
,
xp
,
cosmo
);
/* Calculate the entropy EOS of the particle */
const
double
entropy_eos
=
entropy_floor
(
p
,
cosmo
,
entropy_floor_props
);
const
double
entropy_eos
=
entropy_floor
(
p
,
cosmo
,
entropy_floor_props
);
/* Check the Scahye & Dalla Vecchia 2012 EOS-based temperature critrion */
return
(
entropy
<
...
...
@@ -410,8 +409,8 @@ INLINE static void star_formation_copy_properties(
sp
->
birth_density
=
hydro_get_physical_density
(
p
,
cosmo
);
/* Store the birth temperature in the star particle */
sp
->
birth_temperature
=
cooling_get_temperature
(
phys_const
,
hydro_props
,
us
,
cosmo
,
cooling
,
p
,
xp
);
sp
->
birth_temperature
=
cooling_get_temperature
(
phys_const
,
hydro_props
,
us
,
cosmo
,
cooling
,
p
,
xp
);
/* Flag that this particle has not done feedback yet */
sp
->
f_E
=
-
1
.
f
;
...
...
src/stars/EAGLE/stars_io.h
View file @
cf032f6f
...
...
@@ -85,8 +85,9 @@ INLINE static void stars_write_particles(const struct spart *sparts,
birth_time
);
list
[
8
]
=
io_make_output_field
(
"FeedbackEnergyFraction"
,
FLOAT
,
1
,
UNIT_CONV_NO_UNITS
,
sparts
,
f_E
);
list
[
9
]
=
io_make_output_field
(
"BirthTemperature"
,
FLOAT
,
1
,
UNIT_CONV_TEMPERATURE
,
sparts
,
birth_temperature
);
list
[
9
]
=
io_make_output_field
(
"BirthTemperature"
,
FLOAT
,
1
,
UNIT_CONV_TEMPERATURE
,
sparts
,
birth_temperature
);
}
/**
...
...
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