galaxia is a code for generating a synthetic model of the galaxy. This repository is a modified version of galaxia (Sharma, S., Bland-Hawthorn, J., Johnston, K. V., & Binney, J. 2011, ApJ, 730,3) that enables the user to modify the parameters of the galaxy model. This README outlines a slightly different installation and usage than the one described on the galaxia documentation page.
To install galaxia, first clone the GitHub repository.
git clone [email protected]:jluastro/galaxia.git
Next download and extract the GalaxiaData folder
from our online server at http://bhs.astro.berkeley.edu/GalaxiaData.tar.gz
.
wget http://bhs.astro.berkeley.edu/GalaxiaData.tar.gz
tar xvf GalaxiaData.tar.gz
This folder will need to be unique to each galaxy model that you run on galaxia, so you may need to download multiple versions for different galaxy models parameters.
Next compile, make, and install the galaxia installation. We recommend following the
non root installation outlined in
the galaxia documentation.
The prefix argument specifies the folder where the executable will be written to.
If you want to install in PATH/TO/galaxia/bin
then run:
./configure --prefix=PATH/TO/galaxia
make
make install
Note that our version does not require specifying a data directory. Doing so has no effect on the execution of the code. Instead the user is asked to specify the location of the GalaxiaData folder in a galaxyModel parameter file as described below.
You will now have a galaxia executable located in PATH/TO/galaxia/bin
. If this
directory does not already exist in your PATH environment variable, then make sure to prepend it.
export PATH=PATH/TO/galaxia/bin:$PATH
The functions and features of galaxia are outlined on the galaxia documentation page. We provide an example of the required galaxia parameter file at example_galaxiaParams.txt.
Our version requires an additional parameter file that states the location of the GalaxiaData directory and the galaxy model parameters. An example galaxyModel parameter file is located at example_galaxyModelParams.txt.
To run galaxia with this parameter file, place it as the next argument after the regular galaxia parameter file.
galaxia -r example_galaxiaParams.txt example_galaxyModelParams.txt
Make sure that the GalaxiaData directory specified in your galaxyModel parameter file points to a unique directory for each different set of galaxy model parameters.
Our version will automatically generate the BHTree files required to run galaxia if they are not present in the GalaxiaData directory. This will occur the first time you run a galaxia simulation. However you can choose to force the calculation of the BHTree files by running:
galaxia -s [warp or nowarp] example_galaxyModelParams.txt
BHTree files will now exist in the GalaxyData folder specified
in example_galaxyModelParams.txt
.