Skip to main content

Code Guide: Geometric Unity

← Technical note · Papers archive

R. Fisher · Braid Dynamics Applied Research Group · November 17, 2026

Guide PDF · Guide Markdown · Computational supplement (Markdown) · Source archive (ZIP)

1. Files and contents​

The verification material accompanies the technical note Clifford Contractions and the First-Order Bosonic Action in Geometric Unity. It consists of the complete source in a Markdown computational supplement, an archive of source files and license terms, and this guide.

The text and figures in the note and companion documents are licensed under CC BY 4.0. The software and project configuration files, including source listings embedded in the computational supplement, are licensed under the MIT License. The archive's README.md specifies the scope of these grants, with full terms in LICENSE-CC-BY-4.0.txt and LICENSE-MIT.txt.

MaterialFiles and contents
Technical notefisher-geometric-unity-2026-11-17.pdf and fisher-geometric-unity-2026-11-17.md. The mathematical paper in PDF and Markdown.
Computational supplementfisher-geometric-unity-2026-11-17-computational-supplement.md. All forty Lean files, the Python program, the three project configuration files, the archive README, and both full license texts, with a linked file index and a summary for each listing.
Source archivefisher-geometric-unity-2026-11-17-code.zip. The same files, ready to extract and run.
Code guidefisher-geometric-unity-2026-11-17-code-guide.pdf and fisher-geometric-unity-2026-11-17-code-guide.md. This guide's file descriptions, execution instructions, result index, and benchmark tables.

Read the file descriptions to locate a proof, the execution instructions to run the archive, or the benchmark tables to compare numerical results. The computational supplement can also be read directly or supplied as a single text document for source review.

2. Running the source archive​

The Python program and Lean proofs can be run independently after extracting the archive.

Extract the project​

Download and extract the source archive. It contains a directory named gu-code. All commands below run inside that directory, which contains GU-test.py, lakefile.toml, and the Lean files.

cd gu-code

The archive also contains README.md, both license texts, and SHA256SUMS, a manifest of the SHA-256 digests of every other archived file. Each archived file matches its listing in the computational supplement, using UTF-8 text and Unix line endings.

Run the Python checks​

Install Python and NumPy, then run the verification program. The recorded benchmark used Python 3.13.1 and NumPy 2.3.3.

python -m pip install numpy==2.3.3
python GU-test.py

The program prints six groups of checks, labeled V1 through V6, and ends with ALL 6 VERIFICATION GROUPS PASSED when they pass. The benchmark took about three minutes and recorded a peak Python allocation of about 1.3 GiB. Runtime and floating-point residuals depend on the machine and numerical libraries. The exact checks and the measured residuals are identified in the benchmark tables.

Check the Lean proofs​

Install Git and Elan, the Lean toolchain manager. The file lean-toolchain selects Lean 4.33.1. Mathlib v4.33.1 and its exact dependency revisions are recorded in lakefile.toml and lake-manifest.json. The project contains 39 Lean library targets and the separate audit module Audit.lean, for a total of 40 Lean files.

Run these commands in the extracted gu-code directory. The first downloads precompiled Mathlib files, the second checks the project with warnings treated as errors, and the third prints the axiom dependencies of the indexed results.

lake exe cache get
lake --wfail build
lake env lean -DwarningAsError=true Audit.lean

The first use needs an internet connection to obtain the toolchain and dependencies. A successful build ends with Build completed successfully. The audit declarations use propext, Classical.choice, and Quot.sound, the standard Lean axioms recorded in the checked project.

To check the real classification alone, run the named target. Lake builds its dependencies automatically.

lake --wfail build D7RealTheorem

To check one source file directly, run Lean from the project directory.

lake env lean -DwarningAsError=true D7RealTheorem.lean

Open the project in Visual Studio Code​

Install the Lean 4 extension and open the extracted gu-code directory as the workspace folder. Open a Lean file, then use the Lean Infoview to inspect a theorem and its proof. Place the cursor inside a proof to see the local goals.

The terminal build and Audit.lean provide the project-wide check. An empty Infoview after the closing namespace reports the cursor's current location.

3. Mathematical coverage​

The real classification is assembled in D7RealTheorem.lean. Its declaration theorem_3_4 proves the real dimensions 200, 96, 56, and 48, the 96-dimensional Bianchi subspace, and equivalence with vanishing divergence on every closed coordinate two-form with coefficients in the modeled unitary real form.

