Leviathan

The content on this page was written by AI under human supervision.

Leviathan finds the Landau singularities of a family of Feynman integrals: the polynomial conditions on the external invariants and masses under which the integrals can become singular. It takes the Lee–Pomeransky polynomial of the diagram with the names of its kinematic parameters and integration variables. It returns the number of master integrals sector by sector, a list of candidate singularity polynomials, and a verdict on each candidate from an explicit test. The method is the Euler-characteristic-drop criterion of Chestnov, Crisanti and Giroux (arXiv:2606.29612); Leviathan is BootLoops' own Julia implementation, written from the papers and sharing no code with the authors' programs.

What it does

A Feynman integral is analytic in its kinematic variables away from its Landau singularities, for example $s-4m^2=0$ for the one-loop bubble. Knowing them in advance fixes where thresholds and branch points can sit and supplies the arguments of the logarithms (the symbol letters) from which the answer is built; Leviathan finds them by counting. Write the integral in Lee–Pomeransky forma representation with a single polynomial G = U + F in the Feynman parameters, U and F being the two Symanzik graph polynomials of the diagram with polynomial $G$. With generic, non-integer propagator powers and dimension, the critical-point equations of $G$ have finitely many solutions; their number is the Euler characteristichere, the number of isolated solutions of the regulated critical-point equations of G; for a Feynman family it equals the number of master integrals, the finite basis to which every integral of the family reduces $\chi$, equal to the number of master integrals and constant at generic kinematics. The Landau singularities are exactly the loci where $\chi$ drops.

