Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
SWIFTsim
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
SWIFT
SWIFTsim
Commits
1a44222f
Commit
1a44222f
authored
6 years ago
by
Peter W. Draper
Browse files
Options
Downloads
Plain Diff
Merge remote-tracking branch 'origin/master' into parmetis-perm-test
parents
bbefa289
e9d05916
Branches
Branches containing commit
Tags
Tags containing commit
1 merge request
!506
Add ParMETIS support
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/hydro_properties.c
+1
-1
1 addition, 1 deletion
src/hydro_properties.c
src/units.c
+14
-0
14 additions, 0 deletions
src/units.c
src/units.h
+1
-0
1 addition, 0 deletions
src/units.h
with
16 additions
and
1 deletion
src/hydro_properties.c
+
1
−
1
View file @
1a44222f
...
...
@@ -123,7 +123,7 @@ void hydro_props_init(struct hydro_props *p,
/* Compute the minimal energy (Note the temp. read is in internal units) */
double
u_min
=
phys_const
->
const_boltzmann_k
/
phys_const
->
const_proton_mass
;
u_min
*=
p
->
ini
ti
al_temperature
;
u_min
*=
p
->
m
ini
m
al_temperature
;
u_min
*=
hydro_one_over_gamma_minus_one
;
/* Correct for hydrogen mass fraction */
...
...
This diff is collapsed.
Click to expand it.
src/units.c
+
14
−
0
View file @
1a44222f
...
...
@@ -50,6 +50,20 @@ void units_init_cgs(struct unit_system* us) {
us
->
UnitTemperature_in_cgs
=
1
.;
}
/**
* @brief Initialises the unit_system structure with SI system
*
* @param us The unit_system to initialize
*/
void
units_init_si
(
struct
unit_system
*
us
)
{
us
->
UnitMass_in_cgs
=
1000
.;
us
->
UnitLength_in_cgs
=
100
.;
us
->
UnitTime_in_cgs
=
1
.;
us
->
UnitCurrent_in_cgs
=
1
.;
us
->
UnitTemperature_in_cgs
=
1
.;
}
/**
* @brief Initialise the unit_system with values for the base units.
*
...
...
This diff is collapsed.
Click to expand it.
src/units.h
+
1
−
0
View file @
1a44222f
...
...
@@ -96,6 +96,7 @@ enum unit_conversion_factor {
};
void
units_init_cgs
(
struct
unit_system
*
);
void
units_init_si
(
struct
unit_system
*
);
void
units_init
(
struct
unit_system
*
us
,
double
U_M_in_cgs
,
double
U_L_in_cgs
,
double
U_t_in_cgs
,
double
U_C_in_cgs
,
double
U_T_in_cgs
);
void
units_init_from_params
(
struct
unit_system
*
,
struct
swift_params
*
,
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment