specoutlines

Computes spectral line profiles arising from astrophysical winds

https://github.com/sflury/outlines

Science Score: 57.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
    Found 1 DOI reference(s) in README
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (13.9%) to scientific vocabulary
Last synced: 6 months ago · JSON representation ·

Repository

Computes spectral line profiles arising from astrophysical winds

Basic Info
  • Host: GitHub
  • Owner: sflury
  • License: gpl-3.0
  • Language: Python
  • Default Branch: main
  • Homepage:
  • Size: 449 KB
Statistics
  • Stars: 0
  • Watchers: 1
  • Forks: 1
  • Open Issues: 0
  • Releases: 2
Created over 2 years ago · Last pushed 7 months ago
Metadata Files
Readme License Citation

README.md

OutLines Logo

OutLines models spectral line profiles from winds, bubbles, and outflows following the formalism in Flury 2025 (see also Flury, Moran, & Eleazer 2023 for an earlier version). A primary goal of OutLines is to remain agnostic to the underlying physics while also drawing on physical motivations for the geometry, velocity, and gas density distributions. A cartoon of the model illustrating the observation of spherical outflows is shown below, depecting the Doppler shift (colored arrows) of light emitted (yellow and orange) and absorbed (orange) by gas in the outflow.

image of a model outflow

Physically justifiable assumptions include the density profile, including a variety of continuous or shell-like gas density distributions, and the velocity field, including the so-called beta law from approximations to CAK theory (e.g., Castor et al. 1975, Barlow et al. 1977) and other power law solutions, under the Sobolev approximation that small-scale ("local") gas velcities contribute negligibly to the net velocity field.

Emission and absorption profiles are computed in velocity space for the specified wavelength(s). Following the equation of radiative transfer, emission line profiles should be added in flux space while absorption line profiles should be added in optical depth space. One or multiple lines can be computed for each set of outflow properties, which is highly recommended in the case of multiple features from the same species such as the [O III] doublet or Si II UV absorption features. However, simultaneous fitting of lines from different phases of the interstellar medium or even different ionization zones is cautioned as different phases may not share the same wind, bubble, or outflow properties.

OutLines currently supports line profile models for absorption lines and nebular, resonant, and fluorescent emission lines.

Installation

While it is possible to download this repository, OutLines is readily accessible via pip install, which will automatically ensure the appropriate dependencies are also installed. An example call in the terminal command line is shown below.

bash $ pip3 install SpecOutLines

Line Profile Classes

| CLASS | LINE FEATURE | |-------------|----------------------| | Absorption | resonant absorption | | Nebular | nebular emission | | Resonant | resonant emission | | Fluorescent | fluorescent emission |

Example Usage -- [O III] 4959,5007 Profiles

python import OutLines as OL from numpy import linspace import matplotlib.pyplot as plt model = OL.Nebular([4958.911,5006.843],Geometry='HollowCones',AddStatic=True,Disk=True) model.update_params(['TerminalVelocity'],[500,30,15,45]) model.update_params(['OpeningAngle','CavityAngle','Inclination'],[500,30,15,45]) model.update_params(['FluxOutflow1','FluxStatic1'],[1/2.98,1/2.98]) wave = linspace(4950,5015,651)wave = linspace(4950,5015,651) plt.plot(wave,model.get_profile(wave),lw=2,color='C3') plt.plot(wave,model.get_outflow(wave),dashes=[3,3],lw=2,color='C3') plt.plot(wave,model.get_static(wave),':',lw=2,color='C3') plt.show() model.print_settings() model.print_params() props = OL.Properties(model) props.print_props() image of predicted \[O III\] doublet profile

