Systems & physics papers
Alongside the quantitative-finance working papers further down this page, the same lab publishes the open-source
systems and mathematical-physics libraries used to build them: Polarway,
pysic-rs and
optimiz-rs, each with its own arXiv-style paper living in its own repository.
Four of these papers are deposited on Zenodo with a citable DOI and their full reproduction artifacts
(notebooks, data, build scripts); where a DOI is shown below it is the version of record, and the PDF
served from this page is that same build.
Systems
CPU-only
Rust / Python
PINN verification
Membership audit
ThotBook-AI: CPU-Only Language-Model Training with Physics-Informed Verification, Membership Auditing and Versioned Corpus Provenance
M. Alvarez · HFThot Research Lab · 2026 · 44 pp. · v3 (measured two-node distributed campaign)
ThotBook-AI is a Rust system that trains, serves, verifies and audits a personal language model entirely on CPU — no GPU and no external API. Every pipeline stage reads and writes a versioned Delta Lake table, so the corpus that produced a model is recoverable at a numbered version with a commit timestamp; a self-contained reverse-mode autodiff engine solves the differential equations appearing in ingested documents rather than only quoting them. Version 3 adds a measured two-node distributed campaign (local host + VPS workers): the full-batch 96,000-point gradient runs in 18.7 s single-process and 2.6 s at 4+4 workers, with exactness certificates carried across hosts (deviation ~3×10−12 from cross-BLAS summation order, loss agreement to 6.5×10−19) and every number reproduced from the released JSON artifact. The paper also audits privacy (a document-level membership-inference study with Platt-calibrated attack AUCs), federated defences (FedAvg with top-$K$, DP and secure aggregation), and reports an honest measured positioning against published baselines.
📋 BibTeX
@techreport{alvarez2026thotbook,
author = {Alvarez, M.},
title = {ThotBook-AI: CPU-Only Language-Model Training with Physics-Informed Verification, Membership Auditing and Versioned Corpus Provenance},
institution = {HFThot Research Lab},
year = {2026},
url = {https://hfthot-lab.eu/papers/thotbook-ai-arxiv.pdf}
}
Systems
Data engineering
Railway-oriented programming
Category theory
Polarway: Railway-Oriented Data Engineering for Bounded-Memory, Multi-Language Analytics
M. Alvarez · HFThot Research Lab · 2026 · 32 pp. · v2.0.0 (category-theoretic proofs, two-sided Spark/DuckDB benchmarks)
Polarway applies Railway-Oriented Programming to analytical pipelines — every transformation returns an explicit success/failure value, so error handling composes instead of being bolted on through exceptions. Built as an extension of the Polars columnar engine, it adds a Delta-Lake-backed lakehouse with ACID transactions and time travel, a domain-agnostic event bus, network-native streaming sources (WebSocket, REST, gRPC), and a Spark DataFrame compatibility layer. On a single node with 5M rows, the engine is 3.4–8.7× faster than PySpark on scan/aggregation/join/windowing — while reporting honestly where it loses: PySpark is 1.8× faster on sort-with-top-k, and DuckDB beats it on four of five queries. The extended whitepaper adds full proofs that Polarway's pipeline composition forms a genuine Kleisli category and that its streaming aggregations are correct exactly when their combiner is a monoid homomorphism — the identity behind constant-memory processing of datasets larger than RAM — together with a structural comparison against Spark, Kafka, Cloudera and Databricks. Version 2 turns that algebra into the laboratory's documented distributed-execution pattern: domain decomposition with (mean, n)-monoid aggregation is the exactness certificate reused verbatim by the pysic-rs campaign and the ThotBook-AI PINN case study.
📋 BibTeX
@misc{alvarez2026polarway,
author = {Alvarez, M.},
title = {Polarway: Railway-Oriented Data Engineering for
Bounded-Memory, Multi-Language Analytics},
howpublished = {Zenodo},
version = {2.0.0},
year = {2026},
doi = {10.5281/zenodo.23925077},
url = {https://doi.org/10.5281/zenodo.23925077}
}
Systems
Mathematical physics
Rust / Python
Validation discipline
pysic-rs: A Validated Mathematical-Physics Engine in Rust
M. Alvarez · HFThot Research Lab · 2026 · 21 pp. · v0.2.0 (eight defects + the measured distributed-workload campaign)
pysic-rs is a CPU-only mathematical-physics library in Rust exposed to Python via PyO3, covering special functions, linear algebra, ODE/PDE solvers, quantum mechanics, general relativity, gauge theory, topology and electromagnetism — built around one methodological commitment: every routine is graded against a closed-form or tabulated reference value rather than demonstrated on a plausible-looking plot. Applying that discipline to a pedagogical walk-through connecting Schrödinger, Dirac, Maxwell/Aharonov–Bohm, the ADM constraints and Wheeler–DeWitt exposed eight incorrect routines already in the library's own code — including a Dirac propagator whose norm grew to 3.6×1057. Version 2 adds three computed physics walk-throughs (Schrödinger-to-Dirac, Aharonov–Bohm, the ADM constraints) with re-executed closed-form checks — and, delivered on the promise of the sketch, a measured distributed-workload campaign: a 96-column Dyson–Schwinger sweep across worker processes aggregated exactly (bit-identical to the sequential run), a self-consistent gap equation solved to round-off in half a second with its Banach bound certified before any iteration, and a distributed physics-informed-network case study — speedups and their degradation reported as measured, on plain CPU processes.
📋 BibTeX
@misc{alvarez2026pysicrs,
author = {Alvarez, M.},
title = {pysic-rs: A Validated Mathematical-Physics Engine in Rust,
and What Grading It Against Closed Forms Revealed},
howpublished = {Zenodo},
version = {0.2.0},
year = {2026},
doi = {10.5281/zenodo.23934314},
url = {https://doi.org/10.5281/zenodo.23934314}
}
Course
Analysis & numerics
34 solved exercises
Mathematical Prerequisites for Computational Physics
HFThot Research Lab · 2026 · 30 pp. · 34 solved exercises · €10.99
Complex analysis and special functions, floating-point cancellation, spectral linear algebra, ODE stability and stiffness, Fourier and Strang splitting, asymptotics and turning points, Clifford algebra, and constrained systems — every chapter ends on the invariant that would have caught the corresponding pysic-rs defect. In French, with all 34 exercises fully solved. The thread running through it is one question: how would I know this result is wrong?
📋 BibTeX
@book{hfthot2026mathprereqs,
author = {{HFThot Research Lab}},
title = {Mathematical Prerequisites for Computational Physics (course, in French)},
publisher = {HFThot Research Lab},
year = {2026},
url = {https://hfthot-lab.eu/papers/prereqs-pysic-rs-sample.pdf}
}
Systems
Numerical primitives
Rust / Python
optimiz-rs: A Rust-Backed Library of Composable Numerical Primitives for Quantitative Finance
M. Alvarez · HFThot Research Lab · 2026 · 28 pp. · v2 (validation matrix + honest benchmarks)
optimiz-rs is a Rust library of numerical primitives — hidden Markov models, backward stochastic differential equations, McKean–Vlasov diffusions, path signatures, persistent homology, Hawkes processes and robust estimators — exposed to Python through a stable PyO3 facade and distributed on both PyPI and crates.io. The paper gives complete mathematical derivations of the core primitives, validates the implementation by reproducing Sznitman's propagation-of-chaos convergence rate on a mean-reverting McKean–Vlasov flow, and reports honest single-thread benchmarks showing 1.7–67.7× wall-clock speedups over pure-Python/NumPy/SciPy baselines on intrinsically sequential workloads. A new section brings the same infrastructure to mean-field dynamics: physics-informed network optimization of McKean–Vlasov SDEs in the style of Zhang, Guo & Karniadakis (arXiv:1905.01205), where gradient slabs shared across worker processes recombine through the streaming (mean, n) monoid --- so distributed gradients are ensemble-exact, a property the sibling pysic-rs paper measures on its DSE campaign.
📋 BibTeX
@misc{alvarez2026optimizrs,
author = {Alvarez, M.},
title = {optimiz-rs: A Rust-Backed Library of Composable Numerical
Primitives for Quantitative Finance},
howpublished = {Zenodo},
version = {2},
year = {2026},
doi = {10.5281/zenodo.23935101},
url = {https://doi.org/10.5281/zenodo.23935101}
}
Physics
PINN
Automatic differentiation
CPU-only
Reproduction artifact
Physics-Informed Neural Networks on One CPU: Exact Gradients from an External Objective Library
M. Alvarez · HFThot Research Lab · 2026 · 32 pp. · Wheeler–DeWitt, Hermitian Yang–Mills, Dirac, Dyson Brownian motion, McKean–Vlasov
Five equations from quantum cosmology, gauge theory, relativistic quantum mechanics and random matrix
theory, each solved by a physics-informed neural network trained entirely on a single CPU and without a
deep-learning framework. The objectives are supplied by optimiz-rs; the automatic
differentiation is a 261-line reverse-mode tape over NumPy; the optimisers are a 130-line AdamW/L-BFGS
pair. The methodological contribution is a composition rule that lets an objective defined
outside the differentiation tape contribute an exact gradient through a single
vector–Jacobian product — so one audited implementation of a loss serves an entire stack, at
no cost in accuracy: the assembled gradient agrees with central finite differences to
4×10−8 relative error. Every network is graded against an independent
reference rather than against itself — Numerov integration, spectral inversion of the periodic
Laplacian, the exactly diagonalised propagator, and the simulated particle system with the analytic
semicircle transform — for relative errors of 2.4×10−4 to
9.8×10−2 and 213 s of total training on one i9-8950HK. Two diagnostics were
deliberately kept out of the objectives so that they constitute evidence rather than assumption:
unitarity of the Dirac evolution, never imposed and holding to 10−3, and Wigner's
semicircle law, recovered from nothing but a complex Burgers equation and an initial condition. The
closed-form cost model Θ((1+2d)NLW²) is used to say where the no-accelerator choice stops
being the right one — when the working set leaves last-level cache, not when the parameter count
grows. Two solver defects the protocol caught in the authors' own library are reported with
reproducible evidence.
📋 BibTeX
@misc{alvarez2026pinncpu,
author = {Alvarez, M.},
title = {Physics-Informed Neural Networks on One CPU: Exact Gradients
from an External Objective Library},
howpublished = {Zenodo},
version = {1},
year = {2026},
doi = {10.5281/zenodo.23764841},
url = {https://doi.org/10.5281/zenodo.23764841}
}
Physics
Gauge theory
Prerequisites
Prerequisites for Yang–Mills Theory and the Mass Gap Problem
M. Alvarez · HFThot Research Lab · 2026 · 52 pp. (machine-checked algebraic identities)
A self-contained mathematical primer for the companion article “Yang–Mills: Why a Million-Dollar Problem Has Resisted for 70 Years.” Builds, from first principles, the machinery that article assumes: Lie groups and algebras, principal bundles, connections and curvature (the geometric meaning of $A_\mu$ and $F_{\mu\nu}$), the variational derivation of the Yang–Mills field equations, the Wightman axioms needed to state the Clay Millennium mass-gap problem rigorously, the one-loop derivation of asymptotic freedom, the topological classification of instantons via the Bogomolny bound, and the spontaneous-symmetry-breaking computation behind the Higgs mechanism — closing with a section-by-section roadmap back to the article. Full derivations, worked examples, and exercises with solutions throughout.
📋 BibTeX
@techreport{alvarez2026yangmillsprereqs,
author = {Alvarez, M.},
title = {Prerequisites for Yang--Mills Theory and the Mass Gap Problem},
institution = {HFThot Research Lab},
year = {2026},
url = {https://hfthot-lab.eu/papers/yang-mills-prerequisites.pdf}
}
Public working papers
Each working paper is released as an open PDF, accompanied by a companion course on
hfthot-lab.eu/courses
and a blog summary. We welcome peer feedback by email.
WP1
Mean-field games
McKean–Vlasov
Optimal allocation
Optimal Trading via Mean-Field Games & MCMC
M. Alvarez · HFThot Research Lab · 2026 · 46 pp. · v1.1 (falsification protocol)
We formulate optimal portfolio allocation in the presence of self-induced market impact as a mean-field game (MFG) of McKean–Vlasov type. The Hamilton–Jacobi–Bellman / Fokker–Planck system is solved by a particle method coupled to an MCMC sampler over the population distribution. We prove convergence of the discretised system under a monotonicity condition on the running cost and provide explicit sample-complexity bounds. A numerical study on a synthetic universe shows that the MFG-aware allocator outperforms classical mean-variance both in Sharpe and in turnover-stability across regime switches.
📋 BibTeX
@techreport{alvarez2026wp1,
author = {Alvarez, M.},
title = {Optimal Trading via Mean-Field Games and {MCMC}},
institution = {HFThot Research Lab},
number = {WP1},
year = {2026},
url = {https://hfthot-lab.eu/papers/wp1-mean-field-games.pdf}
}
WP2
Rough volatility
Path signatures
Heston
Rough Heston & Signature Methods for Volatility Arbitrage
M. Alvarez · HFThot Research Lab · 2026 · 60 pp. · v1.1 (falsification protocol)
The rough Heston model captures key empirical features of the implied-volatility surface — short-term skew, term-structure of vol-of-vol, and roughness exponent $H \approx 0.1$ — that classical Heston cannot reproduce. We derive an efficient calibration scheme that combines fractional ODE numerics with a path-signature representation of forward variance curves. The signature embedding turns the calibration into a smooth optimisation in feature space, yielding a 10–30× speed-up over Fourier-based calibrations on liquid surfaces. We show empirically that the rough-Heston / signature pipeline closes the calibration gap on SPX, EUR/USD, and BTC option surfaces, and we use it to build a model-free volatility-arbitrage indicator with documented backtest performance on synthetic paths.
📋 BibTeX
@techreport{alvarez2026wp2,
author = {Alvarez, M.},
title = {Rough {H}eston and Signature Methods for Volatility Arbitrage},
institution = {HFThot Research Lab},
number = {WP2},
year = {2026},
url = {https://hfthot-lab.eu/papers/wp2-rough-heston-signatures.pdf}
}
WP3
Stochastic control
HJB
Adaptive Portfolio Construction & Execution
M. Alvarez · HFThot Research Lab · 2026 · 54 pp. · v1.1 (falsification protocol)
A stochastic-control framework that fuses regime detection, optimal allocation, and execution-aware optimisation into a single Hamilton–Jacobi–Bellman recursion. The optimal trading rate is computed self-consistently with execution friction, eliminating the artificial split between portfolio construction and execution scheduling. Convergence of a policy-iteration scheme is proven; a deep-Galerkin variant is provided for high-dimensional regimes.
📋 BibTeX
@techreport{alvarez2026wp3,
author = {Alvarez, M.},
title = {Adaptive Portfolio Construction and Execution},
institution = {HFThot Research Lab},
number = {WP3},
year = {2026},
url = {https://hfthot-lab.eu/papers/wp3-adaptive-portfolio.pdf}
}
WP4
Volatility surfaces
SVI / SSVI
Dispersion
Options Portfolio Labs — Volatility Arbitrage at Scale
M. Alvarez · HFThot Research Lab · 2026 · 66 pp. · v3.1 (arbitrage certificates)
A unified pricing-and-hedging framework for systematic options desks: arbitrage-free SSVI surface calibration, regime-conditioned dispersion signals, and a Greeks-tensor risk budget. We provide a constrained-QP hedger that respects both transaction costs and Greek caps, and demonstrate the framework on an SPX-vs-constituent dispersion lab.
📋 BibTeX
@techreport{alvarez2026wp4,
author = {Alvarez, M.},
title = {Options Portfolio Labs: Volatility Arbitrage at Industrial Scale},
institution = {HFThot Research Lab},
number = {WP4},
year = {2026},
url = {https://hfthot-lab.eu/papers/wp4-options-portfolio-labs.pdf}
}
WP5
Geometric arbitrage
Chern–Simons
Walk-forward validation
Topological Arbitrage: A Discrete Chern–Simons Framework for Lead–Lag Markets
M. Alvarez · HFThot Research Lab · 2026 · 23 pp. · revised v3 · under journal review
Building on Farinelli's geometric arbitrage theory, WP5 discretises the smooth market bundle
into an asset graph $G=(V,E)$ carrying a $U(1)$-valued lead–lag connection
$A_{ij}^{(\tau)}$; plaquette curvature $F_{\triangle}$ is identified with discrete
arbitrage opportunities, and the Chern–Simons functional
$\Phi_{CS}=\sum_{\triangle}\lVert F_{\triangle}\rVert^{2}$ is a gauge-invariant scalar that
detects where the zero-curvature (NFLVR) condition fails. The signal extends to higher-order
interactions via 4-simplices (Reshetikhin–Turaev quantisation) and couples to Kalman/HMM
regime filtering. Validated on five major crypto assets (BTC, ETH, SOL, AVAX, BNB, 2022–2024)
with a purged $k$-fold walk-forward protocol: the Chern–Simons signal Granger-causes realised
volatility at horizon $h{=}3$ (Diebold–Mariano $p<0.01$ vs.\ the VIX/RV baseline) and
delivers a deflated Sharpe ratio of $1.84$ versus $1.12$ for the linear PCA stat-arb
benchmark. Proofs, the Rust kernel, and the identifiability analysis are in the appendices.
📋 BibTeX
@techreport{alvarez2026wp5,
author = {Alvarez, M.},
title = {Topological Arbitrage: A Discrete {C}hern--{S}imons Framework for Lead--Lag Markets},
institution = {HFThot Research Lab},
number = {WP5},
note = {Revised v3; under journal review},
year = {2026},
url = {https://hfthot-lab.eu/research.html}
}
Publication plan & per-paper readiness
Transparent roadmap from working paper to journal submission. Each paper now ships a
falsification protocol — every headline claim is bound to a refutation statistic,
a pre-registered acceptance threshold, and the artefact that re-runs the test; a failed check on
refreshed data is published, not silently re-fit. Updated October 2026.
Ordering. WP5 goes out first (fastest path to referee feedback), followed by WP2, WP4, WP1 and WP3,
incorporating lessons between submissions. Systems papers (polarway / pysic-rs / optimiz-rs) go to
venue-appropriate software journals in parallel. No acceptance has yet been claimed anywhere on this page;
statuses reflect preparation, peer-feedback rounds and open falsification commitments.