As discussed in the Lecture, there is a famous relation observed in galaxies relating the surface density of gas with the star formation rate. The so called SK relation
You can start from several initial conditions of idealized galaxies:
Preparing the simulation:
OpenGadget3/CoolingSfr
as
the tutorial version contains some typos in the cooling part.PERIODIC
, NOGRAVITY
, LONG_X/Y/Z
and all the switches enabled
for MAGNETIC
in the Config.sh
file.
COOLING
and SFR
in the Config.sh
file and compile the code.
TREECOOL
file from the OpenGadget3 directory into your simulation directory.
InitCondFile
ICFormat 1
TimeMax 1
TimeBetSnapshot 0.01
PeriodicBoundariesOn 0
PartAllocFactor 5.5
CoolingOn 1
StarformationOn 1
SofteningGas 0.02
SofteningHalo 0.02
SofteningDisk 0.02
SofteningBulge 0.02
SofteningStars 0.02
SofteningGasMaxPhys 0.02
SofteningHaloMaxPhys 0.02
SofteningDiskMaxPhys 0.02
SofteningBulgeMaxPhys 0.02
SofteningStarsMaxPhys 0.02
UnitLength_in_cm 3.085678e21
UnitMass_in_g 1.989e43
UnitVelocity_in_cm_per_s 1e5
CritPhysDensity 0.
MaxSfrTimescale 1.5
CritOverDensity 57.7
TempSupernova 1.0e8
TempClouds 1000.0
FactorSN 0.1
FactorEVP 1000.0
show_galaxy.pro
in IDL
show_sk.pro
in IDL
ifort -g -traceback -check all -fpe0 -o galaxysetup galaxysetup.f90
galaxy.txt
,
which is a text version of the “small” galaxy initial conditions)
./galaxysetup
gnuplot grid.plt
(to check that the particle positions are set up correctly)
ICFormat 2
galaxies.ic
as the initial conditions file
and output
as the snapshot file base in the parameter file,
and BoxSize
= 1TimeMax
= 10, TimeBetSnapshot
= 0.1)
ifort -g -traceback -check all -fpe0 -o readsnap readsnap.f90
for file in output_???; do ./readsnap $file >$file.txt; done
gnuplot galaxy.plt
xine -l galaxies.mp4
You can additionally switch on the kinetic feedback and see what happens, especially if now a galactic outflow/wind is established.
WINDS
in the Config.sh
file.
WindEfficiency 2.0
WindFreeTravelMaxTimeFactor 0.025
WindEnergyFraction 0.5
WindFreeTravelDensFac 0.5