arXiv:2610.07159
Magnus: neutrino oscillation probabilities for any Hermitian Hamiltonian, any number of flavors, and any matter profile
Mauricio Bustamante
Abstract
Interpreting neutrino oscillation measurements requires computing the probability that a neutrino born with one flavor is detected with another. In vacuum and in matter of constant density, this probability has exact formulas. Where the density varies along the path, as in the Earth, the Sun, or a supernova, it does not. There, the usual approaches either replace the profile by constant-density steps, whose error falls only as the square of their width, or integrate the evolution equation with a general-purpose solver, which must shorten its steps to meet a tighter tolerance. Both become slow at high accuracy, yet an analysis needs the probability at many energies, directions, and parameter values. Each new experiment or model often requires writing and validating a new solver. We present Magnus, an open-source Python code that avoids these limitations. It uses the Magnus expansion, whose error falls as a high power of its step width and whose cost is set by how fast the density varies, not by how many oscillations the path holds. Magnus accepts any density profile, any number of flavors, and any Hermitian Hamiltonian, such as those of non-standard interactions, sterile neutrinos, Lorentz-invariance violation, and pseudo-Dirac neutrinos. Where a cheaper route exists, it takes it automatically. For example, where the density varies slowly, as in the Sun, it follows the instantaneous eigenstates and applies the expansion only at resonances. Besides oscillating probabilities, Magnus returns phase-averaged ones, which describe solar and astrophysical neutrinos. A typical probability takes a few milliseconds, and batched scans are one to two orders of magnitude cheaper per point. Among the public codes we compared, Magnus is the fastest at high accuracy on a varying profile. Magnus shifts the effort of studying a new experiment or model from writing a solver to specifying its physics.
AI Summary
Computing neutrino flavor-transition probabilities through varying matter requires integrating a position-dependent Schrödinger equation, often repeatedly across parameter scans. This paper presents Magnus (`magnuspy`), an open-source Python package accepting an arbitrary Hermitian Hamiltonian and any number of flavors, with wrappers for standard oscillations and several beyond-standard-model scenarios. The numerical core composes unitary slab propagators built from established Magnus-expansion integrators. Gauss–Legendre schemes reach global orders $2,4,6,8$; a cumulative-quadrature implementation retains up to ten Magnus terms. Slab refinement compares successive probability matrices against requested tolerances, with boundaries aligned to declared discontinuities. Specialized routes include constant-Hamiltonian exponentiation, batched scans, and adiabatic eigenstate transport with Magnus patches around nonadiabatic crossings. The package also computes phase-averaged probabilities, retaining partially coherent interference under an approximate energy-resolution model. Validation against independent DOP853 integrations at two to five flavors gives probability differences of a few parts in $10^{12}$ on a smooth exponential profile. Benchmarks report millisecond-scale individual probabilities and one-to-two-order-of-magnitude reductions per point for batched scans. Among eight compared codes, Magnus is fastest at high accuracy on the tested varying Earth profiles; specialized codes remain cheaper at constant density or coarse accuracy. Hermiticity excludes decay, absorption, and open-system decoherence; nonlinear collective oscillations are also unsupported. Successive-grid agreement is not a rigorous error bound, and unresolved narrow features can evade convergence checks. Adiabatic certification has analogous limitations. Phase averaging freezes eigenvectors and linearizes energy-dependent phases; declared discontinuities instead trigger an energy-window average, a different observable.
the author used Claude for research assistance in code development, numerical auditing, workflow documentation, repository maintenance, and editorial revision.
Central claim may not hold: The abstract claims computational cost does not depend on the number of oscillations, but the general Magnus engine uses phase-dependent slab counts and the body explicitly acknowledges that its cost grows with accumulated phase. The abstract's high-power error scaling is conditional on sufficient smoothness within slabs, whereas an unresolved discontinuity can reduce convergence to approximately first order regardless of the selected Magnus order.
Written by gpt-6.1-sol from the paper's full text. Automated: it can be wrong.
- Comments
- 92 pages, 43 figures, plus code listings and appendices. Full documentation: https://mbustama.github.io/Magnus/