The proof begins with complex exterior representations, establishes their intertwiner dimensions, identifies the real Spin action on the coefficient matrices, and transports the dimensions to that action. The real first-jet model then identifies closed inputs with the kernel of alternation. Restriction to the alternating, vector, and traceless-hook channels gives the classification in the note.

Theorem 5.2 uses a finite index set, coefficients in an associative real algebra, and an integrated cyclic trace. Its mixed-term boundary identity is supplied by Stokes' theorem in the geometric setting. Stationarity also requires separation by admissible variations. Witness W1 uses the Clifford algebra of signature (7,7)(7,7) and the normalization Tr⁡(I)=128\operatorname{Tr}(I)=128.

The Noether formalization proves finite gauge invariance and uses dual numbers for the dressing differential. The commuting derivations are ordinary coordinate derivatives. The reference connection carries its own curvature. The paired identity assumes the integrated boundary identities. The off-shell coefficient equality also assumes a dressing Euler representative and separation by admissible gauge tests.

The Python program supplies the numerical comparisons, matrix checks, and integer tables described in Section 6. The Lean declarations provide the formal results listed in Section 5.

4. Source file descriptions​

The filenames below are identical in the archive and in the computational supplement. Each filename links to its source listing. The groups follow the mathematical dependencies, with the main results listed first.

Main results and audit​

FileRole
Theorem52.leanDerives the first variation, stationarity criterion, and Einstein specialization under the stated boundary and separation hypotheses.
WitnessW1.leanConstructs the exact nonzero torsion correction in the split Clifford algebra and checks the test blade and trace pairing.
BianchiSymbol.leanIdentifies closed first jets, realizes them by closed linear two-forms, and proves unique factorization through alternation.
NoetherIdentity.leanProves finite gauge invariance, the dressing differential, and the paired and off-shell Noether identities under explicit hypotheses.
D7RealTheorem.leanAssembles real Theorem 3.4, including the dimensions 200, 96, 56, and 48 and the closed-field Bianchi criterion.
Audit.leanPrints the axiom dependencies of the indexed mathematical results.

Complex exterior representations​

FileRole
D7Counts.leanComputes signed integer multiplicities and verifies the fifteen grade rows and channel totals.
D7Classification.leanProvides general decomposition, intertwiner-dimension, block decomposition, and real-to-complex comparison lemmas.
D7Exterior.leanDefines the split complex orthogonal action and checks exterior weights, highest-weight candidates, and Weyl dimensions.
D7Hodge.leanConstructs the equivariant Hodge involution on the middle exterior power and its signed eigenspaces.
D7Irreducible.leanProves irreducibility of the non-middle exterior powers using signed coordinate actions.
D7VectorTensor.leanConstructs alternation, trace, and their sections and splits the vector times two-form representation into three channels.
D7Hook.leanProves irreducibility of the traceless hook representation.
D7VectorGrades.leanConstructs wedge and metric-contraction maps and their equivariant sections in all exterior degrees.
D7MiddleTensor.leanConstructs the two signed residual summands in the middle degree.
D7MiddleIrreducible.leanProves irreducibility of the signed middle residual summands.
D7TensorColumns.leanOrganizes repeated-index and distinct-index tensor coordinates used in the kernel arguments.
D7TensorRotations.leanCalculates the plane rotations that connect the two tensor-coordinate families.
D7GradeIrreducible.leanProves irreducibility of the non-middle vector-exterior kernels.
D7ComplementaryGrades.leanTransports exterior representations and their tensor kernels between complementary degrees by Hodge duality.
D7SignedDistinction.leanDistinguishes the two signed middle constituents using a diagonal torus action.

Multiplicity counts and complex symbols​

FileRole
D7TripleInvariants.leanClassifies invariant trilinear exterior forms and bounds the vector and alternating multiplicities.
D7TripleMultiplicity.leanRealizes the trilinear invariants and proves the vector and alternating totals of 56 and 96.
D7QuadInvariants.leanClassifies the invariant forms with a vector factor and three exterior factors.
D7QuadMultiplicity.leanRealizes the invariant four-factor forms needed for the unrestricted contraction count.
D7Unrestricted.leanIdentifies unrestricted intertwiners with invariant forms and proves the total dimension 200.
D7Final.leanAssembles the complex symbol channels, the Bianchi factorization, the hook count, and the general action-span comparison.
D7BianchiFields.leanMatches the complex tensor symbols to coordinate first jets and proves the closed-field criterion in every grade.

