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
b32f33ab
Commit
b32f33ab
authored
Jan 05, 2019
by
Matthieu Schaller
Browse files
Added units to the gravity and hydro parameter outputs in the snapshots.
parent
1a9b5c53
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/gravity_properties.c
View file @
b32f33ab
...
...
@@ -170,20 +170,22 @@ void gravity_props_print_snapshot(hid_t h_grpgrav,
io_write_attribute_s
(
h_grpgrav
,
"Softening style"
,
kernel_gravity_softening_name
);
io_write_attribute_f
(
h_grpgrav
,
"Comoving softening length"
,
h_grpgrav
,
"Comoving softening length
[internal units]
"
,
p
->
epsilon_comoving
*
kernel_gravity_softening_plummer_equivalent
);
io_write_attribute_f
(
h_grpgrav
,
"Comoving Softening length (Plummer equivalent)"
,
p
->
epsilon_comoving
);
io_write_attribute_f
(
h_grpgrav
,
"Maximal physical softening length"
,
h_grpgrav
,
"Comoving Softening length (Plummer equivalent) [internal units]"
,
p
->
epsilon_comoving
);
io_write_attribute_f
(
h_grpgrav
,
"Maximal physical softening length [internal units]"
,
p
->
epsilon_max_physical
*
kernel_gravity_softening_plummer_equivalent
);
io_write_attribute_f
(
h_grpgrav
,
"Maximal physical softening length (Plummer equivalent)"
,
"Maximal physical softening length (Plummer equivalent) "
" [internal units]"
,
p
->
epsilon_max_physical
);
io_write_attribute_f
(
h_grpgrav
,
"Opening angle"
,
p
->
theta_crit
);
io_write_attribute_s
(
h_grpgrav
,
"Scheme"
,
GRAVITY_IMPLEMENTATION
);
io_write_attribute_
d
(
h_grpgrav
,
"MM order"
,
SELF_GRAVITY_MULTIPOLE_ORDER
);
io_write_attribute_
i
(
h_grpgrav
,
"MM order"
,
SELF_GRAVITY_MULTIPOLE_ORDER
);
io_write_attribute_f
(
h_grpgrav
,
"Mesh a_smooth"
,
p
->
a_smooth
);
io_write_attribute_f
(
h_grpgrav
,
"Mesh r_cut_max ratio"
,
p
->
r_cut_max_ratio
);
io_write_attribute_f
(
h_grpgrav
,
"Mesh r_cut_min ratio"
,
p
->
r_cut_min_ratio
);
...
...
src/hydro_properties.c
View file @
b32f33ab
...
...
@@ -239,7 +239,8 @@ void hydro_props_print_snapshot(hid_t h_grpsph, const struct hydro_props *p) {
io_write_attribute_f
(
h_grpsph
,
"Kernel delta N_ngb"
,
p
->
delta_neighbours
);
io_write_attribute_f
(
h_grpsph
,
"Kernel eta"
,
p
->
eta_neighbours
);
io_write_attribute_f
(
h_grpsph
,
"Smoothing length tolerance"
,
p
->
h_tolerance
);
io_write_attribute_f
(
h_grpsph
,
"Maximal smoothing length"
,
p
->
h_max
);
io_write_attribute_f
(
h_grpsph
,
"Maximal smoothing length [internal units]"
,
p
->
h_max
);
io_write_attribute_f
(
h_grpsph
,
"CFL parameter"
,
p
->
CFL_condition
);
io_write_attribute_f
(
h_grpsph
,
"Volume log(max(delta h))"
,
p
->
log_max_h_change
);
...
...
@@ -248,8 +249,12 @@ void hydro_props_print_snapshot(hid_t h_grpsph, const struct hydro_props *p) {
io_write_attribute_i
(
h_grpsph
,
"Max ghost iterations"
,
p
->
max_smoothing_iterations
);
io_write_attribute_f
(
h_grpsph
,
"Minimal temperature"
,
p
->
minimal_temperature
);
io_write_attribute_f
(
h_grpsph
,
"Minimal energy per unit mass [internal units]"
,
p
->
minimal_internal_energy
);
io_write_attribute_f
(
h_grpsph
,
"Initial temperature"
,
p
->
initial_temperature
);
io_write_attribute_f
(
h_grpsph
,
"Initial energy per unit mass"
,
io_write_attribute_f
(
h_grpsph
,
"Initial energy per unit mass [internal units]"
,
p
->
initial_internal_energy
);
io_write_attribute_f
(
h_grpsph
,
"Hydrogen mass fraction"
,
p
->
hydrogen_mass_fraction
);
...
...
@@ -260,7 +265,8 @@ void hydro_props_print_snapshot(hid_t h_grpsph, const struct hydro_props *p) {
p
->
viscosity
.
alpha_max
);
io_write_attribute_f
(
h_grpsph
,
"Alpha viscosity (min)"
,
p
->
viscosity
.
alpha_min
);
io_write_attribute_f
(
h_grpsph
,
"Viscosity decay length"
,
p
->
viscosity
.
length
);
io_write_attribute_f
(
h_grpsph
,
"Viscosity decay length [internal units]"
,
p
->
viscosity
.
length
);
io_write_attribute_f
(
h_grpsph
,
"Beta viscosity"
,
const_viscosity_beta
);
}
#endif
...
...
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