sf3dmodels

This is the documentation for the Star-Forming regions 3D Modelling package.

Find the source code on GitHub.

Powered by Astropy Badge ASCL Code Record

sf3dmodels is a 3D modelling package that collects analytical prescriptions of gas/dust envelopes, discs, outflows and filaments in order to reproduce complex star-forming systems such as those being revealed by state-of-the-art telescopes. The package can (i) model individual/isolated objects or, alternatively, (ii) couple multiple models in a single grid to recreate composite regions.

The output model can then be read with LIME, RADMC-3D or Polaris to compute the radiative transfer of the modelled region, which is a key step prior comparison to real observations.

https://raw.githubusercontent.com/andizq/star-forming-regions/master/images/intro_sf3dmodels0_png.png

The sf3models grid and rt (radiative transfer) modules can also be used as wrappers between hydrodynamical simulations and radiative transfer codes. These modules are especially dedicated to treat irregular meshes (e.g. Voronoi meshes or SPH grid particles).

https://raw.githubusercontent.com/andizq/star-forming-regions/master/images/intro_sf3dmodels1_png.png

Take a look at the following examples linking AREPO and Phantom hydrodynamical simulations with Polaris and LIME,

Requirements

Installation

From source

Clone the star-forming-regions repository from GitHub:

If you have a github account, type in a terminal:

git clone git@github.com:andizq/star-forming-regions.git

if you don’t have one:

git clone https://github.com/andizq/star-forming-regions.git

Get into the star-forming-regions folder and run the setup.py script in installation mode:

cd star-forming-regions
python setup.py install

You can run any example from star-forming-regions/examples to check if the installation was succesful.

Update the package

cd star-forming-regions
git pull
python setup.py install

Uninstall

pip uninstall sf3dmodels

LIME in sf3dmodels mode

The star-forming-regions repository includes a customised version of LIME v1.9.5, with additional routines for sf3dmodels users. This customisation allows using the sf3dmodels output as input for LIME in a user-friendly way.

Installation

LIME must be configured separately after installing the sf3dmodels package with success.

Have a look at the LIME installation notes section. If you need to install third-party libraries (e.g. qhull, cfitsio, gsl), make sure to configure their paths to point to the LIME directory included in this repository.

We strongly recommend the user to install the 2010 version of Qhull, which can be done as follows:

wget https://github.com/qhull/qhull/archive/2010.1.tar.gz #download qhull v2010.1
#curl -O https://github.com/qhull/qhull/archive/2010.1.tar.gz #you can also use curl
gunzip 2010.1.tar.gz
tar -xvf 2010.1.tar
cd qhull-2010.1
sh config/bootstrap.sh
./configure --prefix=/Users/andizq/star-forming-regions/lime
emacs Makefile #if defined, delete flag -Wno-sign-conversion
make
make install

Running LIME

LIME will look for the .dat files (with your model data) generated by sf3dmodels and load them into dedicated sf3d structures. To invoke this option, a -S flag (capital S) must be added to the usual execution command as follows:

lime -S model.c

The standard LIME command line options may also be invoked. For instance, to set LIME to (1.) produce normal output rather than the default ncurses output style, (2.) read the sf3dmodels output and (3.) run in parallel mode with 4 threads you should execute:

lime -nS -p 4 model.c

Note that if the -S option is not set you will get back the ‘default’ operation of LIME.

LIME Examples

Take a look at the folders lime/example and lime/example_sf3dmodels/ included in this repository.

Reference/API

sf3dmodels Package

sf3dmodels : star-forming regions 3d modelling package

Developers

Special thanks to those who have reported bugs or whose ideas and discussions have helped improve sf3dmodels,

  • Rowan Smith
  • Yuxin Lin
  • Antonio Hernandez
  • Jonathan Henshaw
  • Qizhou Zhang
  • Leonardo Testi
  • Stefano Facchini
  • Ewine van Dishoeck
  • Pietro Curone
  • Carlos Carrasco-González
  • Adriana Rodríguez-Kamenetzky

License

This project is Copyright (c) Andres Izquierdo and licensed under the terms of the BSD 3-Clause license. This package is based upon the Astropy package template which is licensed under the BSD 3-clause licence. See the licenses folder for more information.

Citing sf3dmodels

If you find sf3dmodels useful for your research please cite the work of Izquierdo+2018:

@ARTICLE{2018MNRAS.478.2505I,
   author = {{Izquierdo}, Andr{\'e}s F. and {Galv{\'a}n-Madrid}, Roberto and
             {Maud}, Luke T. and {Hoare}, Melvin G. and {Johnston}, Katharine G. and
             {Keto}, Eric R. and {Zhang}, Qizhou and {de Wit}, Willem-Jan},
   title = "{Radiative transfer modelling of W33A MM1: 3D structure and dynamics of a complex massive star-forming region}",
   journal = {\mnras},
   keywords = {radiative transfer, stars: formation, stars: massive, stars: protostars, Astrophysics - Astrophysics of Galaxies, Astrophysics - Solar and Stellar Astrophysics},
   year = "2018",
   month = "Aug",
   volume = {478},
   number = {2},
   pages = {2505-2525},
   doi = {10.1093/mnras/sty1096},
   archivePrefix = {arXiv},
   eprint = {1804.09204},
   primaryClass = {astro-ph.GA},
   adsurl = {https://ui.adsabs.harvard.edu/abs/2018MNRAS.478.2505I},
   adsnote = {Provided by the SAO/NASA Astrophysics Data System}
}

Warning

This package, as well as its documentation, are currently under development and may often undergo modifications.