sparsax.umf_solve_factor¶
-
sparsax.umf_solve_factor(token, b, trans=
False)[source]¶ Solve
A x = b(orA^T x = b) using a pre-computed UMFPACK factor.The UMFPACK counterpart of
lu_solve_factor(). Reuses the numeric factor held intoken(fromumf_factor()): triangular solves only, no factorization. The factor is not consumed. Not differentiable.- Parameters:¶
- token¶
token from
umf_factor()(an opaqueint64[2]array).- b¶
[n]or[n, n_rhs]float64 — right-hand side(s).- trans=
False¶ if
True, solveA^T x = b(the adjoint); otherwiseA x = b.
- Returns:¶
xwith the same shape asb.
Note
vmap(umf_solve_factor, in_axes=(None, 0))reuses one factor across a batch of right-hand sides — the Krylov-recurrence shape (one factor,m+1solves), run as one multi-column solve.vmap(umf_factor)thenvmap(umf_solve_factor)(both batched) gives one factor per batch element. The two nest in either order, as one native call.