Real Spin and Clifford actions​

FileRole
D7UnitaryRealForm.leanModels skew-adjoint coefficient matrices as a real form and identifies their complexification.
D7SpinAction.leanDefines the real Spin vector and Clifford conjugation actions and their exterior-algebra identification.
D7CliffordMatrix.leanConstructs the split Clifford algebra as matrices on the 128-dimensional exterior spinor module.
D7CliffordAdjoint.leanIdentifies the matrix adjoint, checks Hermitian signature (64,64), and intertwines coefficient conjugation.
D7SpinNullFrame.leanChanges the real vector action into split null coordinates and maps its complexification into the orthogonal action.
D7SpinRootLifts.leanConstructs real Spin lifts of the isotropic root transvections.
D7SpinOrientation.leanProves that the real Spin vector action has determinant one.
D7RootInterpolation.leanUses polynomial interpolation to place complex split-root tensor actions in the span of real Spin actions.
D7RootGeneration.leanProves generation of the complex split special orthogonal action by split roots and extends the action-span result.
D7RealComparison.leanIdentifies the complexified real coefficient, form, and covector tensor actions with the complex exterior-grade actions.
D7RealJets.leanConstructs real coordinate first jets, wedge and trace projections, and their equivariant sections.
D7RealRanks.leanTransfers the complex intertwiner counts to the real operator and exterior-symbol spaces.

Program and project configuration​

FileRole
GU-test.pyRuns the six groups of computational and numerical checks reported in the benchmark tables.
lakefile.tomlDeclares the 39 Lean library targets and pins Mathlib to v4.33.1.
lake-manifest.jsonRecords the exact Mathlib and transitive dependency revisions for the portable project.
lean-toolchainPins Lean to leanprover/lean4:v4.33.1.

Publication and license files​

FileRole
README.mdRecords the publication DOI and citation, archive contents, and the scope of the text and software licenses.
LICENSE-CC-BY-4.0.txtContains the full Creative Commons Attribution 4.0 International terms for the text and figures.
LICENSE-MIT.txtContains the full MIT License and copyright notice for the software and project configuration files.

File names and declaration names​

A Lean filename identifies a source module. A theorem is identified by its namespace and declaration name. The files D7RealRanks.lean and D7RealTheorem.lean both contribute to the namespace GeometricUnity.D7RealTheorem. The result index gives the declaration name together with the file where it is defined.

5. Main Lean results​

Each row names the source file and the declaration to inspect. Add GeometricUnity., the namespace, and the declaration name to obtain the full name. The namespace normally matches the filename without its extension. The two results defined in D7RealRanks.lean use the namespace D7RealTheorem. For example, the real classification has the full name

GeometricUnity.D7RealTheorem.theorem_3_4
ResultSource fileDeclaration
Real Theorem 3.4D7RealTheorem.leantheorem_3_4
Closed-field equivalenceD7RealTheorem.leanmem_bianchi_iff_closed_fields
Alternating factorizationD7RealTheorem.leanbianchiEquiv
Traceless-hook projectionD7RealTheorem.leanmem_hook_iff_project
Real unrestricted dimensionD7RealRanks.leanunrestricted_dimension
Real alternating and vector dimensionsD7RealRanks.leanexterior_symbol_dimensions
First variationTheorem52.leantheorem_5_2
StationarityTheorem52.leanstationary_iff
Einstein specializationTheorem52.leaneinstein_euler
Exact torsion correctionWitnessW1.leancorrection_value
Nonvanishing of the correctionWitnessW1.leancorrection_ne_zero
Closed linear realizationBianchiSymbol.leanclosed_linear_realization
Unique alternating factorizationBianchiSymbol.leancompatible_iff_unique_factor
Finite gauge invarianceNoetherIdentity.leandressedAction_gauge
Paired Noether identityNoetherIdentity.leandressingDerivative_eq_divergence
Off-shell Noether identityNoetherIdentity.leantheorem_6_1

6. Benchmark results​

The benchmark run used Python 3.13.1 and NumPy 2.3.3 on Windows, with OPENBLAS_NUM_THREADS=4 and OMP_NUM_THREADS=4. All six verification groups passed. The tables report relative residuals unless a row specifies another quantity.

