This repository contains simple Python utilities for computing the projected separation between the nuclei of a dual active galactic nucleus (AGN) system. The scripts demonstrate how to convert precise celestial coordinates into an angular distance and how to translate that measurement into a physical scale using a cosmological model.
Dual AGN occur when two supermassive black holes are active within the same galaxy, typically as the result of a merger. Measuring the angular separation between these nuclei allows astronomers to estimate their physical separation in parsecs or kiloparsecs. The steps are:
- Convert RA/Dec to decimal degrees – Right ascension is usually measured in hours, minutes and seconds, while declination uses degrees, arcminutes and arcseconds. Converting these values to decimal degrees simplifies further calculations.
- Compute angular distance – Using the spherical law of cosines we calculate the small angle between the nuclei on the sky.
- Convert to physical distance – With a cosmological redshift we can determine the angular diameter distance and translate the angular separation into kiloparsecs.
These calculations give a first‐order estimate of the distance between the nuclei assuming the separation is entirely in the plane of the sky.
Nuclear_Code.py– Functions for converting coordinates and computing angular separations. Running the module executes an example using two sets of coordinates.arcsec_to_parsec.py– Usesastropyto convert an angular measurement and redshift into a physical separation.requirements.txt– Python dependencies..gitignore– Standard ignores for Python projects.
Install the dependencies (ideally inside a virtual environment):
pip install -r requirements.txtTo compute the example angular separation run:
python Nuclear_Code.pyTo convert an angular distance to kiloparsecs:
python arcsec_to_parsec.pyBoth scripts can be imported as modules in your own analysis pipeline.
This repository is released under the MIT License.