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
e5738a31
Commit
e5738a31
authored
Aug 03, 2018
by
Matthieu Schaller
Browse files
Use the same definition of G, Mpc and M_sun in all the examples.
parent
8810779b
Changes
28
Hide whitespace changes
Inline
Side-by-side
examples/AgoraDisk/agora_disk.yml
View file @
e5738a31
# Define the system of units to use internally.
InternalUnitSystem
:
UnitMass_in_cgs
:
1.98
9
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.085e21
# kpc in centimeters
UnitMass_in_cgs
:
1.98
848
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.085
67758
e21
# kpc in centimeters
UnitVelocity_in_cgs
:
1e5
# km/s in centimeters per second
UnitCurrent_in_cgs
:
1
# Amperes
UnitTemp_in_cgs
:
1
# Kelvin
...
...
examples/AgoraDisk/plot_solution.py
View file @
e5738a31
...
...
@@ -82,8 +82,8 @@ mean_dispersion_time_range = [50, 500] # in Myr = Used if add_mea
mean_dispersion_density_range
=
[
1e-25
,
1e-22
]
# in g/cm3 = Used if add_mean_fractional_dispersion = 1, for draw_density_DF
disk_normal_vector
=
[
0.
,
0.
,
1.
]
gadget_default_unit_base
=
{
'UnitLength_in_cm'
:
3.08568e+21
,
'UnitMass_in_g'
:
1.98
9
e+43
,
gadget_default_unit_base
=
{
'UnitLength_in_cm'
:
3.0856
775
8e+21
,
'UnitMass_in_g'
:
1.98
848
e+43
,
'UnitVelocity_in_cm_per_s'
:
100000
}
color_names
=
[
'red'
,
'magenta'
,
'orange'
,
'gold'
,
'green'
,
'cyan'
,
'blue'
,
'blueviolet'
,
'black'
]
linestyle_names
=
[
'-'
]
...
...
examples/DiscPatch/GravityOnly/disc-patch.yml
View file @
e5738a31
# Define the system of units to use internally.
InternalUnitSystem
:
UnitMass_in_cgs
:
1.988
5
e33
# G
rams
UnitLength_in_cgs
:
3.085677
6
e18
#
C
entimeters
UnitVelocity_in_cgs
:
1e5
#
Centimeters per second
UnitMass_in_cgs
:
1.988
48
e33
# M_sun in g
rams
UnitLength_in_cgs
:
3.085677
58
e18
#
parsec in c
entimeters
UnitVelocity_in_cgs
:
1e5
#
km/s in cm/s
UnitCurrent_in_cgs
:
1
# Amperes
UnitTemp_in_cgs
:
1
# Kelvin
...
...
examples/DiscPatch/GravityOnly/makeIC.py
View file @
e5738a31
...
...
@@ -38,11 +38,10 @@ import random
# usage: python makeIC.py 1000
# physical constants in cgs
NEWTON_GRAVITY_CGS
=
6.672e-8
SOLAR_MASS_IN_CGS
=
1.9885e33
PARSEC_IN_CGS
=
3.0856776e18
PROTON_MASS_IN_CGS
=
1.6726231e24
YEAR_IN_CGS
=
3.154e+7
NEWTON_GRAVITY_CGS
=
6.67408e-8
SOLAR_MASS_IN_CGS
=
1.98848e33
PARSEC_IN_CGS
=
3.08567758e18
YEAR_IN_CGS
=
3.15569252e7
# choice of units
const_unit_length_in_cgs
=
(
PARSEC_IN_CGS
)
...
...
examples/DiscPatch/HydroStatic/disc-patch-icc.yml
View file @
e5738a31
# Define the system of units to use internally.
InternalUnitSystem
:
UnitMass_in_cgs
:
1.988
5
e33
# Grams
UnitLength_in_cgs
:
3.08567758
149
e18
# Centimeters
UnitVelocity_in_cgs
:
1e5
# Centimeters per second
UnitMass_in_cgs
:
1.988
48
e33
# Grams
UnitLength_in_cgs
:
3.08567758e18
# Centimeters
UnitVelocity_in_cgs
:
1e5
# Centimeters per second
UnitCurrent_in_cgs
:
1
# Amperes
UnitTemp_in_cgs
:
1
# Kelvin
...
...
examples/DiscPatch/HydroStatic/disc-patch.yml
View file @
e5738a31
# Define the system of units to use internally.
InternalUnitSystem
:
UnitMass_in_cgs
:
1.988
5
e33
# Grams
UnitLength_in_cgs
:
3.08567758
149
e18
# Centimeters
UnitVelocity_in_cgs
:
1e5
# Centimeters per second
UnitMass_in_cgs
:
1.988
48
e33
# Grams
UnitLength_in_cgs
:
3.08567758e18
# Centimeters
UnitVelocity_in_cgs
:
1e5
# Centimeters per second
UnitCurrent_in_cgs
:
1
# Amperes
UnitTemp_in_cgs
:
1
# Kelvin
...
...
examples/DiscPatch/HydroStatic/makeIC.py
View file @
e5738a31
...
...
@@ -54,8 +54,8 @@ fileName = "Disc-Patch.hdf5"
# physical constants in cgs
NEWTON_GRAVITY_CGS
=
6.67408e-8
SOLAR_MASS_IN_CGS
=
1.988
5
e33
PARSEC_IN_CGS
=
3.08567758
149
e18
SOLAR_MASS_IN_CGS
=
1.988
48
e33
PARSEC_IN_CGS
=
3.08567758e18
PROTON_MASS_IN_CGS
=
1.672621898e-24
BOLTZMANN_IN_CGS
=
1.38064852e-16
YEAR_IN_CGS
=
3.15569252e7
...
...
examples/DiscPatch/HydroStatic_1D/disc-patch-icc.yml
View file @
e5738a31
# Define the system of units to use internally.
InternalUnitSystem
:
UnitMass_in_cgs
:
1.988
5
e33
# Grams
UnitLength_in_cgs
:
3.08567758
149
e18
# Centimeters
UnitMass_in_cgs
:
1.988
48
e33
# Grams
UnitLength_in_cgs
:
3.08567758e18
# Centimeters
UnitVelocity_in_cgs
:
1e5
# Centimeters per second
UnitCurrent_in_cgs
:
1
# Amperes
UnitTemp_in_cgs
:
1
# Kelvin
...
...
examples/DiscPatch/HydroStatic_1D/makeIC.py
View file @
e5738a31
...
...
@@ -55,8 +55,8 @@ fileName = "Disc-Patch.hdf5"
# physical constants in cgs
NEWTON_GRAVITY_CGS
=
6.67408e-8
SOLAR_MASS_IN_CGS
=
1.988
5
e33
PARSEC_IN_CGS
=
3.08567758
149
e18
SOLAR_MASS_IN_CGS
=
1.988
48
e33
PARSEC_IN_CGS
=
3.08567758e18
PROTON_MASS_IN_CGS
=
1.672621898e-24
BOLTZMANN_IN_CGS
=
1.38064852e-16
YEAR_IN_CGS
=
3.15569252e7
...
...
examples/EAGLE_100/eagle_100.yml
View file @
e5738a31
# Define the system of units to use internally.
InternalUnitSystem
:
UnitMass_in_cgs
:
1.98
9
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.085678e24
# Mpc in centimeters
UnitMass_in_cgs
:
1.98
848
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.08567
75
8e24
# Mpc in centimeters
UnitVelocity_in_cgs
:
1e5
# km/s in centimeters per second
UnitCurrent_in_cgs
:
1
# Amperes
UnitTemp_in_cgs
:
1
# Kelvin
...
...
examples/EAGLE_12/eagle_12.yml
View file @
e5738a31
# Define the system of units to use internally.
InternalUnitSystem
:
UnitMass_in_cgs
:
1.98
9
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.085678e24
# Mpc in centimeters
UnitMass_in_cgs
:
1.98
848
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.08567
75
8e24
# Mpc in centimeters
UnitVelocity_in_cgs
:
1e5
# km/s in centimeters per second
UnitCurrent_in_cgs
:
1
# Amperes
UnitTemp_in_cgs
:
1
# Kelvin
...
...
examples/EAGLE_25/eagle_25.yml
View file @
e5738a31
# Define the system of units to use internally.
InternalUnitSystem
:
UnitMass_in_cgs
:
1.98
9
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.085678e24
# Mpc in centimeters
UnitMass_in_cgs
:
1.98
848
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.08567
75
8e24
# Mpc in centimeters
UnitVelocity_in_cgs
:
1e5
# km/s in centimeters per second
UnitCurrent_in_cgs
:
1
# Amperes
UnitTemp_in_cgs
:
1
# Kelvin
...
...
examples/EAGLE_50/eagle_50.yml
View file @
e5738a31
# Define the system of units to use internally.
InternalUnitSystem
:
UnitMass_in_cgs
:
1.98
9
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.085678e24
# Mpc in centimeters
UnitMass_in_cgs
:
1.98
848
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.08567
75
8e24
# Mpc in centimeters
UnitVelocity_in_cgs
:
1e5
# km/s in centimeters per second
UnitCurrent_in_cgs
:
1
# Amperes
UnitTemp_in_cgs
:
1
# Kelvin
...
...
examples/EAGLE_6/eagle_6.yml
View file @
e5738a31
# Define the system of units to use internally.
InternalUnitSystem
:
UnitMass_in_cgs
:
1.98
9
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.085678e24
# Mpc in centimeters
UnitMass_in_cgs
:
1.98
848
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.08567
75
8e24
# Mpc in centimeters
UnitVelocity_in_cgs
:
1e5
# km/s in centimeters per second
UnitCurrent_in_cgs
:
1
# Amperes
UnitTemp_in_cgs
:
1
# Kelvin
...
...
examples/EAGLE_DMO_100/eagle_100.yml
View file @
e5738a31
# Define the system of units to use internally.
InternalUnitSystem
:
UnitMass_in_cgs
:
1.98
9
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.085678e24
# Mpc in centimeters
UnitMass_in_cgs
:
1.98
848
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.08567
75
8e24
# Mpc in centimeters
UnitVelocity_in_cgs
:
1e5
# km/s in centimeters per second
UnitCurrent_in_cgs
:
1
# Amperes
UnitTemp_in_cgs
:
1
# Kelvin
...
...
examples/EAGLE_DMO_12/eagle_12.yml
View file @
e5738a31
# Define the system of units to use internally.
InternalUnitSystem
:
UnitMass_in_cgs
:
1.98
9
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.085678e24
# Mpc in centimeters
UnitMass_in_cgs
:
1.98
848
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.08567
75
8e24
# Mpc in centimeters
UnitVelocity_in_cgs
:
1e5
# km/s in centimeters per second
UnitCurrent_in_cgs
:
1
# Amperes
UnitTemp_in_cgs
:
1
# Kelvin
...
...
examples/EAGLE_DMO_25/eagle_25.yml
View file @
e5738a31
# Define the system of units to use internally.
InternalUnitSystem
:
UnitMass_in_cgs
:
1.98
9
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.085678e24
# Mpc in centimeters
UnitMass_in_cgs
:
1.98
848
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.08567
75
8e24
# Mpc in centimeters
UnitVelocity_in_cgs
:
1e5
# km/s in centimeters per second
UnitCurrent_in_cgs
:
1
# Amperes
UnitTemp_in_cgs
:
1
# Kelvin
...
...
examples/EAGLE_DMO_50/eagle_50.yml
View file @
e5738a31
# Define the system of units to use internally.
InternalUnitSystem
:
UnitMass_in_cgs
:
1.98
9
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.085678e24
# Mpc in centimeters
UnitMass_in_cgs
:
1.98
848
e43
# 10^10 M_sun in grams
UnitLength_in_cgs
:
3.08567
75
8e24
# Mpc in centimeters
UnitVelocity_in_cgs
:
1e5
# km/s in centimeters per second
UnitCurrent_in_cgs
:
1
# Amperes
UnitTemp_in_cgs
:
1
# Kelvin
...
...
examples/ExternalPointMass/externalPointMass.yml
View file @
e5738a31
# Define the system of units to use internally.
InternalUnitSystem
:
UnitMass_in_cgs
:
1.98848e33
# M_sun
UnitLength_in_cgs
:
3.085677
6
e21
# kpc
UnitLength_in_cgs
:
3.085677
58
e21
# kpc
UnitVelocity_in_cgs
:
1e5
# km/s
UnitCurrent_in_cgs
:
1
# Amperes
UnitTemp_in_cgs
:
1
# Kelvin
...
...
examples/ExternalPointMass/makeIC.py
View file @
e5738a31
...
...
@@ -29,7 +29,7 @@ import random
# physical constants in cgs
NEWTON_GRAVITY_CGS
=
6.67408e-8
SOLAR_MASS_IN_CGS
=
1.98848e33
PARSEC_IN_CGS
=
3.085677
6
e18
PARSEC_IN_CGS
=
3.085677
58
e18
# choice of units
const_unit_length_in_cgs
=
(
1000
*
PARSEC_IN_CGS
)
...
...
Prev
1
2
Next
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