Commit 70b6b93
exp: Pade denominator workspace uses LinearSolve's default algorithm
Drop the pinned LUFactorization in alloc_mem and let LinearSolve.init
size-select the algorithm (GenericLUFactorization for n <= 10, tuned
LAPACK/RecursiveFactorization choices above). The tiny-matrix generic LU
refactorizes in place with a cached pivot vector, making the warm solve!
allocation-free and at parity with (n = 5) or faster than (n = 10) the
raw LAPACK.gesv! this path originally used.
Best-of-N end-to-end exponential! times against the old gesv! code
(Julia 1.12, OpenBLAS single-threaded, this machine) are within ~3% at
all of n = 5, 10, 30, 60, 120, 250 for scales 0.3 and 4.0, with fewer
per-call allocation bytes at n <= 10.
One behavioral note: an exactly singular Pade denominator is now
resolved by the default algorithm's QR safety fallback instead of
throwing, matching generic \ semantics. The denominator is nonsingular
by construction for the branch norm bounds, so the retcode guard only
fires if the fallback itself fails.
Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>1 parent 849d306 commit 70b6b93
1 file changed
Lines changed: 11 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
19 | | - | |
20 | | - | |
21 | | - | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
22 | 24 | | |
23 | 25 | | |
24 | 26 | | |
25 | | - | |
| 27 | + | |
26 | 28 | | |
27 | 29 | | |
28 | 30 | | |
| |||
38 | 40 | | |
39 | 41 | | |
40 | 42 | | |
41 | | - | |
42 | | - | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
43 | 47 | | |
44 | 48 | | |
45 | 49 | | |
| |||
0 commit comments