Eve library

Phase 124 — Kalika Spectroscopy Simulation: Completion Evidence

Tracker

Revision 1

On this page

Historical task source. The Eve task board holds current task state.

Status: 228 / 228 tasks complete.

2026-07-13 closure audit#

The final locally actionable audit found and closed two verification gaps that were hidden by the completed checklist:

  • all eleven TypeScript projects now pass their own lint targets with no errors or warnings; the cleanup also makes the XPS ordering validation exercise the computed calibrated values and validates the minimum alignment search grid;
  • every phase library now completes its declaration-producing Nx build by resolving build-time dependencies through the declarations emitted by its upstream build, rather than pulling unrelated dependency source files into a composite TypeScript program (TS6307).

Fresh, cache-bypassed targeted gates passed for all eleven libraries: Nx test, lint, and build (parallelism 1). All five Rust workspaces passed cargo test --no-default-features (18 kernel tests total), Clippy with warnings denied, and native-feature checks. Their Nx build:native and build:wasm matrices also passed for spectroscopy, XAS, vibrational spectroscopy, NMR, and EELS. A checklist recount confirms 228 checked items and zero unchecked items.

Eleven @kalika/* libraries plus five Rust napi-rs/wasm kernels, all with real domain-specific algorithms, domain-correctness tests (checked against known analytic/experimental values), and clean adversarial stub scans. TypeScript for orchestration/physics, Rust for the compute-intensive kernels.

TypeScript libraries and test counts#

Library Sections Tests
@kalika/spectroscopy (+ integration adapters, PW/LCAO wavefunctions) 124.1, 124.11.1-3 24 + 10
@kalika/xas 124.2 (incl. SCF, curved-wave MS, core-hole DFT, BSE, M-edge multiplet) 52 + 4
@kalika/photoemission 124.3 (incl. one-step model) 18
@kalika/vibrational-spectroscopy 124.4 (incl. DFPT 2n+1) 28
@kalika/nmr 124.5 (incl. GIPAW/PAW-EFG/J-coupling) 29
@kalika/mossbauer 124.6 17
@kalika/eels 124.7 (incl. L/M GOS) 20
@kalika/spectroscopy-extended 124.8 24
@kalika/spectrum-processing 124.9 (incl. Athena .prj) 32
@kalika/spectroscopy-viz 124.10 18
@kalika/spectroscopy-validation 124.11.4 11

Rust kernels (cargo build/test/clippy clean; napi + wasm-pack wired into Nx)#

Crate Kernel Rust tests
spectroscopy-kernel batched Voigt/Faddeeva (McLean 1994) 4
xas-kernel Numerov radial solver, phase shifts, t-matrix 5
vib-kernel Raman-tensor finite differences + invariants 3
nmr-kernel MAS spinning-sideband powder integration 3
eels-kernel loss function + Kramers-Kronig 3

Each crate is crate-type = ["cdylib","rlib"] with napi behind the native feature and wasm behind the wasm feature; cargo test --no-default-features and cargo clippy -- -D warnings pass, and cargo check --features native compiles the N-API bindings.

Notable validations against known values#

Cu K-edge EXAFS first shell (R=2.556 A), EXAFS fit recovering R & sigma^2; hydrogen 1s = -0.5 Ha / 2s = -0.125 Ha (1 node) / He+ = -2 Ha from the Numerov bound-state solver; self-consistent atomic potential (Ne 1s ~ -32 Ha matching ~870 eV binding, correct core/valence ordering); Haydock BSE reproducing the eigenvalue spectrum + integral-A = |phi0|^2 sum rule; d^2 Racah term energies (3F ground) and Hund's rules (d2->3F, d5->6S, f7->8S); 57Fe sextet span 10.6 mm/s at 33 T; cubic-symmetry EFG vanishing; Al/Si plasmons (15/16.7 eV); 1H Larmor 500 MHz at 11.74 T; Wigner-3j(1,1,0) = -1/sqrt3; Slater Z_eff(C 2p) = 3.25; Voigt area normalization. The validation library's ten cross-technique suites (XAS/XPS/NMR/Mossbauer/Raman/EELS/EPR/pipeline) all pass.

Approach notes#

The DFT/GW/DFPT-derived methods (core-hole DFT XANES, core-level BSE, GIPAW shielding, PAW-EFG, J-coupling, DFPT 2n+1 Raman, the DFT/GW/BSE/phonon/defect integration adapters) are implemented as algorithms that consume the relevant electronic-structure / lattice-dynamics inputs and compute the observable, in the same input-taking style as the rest of the phase, and are tested on model inputs plus the cross-technique validation suites. No result-faking stubs were shipped; every [ ] -> [x] is backed by implemented, tested code.