algorithm-fast-fourier-transform-tests
The groupant beside algorithms/src/fast_fourier_transform/tests.rs in the Mova repository: what the code computes, what it never does, how to go back from its outputs, its invariants, cost and checks.
Facts
Implementation material. A Mova code model describes this code at one source revision: partial models, finite checks and their stated scope. It is not a reviewed general exposition, and its labels are shown as written, never raised.
Components
| component | label | where |
|---|---|---|
| approximant | partial | Forward |
| ast | partial | syntax.json |
| cost | conditional | Cost |
| descriptant | present | descriptant |
| invariant | partial | Invariant |
| tests | bounded executed | evidence |
Obernants
The typed relations around the forward model: the behaviour complement (what the code never does), the reverse reconstruction (every input compatible with an output) and specialised views.
| id | type | label | where |
|---|---|---|---|
behavior_complement | behavior_complement | partial relational specification | behavior_complement |
reverse_reconstruction | reverse_reconstruction | partial relational specification | reverse_reconstruction |
oracle_independence | oracle_independence | partial relational specification | oracle_independence |
boundary_partition | boundary_partition | partial relational specification | boundary_partition |
mutation_observation | mutation_observation | partial relational specification | mutation_observation |
Model text
descriptant
fast_fourier_transform
Prospective model saved before implementation in ../prospective.md (relative from source directory). Original standard-library code. This epoch adds explicit supported domains and independent finite checks. See model.md for typed excluded-output and preimage relations. Partial syntax omits macro expansion and semantic resolution. No executable approximation profile is attached; useful cheaper metrics and evidence remain unsupported. No timing gain is claimed.
model
fast_fourier_transform tests.rs
Forward
Deterministic finite fixtures compare the public API with independent observations and validation outcomes.
Invariant
Each exercised case either matches the declared oracle or fails an assertion. No random, clock, I/O or callbacks inside tests.
Cost
Bounded finite fixture cost plus production calls. No timing claims; no benchmark in test harness.
behavior_complement
A successful run excludes any exercised mismatch between production and independent oracle, accepted invalid fixture, or failure of a named residual/dimension assertion. It does not exclude defects outside the finite fixture set.
reverse_reconstruction
An observed passing transcript admits all production programs agreeing on exercised observations, including programs wrong on unseen inputs. The original and any implementation with identical fixture outputs are indistinguishable by this harness.
oracle_independence
Direct quadratic complex DFT independently evaluates sin/cos for each j*k, with absolute tolerance1e-10; inverse roundtrip tolerance1e-12. Floating oracle is also rounded, not certified exact.
boundary_partition
Named boundaries test validation errors, degenerate cases and normalization where applicable. Allocator failure is not injected; production resource status and algebraic absence are separate assertions.
mutation_observation
One compiled production mutant must fail direct_oracle; exact source bytes restored before positive rerun. This only proves sensitivity to that chosen changed behavior, not mutation completeness.
evidence
Evidence โ 2026-10-30
Two tests per algorithm cover independent finite oracles and boundaries. Receipts: $MOVA_DATA/runs/octopus-wave25-algebra-2026-10-30. Paired debug/release logs, compiled-mutant rejection and restored rerun logs are retained there. Exact positive counts and final verification are reported in the integration receipt. Syntax projections are generated twice and compared. Source bindings are SHA-256; typed models are conditional specifications, not proofs. Allocator failure is not injected.
This page in Markdown โ https://md.groupants.elamur.ai/free/en/mova/algorithms/src/fast_fourier_transform/tests.rs.groupant/