The landau pipeline has three steps. It counts $\chi$ of the regulated family and $\chi_S$ of every sector $S$ (a subset of propagators, the rest removed by setting their Feynman parameters to zero). Each count is done at a random kinematic point modulo a 31-bit prime, from a Gröbner basis (msolve's F4 algorithm, called through Oscar) and a count of standard monomials, and the report checks $\chi=\sum_S\chi_S$. It generates candidates exactly, over rational functions of the kinematic parameters. For each Feynman parameter it computes the monic minimal polynomial in the quotient ring of the critical-point ideal (the object of the SPQR method, arXiv:2511.14875); the irreducible factors of the denominators of its coefficients are the candidates. Every sector is treated twice, once at zero propagator powers and once with the regulated ideal, because only the regulated pass sees second-type singularities (those not attached to a set of on-shell propagators, such as $s=0$ for the bubble). It then verifies each candidate $\ell$ by recomputing $\chi$ at random points on $\ell=0$: genuine if $\chi$ falls below the generic value, spurious if not, unverified if no point on the locus was found modulo any of ten primes.

The four consistency checks of the paper's Appendix A are included, callable singly or together through diagnose, each returning pass or fail with evidence. They are: zero-dimensional sector ideals (type 1.1), a no-degeneracy test that flags singularities the zero-power pass can miss (type 1.2), $\chi$ additivity (type 2.1), and the drop test itself (type 2.2). Cut propagators are declared with a cut = line and handled throughout. For families where the exact Gröbner basis is out of reach, landau_reconstruct obtains the same minimal polynomials by sampling them at many (prime, kinematic point) pairs and reconstructing each coefficient as a rational function, then applies the same drop test. That route needs $G$ jointly homogeneous in the kinematic parameters with the one dimensionful scale listed last. It sets that scale to 1 while sampling and restores it by degree, so setting $m^2=1$ in the input yourself silently breaks the result. Sampling is serial inside a process, because the underlying Gröbner routines are not thread-safe; run several processes for parallelism.

Candidates from the exact route are exact polynomials. The $\chi$ counts and the verdicts are computed modulo primes at random parameter values, so they are correct with probability very close to one rather than proven. A positive-dimensional sector is reported Indeterminate and skipped with a warning. Three parts of the published method are not implemented (the SPQRDet route, the four-dimensional restriction, the FiniteFlow Macaulay-matrix reconstruction), and Leviathan does not compute the integral or its differential equation. PLD and SOFIA and Landau Alphabet reach the same locus by unrelated methods and serve as cross-checks; Dipstick, including its expansion-by-regions completeness check (dipstick regions), reuses Leviathan's $\chi$ count.

Examples

The one-loop bubble from the command line. The input file examples/bubble.in that comes with the package is

# one-loop equal-mass bubble, Lee-Pomeransky G = U + F
G   = x1 + x2 + mm*(x1+x2)^2 - s*x1*x2
kin = s, mm
x   = x1, x2

and the full pipeline, run from the package directory, is

julia +1.10 --project=. leviathan.jl landau examples/bubble.in

which prints

chi (regulated, generic) = 3
  chi_S [1] = 1
  chi_S [2] = 1
  chi_S [1, 2] = 1
  sum over sectors = 3  [additivity OK]
candidate factors: ["mm", "s", "s - 4*mm"]
  genuine   : ["mm", "s", "s - 4*mm"]
  spurious  : String[]

Three master integrals, one per sector, and three singularities: the vanishing mass, the second-type point $s=0$ and the normal threshold $s=4m^2$, each confirmed by a $\chi$ drop. For an example this small, loading Oscar takes about as long as the computation itself, roughly half a minute each. Replace landau by chi for the counts alone, candidates for the candidate factors before verification, or diagnose for the four checks with their evidence; an optional integer third argument sets the random seed.

The two-loop sunrise from Julia, with the checks. Condensed from test_sunrise.jl:

include(joinpath(@__DIR__, "src", "Leviathan.jl"))
using .Leviathan, Random

rng = MersenneTwister(20260630)
fam = family("x1*x2 + x1*x3 + x2*x3 + s*x1*x2*x3 - mm*(x1+x2+x3)*(x1*x2+x1*x3+x2*x3)",
             ["s", "mm"], ["x1", "x2", "x3"])
r = landau(fam; rng=rng)
print(report(r))
d = diagnose(fam; rng=rng, candidates=r.candidates)

r is a LandauResult: r.chi_sectors[[1, 2, 3]] is the top-sector count (4, with $7=4+1+1+1$ over all sectors) and r.genuine the verified singularities. The test requires these to be exactly s, mm, s - mm, s - 9mm, which include the pseudo-threshold $s=m^2$ and the three-particle threshold $s=9m^2$, with r.spurious empty. d maps each check name, type1.1_sector_dim through type2.2_candidate_verification, to a (pass, evidence) pair; all four pass here, while on the bubble type 1.2 fails by design and names $s$, the second-type singularity only the regulated pass finds. The drop test takes any polynomial: test_leviathan.jl calls diag_type22(fam, ["s - 17mm"]; rng=rng) on the bubble, a deliberately wrong input, and gets back false with s - 17*mm listed as spurious.

The reconstruction route. From test_reconstruct.jl, the bubble by sampling instead of exact elimination:

fam = family("x1 + x2 + mm*(x1+x2)^2 - s*x1*x2", ["s","mm"], ["x1","x2"])
rr = landau_reconstruct(fam; nprimes=3, npoints=20, deg_cap=6, lanes=(:nu0,:regulated))

Three primes, twenty sample points per prime, reconstructed degree at most 6, both passes. The test requires Set(rr.genuine) == Set(["mm","s","s - 4*mm"]), the answer of the exact route; mm, the dimensionful scale, is last in the kinematic list, as this route requires.

Routines

Command-line scripts

Julia module Leviathan (include("src/Leviathan.jl"))

Used on this site

Requirements and source

Julia 1.10 with Oscar 1.7 (which brings msolve, Singular and FLINT) and the JSON package; nothing proprietary. The package directory carries a Project.toml: instantiate it once, then run every script with --project=.. Tests: julia +1.10 --project=. test_leviathan.jl (add --full for the sunrise), which ends with ALL TESTS PASSED, and julia +1.10 --project=. test_reconstruct.jl; test_smoke.jl runs the bubble alone, about half a minute after Oscar has loaded; julia test_staircase.jl tests the counter on plain Julia without Oscar and ends with STAIRCASE PASS. builder.jl also needs PLD by Fevola, Mizera and Telen (mathrepo.mis.mpg.de/PLD). Source: upgrades/leviathan/ in BootLoops' bootloops-dev repository (GitHub organization BootLoops-ai), released under the MIT license. PATCHES.md there states the relation to the papers (arXiv:2606.29612, arXiv:2511.14875) and to the authors' reference code, which carries no license and served only as documentation and as a source of published test values. Gröbner bases are computed by msolve (Berthomieu, Eder, Safey El Din) through Oscar.

← back to the tools index