/DSAModels.jl

Cosmic Ray acceleration models used in Böss et. al. 2023

Primary LanguageJuliaMIT LicenseMIT

Documentation Build Status License Citation
Build Status codecov.io The MIT License DOI

Package Development

⚠️ This package is being discontinued, as it can't be registered in the General registry due to its name. Development has been moved to DiffusiveShockAccelerationModels.jl

DSAModels.jl

This package provides a number of efficiency models for Diffusive Shock Acceleration (DSA). If you use this implementation for publications, please cite Böss et. al. (2023).

Install

As usual with Julia just run

] add https://github.com/LudwigBoess/DSAModels.jl

Usage

To use for example the mach number dependent model by Kang & Ryu (2013), combined with the shock obliquity model by Pais et. al. (2019)

using DSAModels

ηM_model = KR13()  # Mach number dependent model
Mach = 5.0         # we assume a Mach 5 shock
θ_B  = 0.1π        # angle between shock normal and magnetic field vector
X_cr = 0.0         # X_cr = P_cr / P_th -> in this case no pre-existing CRs

# magnetic field angle dependent acc. efficiency
ηB   = ηB_acc_p(θ_B)  

# Mach number dependent acc. efficiency
ηM   = η_Ms(ηM_model, Mach, X_cr)

# total efficiency
η_tot = ηB * ηM