flight_solver/cls/mod.rs
1//! Constrained least-squares (CLS) active-set solver and problem formulations.
2//!
3//! # Solver
4//!
5//! [`solve`] and [`solve_cls`] solve `min ‖Au − b‖²` subject to `umin ≤ u ≤ umax`
6//! using an active-set method with incremental QR updates via Givens rotations.
7//!
8//! # Problem formulations
9//!
10//! | Module | Formulation | `A` size |
11//! |--------|-------------|----------|
12//! | [`setup::wls`] | Weighted LS with regularisation | `(NV+NU) × NU` |
13//! | [`setup::ls`] | Plain LS (no regularisation) | `NV × NU` |
14
15/// Low-level linear algebra: Householder QR, back-substitution, constraint checking.
16pub mod linalg;
17/// Problem formulations (WLS, unreg LS).
18pub mod setup;
19/// Active-set constrained least-squares solver.
20pub mod solver;
21/// Core types, constants, and nalgebra type aliases.
22pub mod types;
23
24pub use solver::{solve, solve_cls};
25pub use types::{ExitCode, Mat, SolverStats, VecN};