``` text

| MODEL SETTINGS |

| Line 1 : 4958.911 | | Line 2 : 5006.843 | | Profile : Nebular | | VelocityField : BetaCAK | | DensityProfile : PowerLaw | | Geometry : HollowCones | | StaticComponent : Yes | | Aperture : No |

| Disk : Yes |


| MODEL PARAMETERS |


| DopplerWidth : 8.994 km/s | | TerminalVelocity : 500.000 km/s | | VelocityIndex : 1.000 | | FluxStatic1 : 0.336 | | FluxStatic2 : 1.000 | | FluxOutflow1 : 0.336 | | FluxOutflow2 : 1.000 | | Inclination : 45.000° | | OpeningAngle : 30.000° | | CavityAngle : 15.000° | | DiskRadius : 2.000 | | PowerLawIndex : 2.000 |



| MODEL PROPERTIES |


| x.out : 1.500 | | v.out : 166.667 km s^-1 | | Mdot : 1.057 Msun yr^-1 | | pdot : 0.111 10^34 dyne | | Edot : 0.009 10^42 erg s^-1 | | v.esc : 1.667 | | pdot.esc : 0.093 | | Edot.esc : 0.154 |


| Mdot, pdot, Edot / R0^2 n0 [kpc^2 cm^-3] | | pdot.est, Edot.esc / v0 [100 km s^-1] |


```

Example Usage -- Si II 1260 Profile

python import OutLines as OL from numpy import linspace import matplotlib.pyplot as plt kwargs = dict(Geometry='FilledCones',DensityProfile='LogNormal',AddStatic=True) model = OL.Absorption(1260.4221,1.18,**kwargs) wave = linspace(1259.25,1260.75,1001) plt.plot(wave,model.get_profile(wave),lw=2,color='C3') plt.plot(wave,model.get_outflow(wave),dashes=[3,3],lw=2,color='C3') plt.plot(wave,model.get_static(wave),':',lw=2,color='C3') plt.show() image of predicted Si II 1260 absorption profile

Referencing OutLines

While this code is provided publicly, it did require substantial effort to develop and document. Any use thereof must be cited in any publications in which this code is used. The BibTeX reference is below; however, a GitHub CCF is also provided for convenience.

bibtex @ARTICLE{, author = {{Flury}, Sophia R.}, title = "{OutLines: Modeling Astrophysical Winds, Bubbles, and Outflows}", journal = {\mnras}, year = 2025, month = jun, volume = {}, number = {}, pages = {}, doi = {} }

I developed and implemented the spherical geometry, power law density, CAK approximation model for analysis of broad [O III] lines observed in Mrk 462. That model was presented in Flury, Moran, & Eleazer (2023) MNRAS 525, 4231 The BibTeX reference is below.

bibtex @ARTICLE{2023MNRAS.525.4231F, author = {{Flury}, Sophia R. and {Moran}, Edward C. and {Eleazer}, Miriam}, title = "{Galactic outflow emission line profiles: evidence for dusty, radiatively driven ionized winds in Mrk 462}", journal = {\mnras}, year = 2023, month = nov, volume = {525}, number = {3}, pages = {4231-4242}, doi = {10.1093/mnras/stad2421} }

Licensing

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see https://www.gnu.org/licenses/.

Owner

  • Name: Sophia Flury
  • Login: sflury
  • Kind: user

Citation (CITATION.cff)

cff-version: 1.2.0
title: "OutLines"
type: software
message: >-
  'If you use this software, please cite it using the metadata from this file.'
authors:
  - given-names: Sophia
    family-names: Flury
    orcid: 'https://orcid.org/0000-0002-0159-2613'
identifiers:
  - type: doi
    value: 10.5281/zenodo.11238265
repository-code: 'https://github.com/sflury/OutLines'
license: GPL-3.0-or-later

GitHub Events

Total
  • Release event: 1
  • Delete event: 1
  • Push event: 27
  • Create event: 2
Last Year
  • Release event: 1
  • Delete event: 1
  • Push event: 27
  • Create event: 2

Packages

  • Total packages: 1
  • Total downloads:
    • pypi 21 last-month
  • Total dependent packages: 0
  • Total dependent repositories: 0
  • Total versions: 1
  • Total maintainers: 1
pypi.org: specoutlines

model spectral line profiles for astrophysical winds, bubbles, and outflows

  • Versions: 1
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Downloads: 21 Last month
Rankings
Dependent packages count: 8.8%
Average: 29.1%
Dependent repos count: 49.5%
Maintainers (1)
Last synced: 6 months ago