DSFB compares prediction and measurement.
- If they disagree a lot, it reduces trust.
- If they agree, it increases trust.
Instead of treating a sensor as valid or invalid, DSFB treats it as trusted proportionally.
Essentially: Proportional Trust Observer.
If a sensor says something that matches what you expect, you listen a lot.
If it says something very different, you listen a little.
Don’t believe a sensor all at once.
Informal overview. See paper for formal definition.
de Beer, R. (2026). Deterministic Drift--Slew Fusion Bootstrap for Navigation During Plasma Blackout in Hypersonic Re-Entry Vehicles (v1.0). Zenodo. [https://doi.org/10.5281/zenodo.18711897]
de Beer, R. (2026). Drift--Slew Fusion Bootstrap: A Deterministic Residual-Based State Correction Framework (v1.0). Zenodo. [https://doi.org/10.5281/zenodo.18706455]
de Beer, R. (2026).
Trust-Adaptive Multi-Diagnostic Weighting for Magnetically Confined Plasma State Estimation (v1.0).
Zenodo. [https://doi.org/10.5281/zenodo.18644561]
de Beer, R. (2026).
Slew-Aware Trust-Adaptive Nonlinear State Estimation for Oscillatory Systems With Drift and Corruption (v1.0).
Zenodo. [https://doi.org/10.5281/zenodo.18642887]
de Beer, R. (2026). Hierarchical Residual-Envelope Trust: A Deterministic Framework for Grouped Multi-Sensor Fusion (v1.0). Zenodo. [https://doi.org/10.5281/zenodo.18783283]
de Beer, R. (2026). Deterministic Disturbance Modeling Framework for Residual-Envelope Fusion Systems (v1.0). Zenodo. [https://doi.org/10.5281/zenodo.18806150]
de Beer, R. (2026). Algebraic Deterministic Dynamics (ADD): A Non-Stochastic Structural Extension of DSFB (v1.0). Zenodo. [https://doi.org/10.5281/zenodo.18830567]
de Beer, R. (2026). Deterministic Structural Causal Dynamics (DSCD): Trust-Gated Emergence of Certifiable Causal Graphs for Safety-Critical Aerospace Autonomy (v1.0). Zenodo. [https://doi.org/10.5281/zenodo.18867217]
de Beer, R. (2026). Deterministic Causal Dynamics for Safety-Critical Autonomous Systems - Trust-Controlled Causal Topology (TCCT) and Structural Regime Dynamics (SRD) (v1.0). Zenodo. [https://doi.org/10.5281/zenodo.18976566]
de Beer, R. (2026). Trust-Monotone Temporal Recursion in Deterministic Structural Dynamics (v1.0). Zenodo. [https://doi.org/10.5281/zenodo.18998208]
de Beer, R. (2026). Alternative Deterministic Structural Inference: The DSFB Stack for Reconstruction, Causal Architecture, Trust Recursion, and Historical Replay (v1.0). Zenodo. [https://doi.org/10.5281/zenodo.19028440]
de Beer, R. (2026). Deterministic Spectral Residual Inference for Swarm Interaction Networks: A DSFB Framework for Structural Phase Stability (v1.0). Zenodo. [https://doi.org/10.5281/zenodo.19073826]
Fusion Bench Figures Notebook:
High-Rate Estimation Trust Figures Notebook:
HRET Correlated Group Figures Notebook:
Starship High-Fidelity 6-DoF Re-Entry Notebook:
Hierarchical Residual-Envelope Trust (HRET)
Deterministic Disturbance Modeling Framework (DDMF)
Structural Regime Dynamics (SRD)
The dsfb-add crate runs deterministic parameter sweeps for the Algebraic Deterministic Dynamics (ADD) stack:
- Algebraic Echo Theory (AET)
- Topological Charge Propagation (TCP)
- Resonance Lattice Theory (RLT)
- Invariant Word-Length Thermodynamics (IWLT)
It generates CSV outputs and figures used in the ADD paper.
The dsfb-dscd crate runs deterministic trust-gated causal graph sweeps and finite-size scaling analyses on top of the DSFB and ADD stacks.
Quick mode (Colab-friendly):
cargo run -p dsfb-dscd -- --quickFull mode (workstation):
cargo run -p dsfb-dscd -- --fullExplicit scale override:
cargo run -p dsfb-dscd -- --num-events 100000 --scaling-ns 4096,8192,16384,32768,65536,100000 --num-tau-samples 1001This writes timestamped CSV outputs under output-dsfb-dscd/<timestamp>/ (including threshold_scaling_summary.csv, threshold_curve_N_<N>.csv, graph_events.csv, graph_edges.csv, degree_distribution.csv, interval_sizes.csv, path_lengths.csv, and edge_provenance.csv).
All DSCD paper figures are reproducible from those generated CSVs and the notebook:
crates/dsfb-dscd/notebooks/dscd_plots.ipynb
This repository contains seven crates for different DSFB workflows:
dsfb: crate for the DSFB estimator itself workspace path:crates/dsfbcrates.io: https://crates.io/crates/dsfb docs.rs: https://docs.rs/dsfbdsfb-ddmf: deterministic disturbance modeling + residual-envelope Monte Carlo sweep crate built on top ofdsfbworkspace path:crates/dsfb-ddmflocal README:crates/dsfb-ddmf/README.mdcrates.io: https://crates.io/crates/dsfb-ddmf docs.rs: https://docs.rs/dsfb-ddmfdsfb-fusion-bench: standalone synthetic benchmarking + plotting-data generator crate workspace path:crates/dsfb-fusion-benchlocal README:crates/dsfb-fusion-bench/README.mddsfb-hret: hierarchical residual-envelope trust crate for grouped multi-sensor fusion under shared disturbances workspace path:crates/dsfb-hretlocal README:crates/dsfb-hret/README.mdcrates.io: https://crates.io/crates/dsfb-hret docs.rs: https://docs.rs/dsfb-hretdsfb-lcss-hret: standalone high-rate estimation trust analysis benchmarking crate workspace path:crates/dsfb-lcss-hretlocal README:crates/dsfb-lcss-hret/README.mdisolated crate (not part of workspace) - compiles independentlydsfb-srd: deterministic Structural Regime Dynamics phase-transition demonstrator for trust-gated causal graphs workspace path:crates/dsfb-srdlocal README:crates/dsfb-srd/README.mdisolated crate (not part of workspace) - compiles independentlydsfb-starship: Starship high-fidelity 6-DoF re-entry simulation + DSFB trust-adaptive fusion demo workspace path:crates/dsfb-starshiplocal README:crates/dsfb-starship/README.mdpublish-ready (not yet published)
Observer-theoretic framework for slew-aware trust-adaptive oscillatory state estimation under bounded disturbances.
DSFB is a state estimation algorithm that tracks position (φ), velocity/drift (ω), and acceleration/slew (α) across multiple measurement channels with adaptive trust weighting. The algorithm dynamically adjusts trust weights for each channel based on exponential moving averages (EMA) of residuals, making it robust to impulse disturbances and measurement anomalies.
- Trust-adaptive fusion: Automatically down-weights unreliable measurement channels
- Drift-slew dynamics: Tracks position, velocity (drift), and acceleration (slew)
- O(M) complexity: Efficient per-step computation for M channels
- Deterministic: Reproducible results with seed control
- Pure Rust: No external C dependencies
The DSFB algorithm operates in discrete time with the following steps:
φ⁻ = φ + ω·dt
ω⁻ = ω + α·dt
α⁻ = α
rₖ = yₖ - h(φ⁻) # Residuals
sₖ = ρ·sₖ + (1-ρ)·|rₖ| # EMA residuals
w̃ₖ = 1 / (σ₀ + sₖ) # Raw trust weights
wₖ = w̃ₖ / Σⱼw̃ⱼ # Normalized weights
R = Σₖ wₖ·rₖ # Aggregate residual
φ = φ⁻ + k_φ·R
ω = ω⁻ + k_ω·R
α = α⁻ + k_α·R
From crates.io:
[dependencies]
dsfb = "0.1.1"To track unreleased changes, use Git:
[dependencies]
dsfb = { git = "https://github.com/infinityabundance/dsfb", branch = "main" }Or install from source:
git clone https://github.com/infinityabundance/dsfb
cd dsfb
cargo build --release -p dsfbuse dsfb::{DsfbObserver, DsfbParams, DsfbState};
// Configure parameters
let params = DsfbParams::new(
0.5, // k_phi: position gain
0.1, // k_omega: velocity gain
0.01, // k_alpha: acceleration gain
0.95, // rho: EMA smoothing (0 < ρ < 1)
0.1, // sigma0: trust softness
);
// Create observer with 2 channels
let mut observer = DsfbObserver::new(params, 2);
// Initialize state
observer.init(DsfbState::new(0.0, 0.5, 0.0));
// Process measurements
let dt = 0.01;
let measurements = vec![1.0, 1.05];
let state = observer.step(&measurements, dt);
println!("φ={}, ω={}, α={}", state.phi, state.omega, state.alpha);
// Check trust weights
let w0 = observer.trust_weight(0);
let w1 = observer.trust_weight(1);
println!("Trust weights: {}, {}", w0, w1);The repository includes a complete simulation harness that demonstrates DSFB performance against baseline methods:
# Run simulation and generate CSV output
cargo run --release -p dsfb --example drift_impulse
# Output will be written to: output-dsfb/<timestamp>/sim-dsfb.csvThe simulation compares three methods:
- Mean Fusion: Simple average of measurements
- Freq-Only Observer: Observer without acceleration state
- DSFB Observer: Full drift-slew fusion with trust adaptation
Simulation scenario:
- Two measurement channels
- Channel 2 has linear drift and impulse disturbance
- Impulse occurs at t=3.0s for 1.0s duration
- Metrics: RMS error, peak error during impulse, recovery time
For the separate fusion diagnostics benchmarking artifact, use dsfb-fusion-bench:
cargo run --release -p dsfb-fusion-bench -- --run-default
cargo run --release -p dsfb-fusion-bench -- --run-sweepOutputs are written under:
output-dsfb-fusion-bench/<timestamp>/(from workspace root by default)- includes
summary.csv,heatmap.csv,trajectories.csv, andsim-dsfb-fusion-bench.csv
Companion notebook for figures:
crates/dsfb-fusion-bench/dsfb_fusion_figures.ipynb
For the high-rate estimation trust analysis, use the standalone dsfb-lcss-hret crate:
# Run default benchmark configuration
cargo run --release --manifest-path crates/dsfb-lcss-hret/Cargo.toml -- --run-default
# Run parameter sweep
cargo run --release --manifest-path crates/dsfb-lcss-hret/Cargo.toml -- --run-sweep
# Customize parameters
cargo run --release --manifest-path crates/dsfb-lcss-hret/Cargo.toml -- \
--run-default \
--num-runs 500 \
--time-steps 2000 \
--seed 123Outputs are written under:
output-dsfb-lcss-hret/<timestamp>/(timestamped directories)- includes
summary.csv,trajectories.csv, andheatmap.csv
Companion notebook for dsfb-lcss-hret figures:
crates/dsfb-lcss-hret/dsfb_lcss_hret_figures.ipynb
Note: This crate is intentionally isolated (not part of the workspace) and compiles independently.
For a single-command run that builds the example, writes the simulation CSV, computes metrics from CSV, and generates plots:
./scripts/run_drift_impulse_verify.shThis produces:
output-dsfb/<timestamp>/sim-dsfb.csvoutput-dsfb/<timestamp>/analysis/metrics.jsonoutput-dsfb/<timestamp>/analysis/metrics_summary.csvoutput-dsfb/<timestamp>/analysis/phi_estimates.pngoutput-dsfb/<timestamp>/analysis/estimation_errors.pngoutput-dsfb/<timestamp>/analysis/trust_weight_and_ema.png
Recovery time is computed as steps after the impulse window until error stays below a near-baseline threshold for hold_steps consecutive samples. The threshold is:
baseline_rms * baseline_factor + baseline_marginbaseline_rmsis RMS error before the impulse start
You can tune this definition:
./scripts/run_drift_impulse_verify.sh \
--hold-steps 10 \
--baseline-factor 1.10 \
--baseline-margin 0.005To verify against values reported in your paper, pass expected metrics and tolerance:
./scripts/run_drift_impulse_verify.sh \
--expect-rms-mean <value> \
--expect-rms-freqonly <value> \
--expect-rms-dsfb <value> \
--expect-peak-mean <value> \
--expect-peak-freqonly <value> \
--expect-peak-dsfb <value> \
--expect-recovery-mean <value> \
--expect-recovery-freqonly <value> \
--expect-recovery-dsfb <value> \
--tolerance 1e-3Use the Jupyter notebook to visualize simulation results:
# First, run the simulation to generate data
cargo run --release -p dsfb --example drift_impulse
# Then open the notebook
jupyter notebook crates/dsfb/dsfb_simulation.ipynbOr use Google Colab:
DSFB Simulation Notebook:
Fusion Bench Figures Notebook:
High-Rate Estimation Trust Figures Notebook:
Starship High-Fidelity 6-DoF Re-Entry Notebook:
In Google Colab, click Run all first. If a notebook asks for CSV files, click Browse in the file picker and upload the required CSVs from your local machine.
The notebook displays:
- Position estimates vs ground truth
- Error curves for all methods
- Trust weight adaptation over time
- EMA residual tracking
- Performance metrics table
State vector for the observer:
phi: f64- Position/phaseomega: f64- Velocity/frequency (drift)alpha: f64- Acceleration/slew
Algorithm parameters:
k_phi: f64- Position correction gaink_omega: f64- Velocity correction gaink_alpha: f64- Acceleration correction gainrho: f64- EMA smoothing factor (0 < ρ < 1, typical: 0.95)sigma0: f64- Trust softness parameter (typical: 0.1)
Main observer struct:
new(params: DsfbParams, channels: usize) -> Self- Create observerinit(&mut self, initial_state: DsfbState)- Set initial statestep(&mut self, measurements: &[f64], dt: f64) -> DsfbState- Process one time stepstate(&self) -> DsfbState- Get current statetrust_weight(&self, channel: usize) -> f64- Get trust weight for channelema_residual(&self, channel: usize) -> f64- Get EMA residual for channel
# Run unit tests
cargo test -p dsfb
# Run with verbose output
cargo test -p dsfb -- --nocapture
# Run specific test
cargo test -p dsfb test_observer_creationBefore publishing a new version to crates.io:
# Verify package contents
cargo package --list -p dsfb
# Verify publishability without uploading
cargo publish --dry-run -p dsfbThen tag and publish explicitly:
# Optional: tag release
git tag v0.1.0
git push origin v0.1.0
# Publish (intentional/manual step)
cargo publish -p dsfb- Time complexity: O(M) per step for M channels
- Space complexity: O(M) for channel statistics
- Deterministic: Given fixed seed, produces identical results
Licensed under the Apache License, Version 2.0 (LICENSE or http://www.apache.org/licenses/LICENSE-2.0)
Contributions are welcome! Please feel free to submit a Pull Request.
For theoretical background, see:
dsfb/
├── Cargo.toml # Workspace configuration (dsfb, dsfb-fusion-bench, dsfb-starship, dsfb-hret, dsfb-ddmf)
├── Cargo.lock
├── crates/
│ ├── dsfb/ # Core DSFB estimator crate
│ │ ├── Cargo.toml
│ │ ├── src/ # Observer, params, state, trust logic
│ │ └── examples/ # Drift/impulse example programs
│ ├── dsfb-ddmf/ # Deterministic disturbance modeling + Monte Carlo sweeps
│ │ ├── Cargo.toml
│ │ ├── README.md
│ │ ├── src/ # Envelope, disturbances, sim, Monte Carlo, CLI
│ │ ├── dsfb_ddmf_colab.ipynb # DDMF Colab notebook
│ │ └── dsfb_ddmf_colab.py # Notebook source script
│ ├── dsfb-fusion-bench/ # Fusion diagnostics benchmark crate
│ │ ├── Cargo.toml
│ │ ├── configs/ # Reproducible run configs
│ │ ├── src/ # Simulation + metrics + CLI
│ │ └── dsfb_fusion_figures.ipynb
│ ├── dsfb-hret/ # Hierarchical residual-envelope trust crate
│ │ ├── Cargo.toml
│ │ ├── README.md
│ │ ├── src/ # HRET API + tests
│ │ └── hret_hypersonic_validation.ipynb
│ ├── dsfb-lcss-hret/ # Standalone high-rate estimation trust benchmark
│ │ ├── Cargo.toml
│ │ ├── README.md
│ │ ├── src/ # CLI + experiment logic
│ │ ├── dsfb_lcss_hret_figures.ipynb
│ │ └── dsfb-lcss-hret-correlated.ipynb
│ └── dsfb-starship/ # Starship 6-DoF re-entry + DSFB demo
│ ├── Cargo.toml
│ ├── README.md
│ ├── src/ # Dynamics, estimators, CLI
│ └── starship_reentry_demo.ipynb
├── .github/
│ └── workflows/
│ └── ci.yml # Workspace CI
├── docs/ # Reference papers and extra notes
├── scripts/ # Plotting and verification helpers
├── output-dsfb-ddmf/ # DDMF run outputs (generated at runtime)
├── output-dsfb-lcss-hret/ # LCSS-HRET run outputs (generated at runtime)
├── README.md # Top-level overview + Colab links
├── LICENSE
└── CITATION.cff