Skip to main content

warpax

arXiv DOI CI Python 3.12+ License: MIT

Observer-robust energy condition verification for warp drive spacetimes.

warpax decides the energy-condition structure of warp-drive spacetimes for every observer at once, from the eigenstructure of the mixed stress-energy tensor $T^a{}_b$, with exact curvature from JAX forward-mode autodiff. The decision uses only the boost-invariant eigenvalues of $T^a{}_b$ and never requires the coordinate-stationary observer $\partial_t$ to be timelike, so it stays well-defined at all warp speeds, including superluminal $v_s \ge 1$ where $\partial_t$ turns spacelike and single-frame tools such as WarpFactory break down. Each Hawking-Ellis type is decided the same way: a $4\times4$ linear matrix inequality $\hat T + \sigma\eta \succeq 0$ over every timelike and null observer, with no rapidity cap and no classification tolerance, and each verdict backed by an exact rational certificate.

Alcubierre warp bubble: Eulerian energy density embedding and observer-robust NEC-margin slab

An Alcubierre warp bubble. The wireframe is the Eulerian energy density, negative everywhere across the wall (ρEul ≤ 0); the slab beneath is the NEC margin minimized over the whole null sphere, which never rises above zero. The sweep sharpens the wall (σ: 1 → 16), then eases the velocity toward flat space. Both fields span about three decades over the sweep, so height and colour are on a signed log scale: monotone and sign-preserving, but not proportional.

Features

  • Frame-independent, all-observer energy-condition certification at every warp speed (including superluminal $v_s \ge 1$), from the eigenstructure of $T^a{}_b$, exact and cap-free for every Hawking-Ellis type.
  • Hawking-Ellis classification (Type I-IV) with explicit Type-IV detection, cross-checked by two eigensolver backends against a 50-digit mpmath reference.
  • Exact decision at Type-III/IV points from the absence of a causal eigenvector, with a closed-form Eulerian null witness for the momentum-sourced case; a closed-form Type-I worst observer and a multistart BFGS optimizer serve only to display violation severity.
  • Momentum-density control of the wall type through the discriminant $\Delta=(\rho+S_\parallel)^2-4|j|^2$: a negative discriminant sends a point to Type IV, and the same momentum density sets the wall NEC deficit and curvature scaling.
  • Rigorous geodesic-integrated ANEC via a symplectic null integrator (with an on-cone witness), plus a Ford-Roman quantum-inequality diagnostic.
  • Bondi four-momentum radiated-flux and Newman-Penrose peeling at null infinity (warpax.bondi).
  • Exact curvature via forward-mode JAX autodiff, no finite-difference stencils.
  • Ten warp/shell metrics, constraint residuals, anisotropic TOV, ADM mass with falloff, Israel junctions, transport diagnostics, and source-first S-/T-shell construction with a five-criterion admissibility standard.

Two papers, one toolkit

warpax backs two separate papers with disjoint claims. If you cite a result, cite the paper it belongs to:

Certification paper (arXiv:2602.18023) Companion note (arXiv:2605.25417)
Question Which observers see energy-condition violations, at which warp speeds? Can source-first shells satisfy the energy conditions at all?
Results Frame-free all-velocity certifier; velocity-resolved type map; momentum-density discriminant controlling the wall type; closed-form worst observer; exoticity ranking + two-term $v_s$ deficit law S-/T-shell constructions from the Einstein constraints; five-criterion admissibility standard; boundary-cost analysis
Modules energy_conditions, geometry, averaged, quantum, analysis, geodesics, transport; metrics Alcubierre / Natário / Van den Broeck / Rodal / Lentz / WarpShell / Garattini constraints (S-/T-shell solvers), tov, adm, junction, design, optimization; metrics/sshell.py, metrics/tshell.py
Examples 01-07 08-10

The S-/T-shells are constructed and certified in the companion note, not in the certification paper; neither paper's results depend on the other's.

Quick start

# Create environment and install
conda create -n warpax python=3.12 -y && conda activate warpax
pip install -e ".[dev,viz,design,solver]"

# Run a quick example
python examples/01_minkowski_sanity.py

See examples/README.md for a numbered learning path (01-10) and which optional extras each script needs.

