General Relativistic Maxwell Equations for Curved Spacetime Electrodynamics with Lanyon
Highlights
- End-to-end formally verified solvers for the general relativistic Maxwell equations and perfectly hyperbolic general relativistic Maxwell equations (with electric and magnetic divergence error correction), for electrodynamics in curved spacetime, in 1D, 2D, and 3D.
- Took ~340 seconds for Lanyon to generate everything.
- ~31 seconds for the general relativistic Maxwell equations in 1D, ~54 seconds for the general relativistic Maxwell equations in 2D, ~71 seconds for the general relativistic Maxwell equations in 3D, ~37 seconds for the perfectly hyperbolic general relativistic Maxwell equations in 1D, ~61 seconds for the perfectly hyperbolic general relativistic Maxwell equations in 2D, ~86 seconds for the perfectly hyperbolic general relativistic Maxwell equations in 3D.
- Real-time screen captures are shown in
/screencaps.
- 24,614 lines of Lean 4 code to prove end-to-end correctness properties.
- 1,966 for the general relativistc Maxwell equations in 1D, 3,710 for the general relativistic Maxwell equations in 2D, 5,532 for the general relativistic Maxwell equations in 3D, 2,342 for the perfectly hyperbolic general relativistic Maxwell equations in 1D, 4,440 for the perfectly hyperbolic general relativistic Maxwell equations in 2D, 6,624 for the perfectly hyperbolic general relativistic Maxwell equations in 3D.
- 270 total definitions and 156 total theorems.
- 11,730 lines of formally verified C code.
- 1,001 for the general relativistic Maxwell equations in 1D, 1,798 for the general relativistic Maxwell equations in 2D, 2,641 for the general relativistic Maxwell equations in 3D, 1,150 for the perfectly hyperbolic general relativistic Maxwell equations in 1D, 2,080 for the perfectly hyperbolic general relativistic Maxwell equations in 2D, 3,060 for the perfectly hyperbolic general relativistic Maxwell equations in 3D.
Further Details
In a generic curved spacetime (decomposed into spacelike hypersurfaces via the ADM decomposition), the general relativistic Maxwell equations of covariant electromagnetism combine a pair of hyperbolic evolution equations:
$$ \frac{\partial \mathbf{B}}{\partial t} + \nabla \times \left( \alpha \mathbf{D} + \boldsymbol\beta \times \mathbf{B} \right) = 0 $$
$$ \frac{\partial \mathbf{D}}{\