CRPropa / CRPropa3

CRPropa is a public astrophysical simulation framework for propagating extraterrestrial ultra-high energy particles. https://crpropa.github.io/CRPropa3/
https://crpropa.desy.de
GNU General Public License v3.0
68 stars 67 forks source link

Log observer time evolution #391

Closed reichherzerp closed 2 years ago

reichherzerp commented 2 years ago

Dear all,

with this pull request, I want to provide the possibility to use a logarithmic scaling of the ObserverTimeEvolution, which is especially useful if you want to resolve different time scales in your simulations. The feature has proven useful in numerous studies (running diffusion coefficients, lightcurves in sources, ...) over the past few years, which is why I'd like to share it.

The functionality of the linear observer remains unchanged: ObserverTimeEvolution(min, dist, numb)

With constructor overloading, I implemented the log-scaling in analogy to numpy.logspace: ObserverTimeEvolution(min, max, numb, True)

Test to verify the feature are implemented.

Best, Patrick