For a 5-10 minute walkthrough from install to seeing an energy condition violation, see the Quickstart tutorial.

Key results

Frame-independent type map across the luminal transition

On matched, wall-resolved grids, the Rodal irrotational geometry is globally Hawking-Ellis Type I at every speed from $v_s = 0.1$ to $2.5$, while the Alcubierre/Natário/Van den Broeck bubble walls are Type-IV dominated (no rest frame, no invariant energy density) at every speed. The split is controlled by the Eulerian momentum density through the discriminant $\Delta=(\rho+S_\parallel)^2-4|j|^2$: an irrotational shift carries no wall momentum and stays globally Type I, while a vortical shift drives $\Delta<0$ and the wall to Type IV. For Rodal's globally Type-I drive the Eulerian frame does not register ~73% of the wall weak-energy and ~74% of the wall dominant-energy violations seen by boosted observers, an exact eigenvalue statement rather than an optimizer artifact. A rigorous geodesic-integrated ANEC (symplectic integrator with an on-cone witness) and a Ford-Roman comparison preserve the ordering: every drive violates, and the irrotational Rodal geometry is the mildest by one to two orders of magnitude.

Composite exoticity ranking and scaling laws

A composite exoticity ranking on the benchmark slice, from observer-independent inputs (NEC severity, Type-IV fraction, rigorous ANEC minimum), places the irrotational Rodal drive nearly two orders of magnitude below the bubble-wall drives (index 0.010 against 0.70 to 1.00), driven by its vanishing Type-IV fraction and tiny averaged-null energy, not by a milder pointwise NEC. The wall NEC deficit follows the two-term law $\min(\rho+p_i) = -C,v_s^2 - D,v_s$, single-term for the irrotational Rodal drive ($D=0$) and with a vorticity-set linear correction for the vortical walls, in line with the Santiago-Schuster-Visser no-go. The wall curvature splits by the same vorticity: vortical walls grow as $v_s^2$, the irrotational Rodal wall as $v_s^4$ ($R^2 \ge 0.99$).

Observer-robust vs Eulerian

Conditional on a violation existing, the Eulerian frame misses up to 29% of the DEC-violating points and 76% of the SEC-violating points across the tested drives (results/comparison_table.json).

Custom metrics

Subclass ADMMetric and run the full pipeline. The figure below validates a Gaussian warp bubble on a 24x24x4 grid: SEC margins from the Eulerian observer (left), from the worst-case boosted observer found by BFGS (center), and the 1496 grid points the Eulerian frame reports as SEC-satisfied while the boosted observer sees them violated (right). Regenerate it with python examples/07_custom_warp_metric.py --readme-figure.

Gaussian Warp Grid Comparison

SEC comparison for a custom Gaussian warp bubble (vs = 0.5). Red marks violations the Eulerian frame misses.

See examples/07_custom_warp_metric.py.

Shell admissibility

warpax ships a five-criterion admissibility standard for warp shells:

Criterion Checks
A. Regularity $C^2$ metric continuity (thick) or Israel conditions (thin)
B. Constraints Hamiltonian + momentum residuals $\epsilon_{\mathcal{H}}$, $\epsilon_{\mathcal{M}}$
C. Matter model Identifiable source (anisotropic fluid, elastic shell)
D. EC margins Frame-free NEC/WEC/DEC from Hawking-Ellis eigenvalue slacks (exact, cap-free at Type-I; valid at all $v_s$)
E. Global Positive ADM mass, asymptotic falloff, tidal forces, invariant transport

Fuchs constant-velocity shell: source-aware $\epsilon_{\mathcal{H}} \approx 3\times10^{-8}$; the bulk shell interior is Type-I and EC-compliant (0 of 13 probes violate), while the smoothing tail turns Type-IV. The source-first S-/ T-shells likewise pass criteria A-C and E with positive interior margins; the binding cost is a cap-free Type-I dominant-energy deficit at the inner shell edge ($\approx -4.4\times10^{-4}$), localized at the smooth source-vacuum transition, and the tilted T-shell's shift vorticity drives a Type-IV onset at its low-density edge. These shell results belong to the companion note; see The boundary cost of source consistency.

Examples

See examples/README.md for runtime estimates, install extras, and a suggested order for new users.