GroupCheckResult
V1Clifford relations and skew-adjointness under J′J'0
V1Eq. (3.27) checkerboard residual under JJ and under J′J'4.29, 0
V1Dimension of the compact derived algebra8190
V1Killing values on iIiI and iJ′iJ'0, -32768
V2Six-operator reductions to three-blade contractions, Einstein and commutator1.3e-16, 1.3e-16
V2Bianchi-compatible dimensions from SVD2, 4
V2Exact D7D_7 Bianchi, vector, and hook counts96, 56, 48

Curvature, action, and gauge checks​

GroupCheckResult
V3Einstein reconstruction4.79e-16
V3Contracted differential Bianchi identity, absolute norm9.41e-14
V3Gauge covariance, bare and dressed0.72, 3.05e-15
V4Dynamical Bianchi identity dAFA=0d_AF_A=01.11e-15
V4Reference divergence, Einstein and commutator2.43e-15, 2.40e-15
V4Direct dynamical divergence formula2.89e-15
V5Hodge involution, degrees 0 through 140
V5Uniform brackets in (9.3) on constant curvature, minimized over the target sign5/6, 1/65/6,\ 1/6
V5Reconstructed Einstein operator on general adjoint input3.99e-16
V5Algebraic comparison for ΔE0=−83γ01234\Delta E_0=-\tfrac83\gamma^{01234}0
V5Sparse variation with the full Euler derivative2.70e-10
V61D quadrature changes in action and Noether pairing, grids 8, 10, and 147.01e-16, 7.43e-15
V62D quadrature changes in action and Noether pairing, grids 8 and 101.35e-15, 1.49e-15
V6Volume-normalized kinetic action and radial derivative-128, -256
V6Mixed kinetic integration by parts7.37e-10
V6Commutator-sector kinetic and cubic bulk variations2.89e-10, 9.58e-10
V6Periodic connection variation, λ=1/3, m=κ1/2\lambda=1/3,\ m=\kappa_1/28.42e-10
V6Periodic connection variation, λ=2/3, m=κ1\lambda=2/3,\ m=\kappa_19.41e-10
V6Fixed-AA dressing variation and Noether pairing3.04e-10
Wall time180.02 s
Peak tracemalloc allocation1313.0 MiB

Directional derivatives​

In the sparse blade test, the finite difference and full Euler expression both give 554.666667554.666667 to the displayed precision. Omitting ΔE\Delta E gives 896.000000896.000000, a 61.5%61.5\% discrepancy relative to the finite difference.

The periodic tests use FB=0F_B=0, a two-variable field on the split-signature 14-torus, and volume-normalized quadrature. The script compares both coefficient choices with the same curvature-plus-κ1T\kappa_1 T expression suggested by equation (9.7). Its discrepancy is 25.7%25.7\% for (λ,m)=(1/3,κ1/2)(\lambda,m)=(1/3,\kappa_1/2) and 62.7%62.7\% for (2/3,κ1)(2/3,\kappa_1). The latter comparison also changes the cubic and mass normalizations. In the fixed-AA dressing test, omitting ΔE\Delta E changes the divergence pairing by 377.9%377.9\% of the finite difference.

Additional checks​

The grade-resolved counts in Theorem 3.4 were verified using the suite's integer D7D_7 routines. For each group of input grades KK in the table, and each exterior power r=1,2,3r=1,2,3, the Weyl dimensions of the output representations, weighted by multiplicity, summed to (14r)∑k∈K(14k)\binom{14}{r}\sum_{k\in K}\binom{14}{k}.

Using the suite's Clifford matrices, the hatted commutator on the closed 0101-jet with M=γ0M=\gamma^0 was zero, and the jet with M=γ1M=\gamma^1 gave 2Γ∗2\Gamma_*. The hatted three-blade commutator on F12=γ0F_{12}=\gamma^0 gave −2iγ12Γ∗-2i\gamma^{12}\Gamma_*. In the typed form calculation, (−,+,+;1/2)(-,+,+;1/2) agreed with −∗ΘEin-*\Theta_{\mathrm{Ein}} on constant Riemann curvature with zero matrix residual. On the closed 0101-jet with M=γ0M=\gamma^0 its one-form divergence was −2γ01-2\gamma^{01}.

Publication DOI: 10.5281/zenodo.24325062.