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
98c4861f
Commit
98c4861f
authored
May 08, 2019
by
Loic Hausammann
Browse files
AGORA: Only the metallicity graphs are missing
parent
2bdab58a
Changes
3
Expand all
Hide whitespace changes
Inline
Side-by-side
examples/GEAR/AgoraDisk/getSolution.sh
View file @
98c4861f
#!/bin/bash
OPTIND
=
1
with_cooling
=
0
function
show_help
{
echo
"Valid options are:"
echo
"
\t
-h
\t
Show this help"
echo
"
\t
-C
\t
Download solution with cooling"
}
while
getopts
"h?C"
opt
;
do
case
"
$opt
"
in
h|
\?
)
show_help
exit
;;
C
)
with_cooling
=
1
;;
esac
done
# cleanup work space
rm
snapshot_0000.hdf5 snapshot_0500.hdf5
if
[
$with_cooling
-eq
1
]
;
then
wget https://obswww.unige.ch/~lhausamm/swift/IC/AgoraDisk/Gear/with_cooling/snapshot_0000.hdf5
wget https://obswww.unige.ch/~lhausamm/swift/IC/AgoraDisk/Gear/with_cooling/snapshot_0500.hdf5
else
wget https://obswww.unige.ch/~lhausamm/swift/IC/AgoraDisk/Gear/without_cooling/snapshot_0000.hdf5
wget https://obswww.unige.ch/~lhausamm/swift/IC/AgoraDisk/Gear/without_cooling/snapshot_0500.hdf5
fi
wget https://obswww.unige.ch/~lhausamm/swift/IC/AgoraDisk/Gear/with_cooling/snapshot_0000.hdf5
wget https://obswww.unige.ch/~lhausamm/swift/IC/AgoraDisk/Gear/with_cooling/snapshot_0500.hdf5
# wget https://obswww.unige.ch/~lhausamm/swift/IC/AgoraDisk/Gear/without_cooling/snapshot_0000.hdf5
# wget https://obswww.unige.ch/~lhausamm/swift/IC/AgoraDisk/Gear/without_cooling/snapshot_0500.hdf5
examples/GEAR/AgoraDisk/plotSolution.py
View file @
98c4861f
This diff is collapsed.
Click to expand it.
examples/GEAR/AgoraDisk/run.sh
View file @
98c4861f
...
...
@@ -5,19 +5,9 @@
# currently only the low resolution is available
sim
=
low
# enable cooling or not
cooling
=
0
# make run.sh fail if a subcommand fails
set
-e
# define flags
flag
=
if
[
$cooling
-eq
1
]
then
flag
=
-C
fi
# Generate the initial conditions if they are not present.
if
[
!
-e
$sim
.hdf5
]
then
...
...
@@ -38,7 +28,7 @@ cp $sim.hdf5 agora_disk.hdf5
python3 changeType.py agora_disk.hdf5
# Run SWIFT
../../swift
$flag
--hydro
--self-gravity
--threads
=
4 agora_disk.yml 2>&1 |
tee
output.log
../../swift
-C
--hydro
--self-gravity
--threads
=
4 agora_disk.yml 2>&1 |
tee
output.log
echo
"Changing smoothing length to be Gadget compatible"
...
...
@@ -46,7 +36,8 @@ python3 cleanupSwift.py agora_disk_0000.hdf5 agora_disk_IC.hdf5
python3 cleanupSwift.py agora_disk_0050.hdf5 agora_disk_500Myr.hdf5
echo
"Fetching GEAR solution..."
./getSolution.sh
$flag
./getSolution.sh
echo
"Plotting..."
python3 plotSolution.py
$flag
python3 plotSolution.py
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