Script Description
01_minkowski_sanity.py Flat-space sanity check (all ECs satisfied)
02_schwarzschild_verification.py Schwarzschild ground-truth validation
03_alcubierre_analysis.py Alcubierre warp drive EC analysis (quickstart entry)
04_warp_drive_comparison.py Multi-metric comparison (six warp drives)
05_grid_analysis.py Grid-based EC verification + comparison figure
06_geodesic_through_warp_bubble.py Geodesic integration with tidal forces
07_custom_warp_metric.py Custom warp manifold + robust EC validation
08_metric_design.py Shape-function metric design (B-spline reproduction)
09_admissibility_diagnostics.py Admissibility diagnostics on the Fuchs warp shell
10_phase_diagram.py Parameter-space sweep and EC-admissible transport phase diagram
python examples/01_minkowski_sanity.py
python examples/10_phase_diagram.py          # 8x6 demo (~2 min)
python examples/10_phase_diagram.py --full   # 20x15 sweep (~30 min GPU)

Architecture

metrics -> geometry -> energy_conditions -> analysis
              |              |
          geodesics    classification (Hawking-Ellis)
              |
         transport / tidal / blueshift
Package Description
geometry JAX autodiff pipeline: metric $\to$ Christoffel $\to$ Riemann $\to$ Ricci $\to$ Einstein $\to$ $T_{\mu\nu}$; ADM 3+1 split; $C^2$ regularity diagnostics
energy_conditions NEC/WEC/SEC/DEC via Hawking-Ellis classification, eigenvalue algebra, multi-start BFGS observer optimization
grids Non-uniform grid generators; wall-clustered sampling that resolves a bubble wall without a uniform refinement everywhere
metrics Nine warp/shell metrics: Natário, Lentz, Rodal, Van den Broeck, WarpShell, Fuchs, S-shell, T-shell, Garattini-Zatrimaylov (Alcubierre, Minkowski, and Schwarzschild ship in benchmarks, making ten warp metrics total)
constraints Hamiltonian + momentum constraint residuals; S-shell and T-shell constraint solvers (pure JAX)
tov Anisotropic TOV equilibrium checker
adm ADM mass with surface integral and asymptotic falloff verification
junction Israel/Darmois junction conditions and surface stress-energy
transport Invariant diagnostics: geodesic deviation, null coordinate-time asymmetry, blueshift hazard
optimization Bernstein basis, multi-objective loss, EC soft/hard constraints, parameter sweep
geodesics Timelike/null geodesic integration via Diffrax, tidal deviation, blueshift extraction
design Differentiable shape-function parametrization with constrained BFGS optimizer
analysis Eulerian vs. robust comparison, convergence tools (stability spreads + continuum polishing of wall extrema, analysis.extrema), kinematic scalars
io External metric loaders: WarpFactory (.mat), EinFields (checkpoint), Cactus (HDF5)
visualization Matplotlib publication figures, Manim animations, phase diagram plots
classify Bobrick-Martire subluminal/superluminal taxonomy
averaged ANEC/AWEC null-ray and geodesic line integrals
quantum Ford-Roman quantum inequality evaluator
bondi Bondi four-momentum, radiated flux, and Newman-Penrose peeling at null infinity
benchmarks Reference spacetimes (Alcubierre, Minkowski, Schwarzschild). Distinct from the top-level benchmarks/ asv harness
numerics Shared numerical utilities: constants, regularity floors, autodiff-safe helpers

All metrics implement a common MetricFunction interface: a callable (4,) -> (4,4) mapping coordinates $x^\mu$ to the covariant metric tensor $g_{\mu\nu}$.

Running tests

pytest                      # Whole suite, ~3 min (1090 tests, parallel by default)
pytest -m smoke             # Visualization import / render smoke tests
pytest tests/test_slemma.py # One module

One tier only: -n auto comes from pyproject.toml, and no test is excluded by default.

Reproducing results

To pin the exact Python environment used to produce the published results:

export PYTHON=$(uv run which python)
bash reproduce_all.sh

Stages can be run individually:

bash reproduce_all.sh --stage core      # Core computation
bash reproduce_all.sh --stage ablation  # Ablation studies
bash reproduce_all.sh --stage figures   # Figure generation

Use --keep-cache to skip cache deletion and only recompute missing results.

