Releases: VolkovIlia/semiflow
Release list
v0.12.0-beta — implicit stiff mode for SymmetricOperator (#16)
Implicit Stiff Mode for SymmetricOperator
The new path="implicit" option adds a dependency-free preconditioned-CG backward-Euler solver for externally-assembled symmetric operators, resolving the O(λ_max·t) timeout on stiff FEM operators.
Highlights
- Flagship benchmark: ~4 ms / sup_error 3.3e-12 on a Neumann N=400 ×10⁷ stiff operator
- Compare: explicit Lanczos ~56 s, scipy expm_multiply >90 s timeout
- Cost caveat: governed by √κ of Jacobi-preconditioned system, not strictly λ_max-independent
- Zero new dependencies: PCG + Jacobi preconditioning are dependency-free
- API: SymmetricOperator.evolve_batched, mass_lumped_evolve, MassKOperator.evolve all support
path="implicit"
CI Hardening
Alongside the #16 feature:
- Flagship Gates: Resolvent argument parsing + bounded L_RESOLVENT tick budget turned green
- Nightly miri: Scalar path (src/scalar/) validated
- Nightly bench-regression: Scoped core families + baseline guard to prevent false positives
Full Changelog
See CHANGELOG.md for complete details.
v0.11.0-beta — Python bindings for the 0.10.0 wave (#15)
[0.11.0-beta] — 2026-06-27
Python binding surface for the 0.10.0-beta feature wave (#11–#14 + A1).
Issues #11, #12, #13, #14, and the graph Krylov additions from the 0.10.x patch
series are now usable from Python via the semiflow-pde wheel. No breaking
changes to the existing Python surface or the Rust public API.
Added (Python bindings, #15)
SymmetricOperator.from_csr/SymmetricOperator.evolve_batched—
externally-assembled symmetric PSD sparse operators (FEM stiffness, Robin BC)
accepted as CSR arrays; batched time-stepping across multiple right-hand sides.symmetric_op_expmv_frechet— combined matrix-exponential action +
per-entry Fréchet gradient in one call.EntrySensitivityis not exposed as a
separate Python class; the gradient is returned directly from this function.MassKOperator/mass_lumped_evolve— generalized-eigenproblem(M, K)
propagation via the congruence chain = R⁻ᵀKR⁻¹; lumped-mass 3-liner path.ConservativeDiffusionChernoff/assemble_conservative_csr_1d—
conservative divergence-form diffusion with harmonic-mean face conductivities;
to_symmetric_operator()bridge to the Krylov engine.phi_action/phi_action_batched/Etdrk4— ETD φ-functions and the
Cox–Matthews ETDRK4 semilinear integrator. Nonlinearity is menu-based
(AllenCahn,Burgers,GrayScott,KuramotoSivashinsky); arbitrary
per-step Python callbacks are deferred (ADR-0179 / ADR-0189 wall preserved).Laplacian.from_csr— direct CSR-based Laplacian construction path.- PEP 561 stubs updated to cover all new symbols; 16/16 smoke tests green.
Changed
- Registry metadata:
ChangelogandRelease Noteslinks now appear on the
PyPI sidebar (semiflow-pde[project.urls]), the crates.iosemiflowpage
(README## Changelogsection), and the npm@semiflow/wasmpage
(README## Changelog / Release notessection).
v0.10.2-beta — Lanczos OOB fix at t≥4
Fixed
Lanczos OOB panic at t≥4 (graph_krylov)
- Off-by-one bug: wrote past
MAX_LANCZOS_DIM=18when Krylov dimension maxed out at large t·λ_max - Bug present since A1/ADR-0185; only triggered at deep t
- Fix: Lanczos now matches Chebyshev/dense expm at t∈{4,8,16} (max|Δ|≤1e-9, no panic)
- Gate
lanczos_large_t_no_oobvalidates the fix - The
--no-lanczosworkaround is no longer needed
Clippy cast_precision_loss in graph_par_speedup example
- Cleaned up compiler warning in
--all-targetsbuild
See CHANGELOG.md for full context.
v0.10.1-beta — Channel-parallel graph path (multicore)
Performance
Channel-parallel graph evolve
- ADR-0184 D3:
evolve_batchedand batched adjoint now split channels across cores viastd::thread::scope - Gated behind
parallelfeature (C≥2); each worker has its ownScratchPool - Graph Krylov ML path was previously single-threaded (parallel feature only covered Strang2D/3D grid kernels)
- Bit-identical to serial (0-ULP; forward + ascending-index gradient reduction per ADR-0184 D4/D5)
- Measured ~5–6× on i7-12700K (612–1942% CPU)
- Closes the "speed" half of the memory↔speed contradiction for graph diffusion / SSM layers
See CHANGELOG.md for full technical details and gate validation.
v0.10.0-beta — Krylov/Fréchet ML backend + 4 issues (#11/#12/#13/#14)
Summary
Five-feature wave (issues #11, #12, #13, #14 + A1 stiff fix): generic symmetric operators, conservative divergence-form diffusion, stiff multilayer conduction, ETD/φ semilinear integrator, and depth-independent Krylov + Fréchet for graph semigroups. All additive; no breaking changes to the 0.9.1-beta public surface.
Added
A1/A2 — Depth-independent graph-semigroup Krylov action + edge-weight Fréchet gradient
GraphKrylovChernoff,graph_expmv_frechet; ADR-0185, math §54graph_expmv(L, v, t, ε)computese^{−tL_G}·vwithout stepping through each time unit- Chebyshev default (O(1) working vectors) or Lanczos adaptive (O(m·N) basis, m ≈ 20–40, flat in
t) graph_expmv_frechetreturns∂J/∂wfor all edge weights via one augmented Krylov solve (Al-Mohy & Higham 2009)- Closes forward and backward speed ceilings exposed by v0.9.1-beta (#10)
- PyO3:
GraphKrylovpyclass +graph_expmv_frechetpyfunction in one GIL-releasing call - Honest limits: symmetric
L_Gonly; time-varyingL(t)out of scope
#13 — Generic externally-assembled symmetric-operator entry point
SymmetricOperator,MassKOperator,EntrySensitivity; ADR-0186, math §55SymmetricOperator::from_csraccepts any externally-assembled symmetric PSD sparse operator- FEM stiffness with Robin BC, anisotropic conductivity — not just graph Laplacians
MassKOperatorpropagatese^{−τM⁻¹K}·vvia congruence chain without formingM⁻¹Kexplicitly- Lumped
(M,K)path is a 3-liner - Honest limits: symmetric PSD required; consistent-mass differentiability deferred
#11 — Conservative (divergence-form) variable-coefficient diffusion
ConservativeDiffusionChernoff,assemble_conservative_csr_1d; ADR-0187, math §56- Harmonic-mean face conductivities reproduce series-resistance network at machine precision
- Handles sharp material interfaces (k-contrast 100:1 to 3025:1) where non-conservative methods give ≥50% error
- Crank–Nicolson wrapper (order()=2, A-stable, no CFL, one O(n) Thomas solve)
- Honest limits:
k > 0; full-tensor non-separable∂_x(k∂_y)out of scope
#14 — Stiff multilayer conduction via mass-weighted Krylov
MultilayerStack,multilayer_evolve,MassWeightedConservativeChernoff; ADR-0188, math §57- Maps physical
[(thickness, k, ρc)]→ node arrays on single uniform grid - Propagates in one depth-flat Krylov action for any integration span
- Beats explicit CFL by ~28000× on Shuttle TPS stack (k-contrast ≈ 3025×, ρc-contrast ≈ 27×)
- Optional A-stable CN convenience for O(1)-vector memory
- Honest limits: 1-D first; one global
dx; node-centered lumped mass only
#12 — ETD φ-functions and ETDRK4 semilinear integrator
phi_action,phi_action_batched,Etdrk4,Nonlinearity; ADR-0189, math §58phi_action_batchedcomputes φ₀…φ_p(τA)·v simultaneously via ONE augmented block-triangular matvec-only Taylor actionEtdrk4(Cox–Matthews 2002 / Kassam–Trefethen 2005) integrates∂ₜu = Lu + N(u)at order 4N(u)is declarativeNonlinearitytrait or fixed enum menu (AllenCahn,Burgers,GrayScott,KuramotoSivashinsky)- Never a per-step Python callback; ADR-0179 wall preserved
NonlinearityDiffenables end-to-end adjoint∂J/∂paramthrough one step- Honest limits:
L1-D divergence-form or symmetric graph only; deferred beyond this scope
Fixed
A1 stiff operator NaN bug (commit 9e5f557)
GraphKrylovChernoff's Chebyshev path silently returned garbage for stiff operators (λ_max ≳ 1400)- Fix: substep
s = ⌈z/Z_SAFE⌉(Z_SAFE = 200), mirroring Lanczos scaling - Plus fail-loud finiteness guard returning
SemiflowError::DomainViolation - Conservative high-contrast diffusion (
λ_max ∼ 10⁴) was affected - New test
cheb_stiff_regime(z ≈ 6400) was red before, green after (sup_error 1.0e-11)
See CHANGELOG.md for ADRs, validation gates, and complete honest limitations.
v0.9.1-beta
v0.9.0-beta.3
semiflow v0.9.0-beta.3
v0.9.0-beta.2
semiflow v0.9.0-beta.2
v0.9.0-beta.1
Release v0.9.0-beta.1 — manylinux x86_64 + macOS arm64 + Windows whee…