Closed ranocha closed 8 months ago
It looks like the current default algorithm will choose
https://github.com/SciML/LinearSolve.jl/blob/e712202303d0649a55b5143857b928df68eccc9f/src/default.jl#L185
when an SMatrix from StaticArrays.jl is passed. For example,
SMatrix
julia> using LinearSolve, StaticArrays julia> A = @SMatrix [1.0 2.0; 3.0 4.0]; b = @SVector [1.0, 2.0]; prob = LinearProblem(A, b) LinearProblem. In-place: true b: 2-element SVector{2, Float64} with indices SOneTo(2): 1.0 2.0 julia> sol = solve(prob) retcode: Default u: 2-element Vector{Float64}: 1.966189735084803e-16 0.49999999999999994 julia> sol.alg LinearSolve.DefaultLinearSolver(LinearSolve.DefaultAlgorithmChoice.KrylovJL_GMRES)
It would be nice if LinearSolve.jl could handle StaticArrays.jl efficiently.
CC @skopecz
This was fixed by https://github.com/SciML/LinearSolve.jl/pull/436 . The PR was already there I just needed to review and merge 😅
Thanks!
It looks like the current default algorithm will choose
https://github.com/SciML/LinearSolve.jl/blob/e712202303d0649a55b5143857b928df68eccc9f/src/default.jl#L185
when an
SMatrix
from StaticArrays.jl is passed. For example,It would be nice if LinearSolve.jl could handle StaticArrays.jl efficiently.
CC @skopecz