Author: Braden Nowicki Advisor: Dr. Massimo Ricotti
Interface with Cloudy Photoionization Software data and RAMSES-RT Simulation data to create galaxy images and spectra in nebular emission lines.
MERLIN
merlin/ : primary package for analysis and visualizations CloudyFiles/ : files related to Cloudy grid runs. Reference/ : previously-developed analysis code.
The Cloudy Photoionization Code is used to generate line emission (flux) throughout the desired parameter space. We consider gas parameters Ionization Parameter, Hydrogen Number Density, and Temperature. A simple grid run is performed, simulating emission for lines present in CloudyFiles/gridrun-09-02-2026/LineList_NebularO.dat and CloudyFiles/gridrun-09-02-2026/LineList_NebularCN.dat (can be adjusted) from a 1 cm thick gas cell. The exact conditions can be adjusted (the star SED, for instance) for a given run; a simulation for every combination of the varying parameters is performed. Line list data is output in 'LineList_NebularCN.dat' and 'LineList_NebularO.dat', then combined into a single 'linelist.dat' file via 'combine_tables.py'.
See CloudyFiles/gridrun-09-02-2026. interp6.in is the input file. The run file (with executable privilege) can be used in your installation of Cloudy. For instance, in the terminal, './run interp6' would run the desired simulations (note that grid runs require the use of the -r option, present in 'run', and therefore the input file is given as interp6, ommitting .in.)
'main.py' outlines the process: create derived field functions; load the simulation given by the filepath (as a command line argument) pointing to the info_*.txt file within an output folder; instantiate an EmissionLineInterpolator object for the derived flux and luminosity fields using the desired 'linelist.dat' table; instantiate a VisualizationManager object; and run the desired routines/analysis for the time slice.
The class structures allow for easy testing of new features and updates. One must call save_sim_info() for Object variables like current_redshift to be created; afterwards, any function can be called in a modular fashion. There are some exceptions: phase_with_profiles(), for instance, uses an object generated by phase_plot().
With the desired routines and field setup chosen in a driver script like 'main.py', analysis can be performed on multiple time slices in parallel. For RAMSES-RT output data stored in a cluster, use scp to copy merlin, a driver script like 'main.py', and a shell script like 'analysis.sh' to the cluster scratch space. One may test that it works in the scratch space by running 'main.py' on one time slice. You must first perform the module loads and pip installs at the beginning of 'main.py' for the dependencies. The shell script 'analysis-1.sh' shows one way to run the script on multiple time slices in parallel (in one job). Preferably, the jobs are submitted in a job array to run when resources are available, since the tasks are completely independent (as in 'analysis.sh'). A python install path can be specified to avoid using the version zaratan jobs default to.
The Merlin is a small species of falcon from the Northern Hemisphere. The naming of this package is inspired by the Merlin's exceptionally sharp eyesight; we generate observational diagnostics from simulated distant, high-redshift galaxies. Birds are a bellwether of environmental decline; populations are down nearly 3 billion birds since 1970. Please consider supporting local efforts to safeguard birds, their migration, and their habitats.