Per-paper reproduction guides map every figure, table and quoted number to the script that produces it:

The outer-edge ($r \ge R_2$) Type-IV verification (log-log slope $1.01 \pm 0.01$) and the ANEC impact-parameter scan are reproduced by scripts/run_tshell_typeIV_onset.py and scripts/run_anec_impact_scan.py.

Documentation

warpax ships full documentation in docs/, organized following the Diataxis framework:

Tutorials

How-to guides

Reference

Explanation

Manim visualizations

Every scene comes from the same curvature and energy-condition code as the papers. Geometric units on the z = 0 slice; each frame is a frozen metric, a parameter sweep rather than a time evolution.

Expansion theta = -K and shear of the Eulerian congruence Kretschmann curvature invariant Eulerian vs observer-robust NEC margin
Eulerian kinematics. Expansion θ = −K: space stretches behind the ship (red) and squeezes in front (blue). Shear σ² as iso-contours, with the f = 0.5 wall on top. Kretschmann invariant. K = RabcdRabcd, the same for every observer. Sign-indefinite in Lorentzian signature, so it dips negative, and spikes on the wall. Observer-robust NEC. Six axis-aligned Eulerian nulls on the left, the worst case over the whole null sphere on the right (k·nEul = −1). The gap is what observer-robust verification buys.

The full set: WallAndVelocitySweep / VelocitySweep (dual-layer 3D, ρEul above a NEC-margin slab), BoostRapiditySweep (energy density vs rapidity ζ, deepening as cosh²ζ), EulerianKinematics2D, KretschmannInvariant2D, NECMargin2D / EulerianVsWorstCaseNEC, and WorstCaseNullDirections / WorstCaseBoostDirections.

# System dependencies (Ubuntu/Debian)
sudo apt install texlive-latex-extra texlive-fonts-recommended dvipng cm-super ffmpeg gifsicle

# Python dependencies (Python <= 3.13 recommended for the renderer)
pip install -e ".[manim]"

# Render all scenes (2D via Cairo, 3D via the GPU OpenGL renderer)
python scripts/render_all_scenes.py

Rendered videos and images are written to media/ (not tracked by git). The 3D scenes render through manim's OpenGL renderer (EGL, headless).

Citation

If you found this work useful, please consider citing:

@article{le2026observer,
  title={Observer-robust energy condition verification for warp drive spacetimes},
  author={Le, An T},
  journal={arXiv preprint arXiv:2602.18023},
  year={2026}
}

@article{le2026boundary,
  title={On the boundary cost of source-consistent warp shells},
  author={Le, An T},
  journal={arXiv preprint arXiv:2605.25417},
  year={2026}
}

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

warpax-1.4.0.tar.gz (524.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

warpax-1.4.0-py3-none-any.whl (427.9 kB view details)

Uploaded Python 3

File details

Details for the file warpax-1.4.0.tar.gz.

File metadata

  • Download URL: warpax-1.4.0.tar.gz
  • Upload date:
  • Size: 524.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for warpax-1.4.0.tar.gz
Algorithm Hash digest
SHA256 df5d58a3cdf90b4b5eaf7e4c3de214a14991822195efa72c27614d892abb9f0b
MD5 40a67d2df4f9eba52567f93ad70e8f44
BLAKE2b-256 0ad92ef04810e9a3c30253f7da86969dc097d4d194709f451e336aa8d5fd89ac

See more details on using hashes here.

Provenance

The following attestation bundles were made for warpax-1.4.0.tar.gz:

Publisher: release.yml on anindex/warpax

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file warpax-1.4.0-py3-none-any.whl.

File metadata

  • Download URL: warpax-1.4.0-py3-none-any.whl
  • Upload date:
  • Size: 427.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for warpax-1.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b5b92b78af3dff92165cb56c5a73f100f4be7ff353bcc9a04e2594783d6d92fe
MD5 fcdc660505fd48e91369d35a71689b1e
BLAKE2b-256 2b7c55e43fc720ab463489fe744d761ab0b0dbc9c85964bd256d97a751036318

See more details on using hashes here.

Provenance

The following attestation bundles were made for warpax-1.4.0-py3-none-any.whl:

Publisher: release.yml on anindex/warpax

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

1.4.0 This release

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page