309
309
310
310
function SciMLBase. solve (prob:: StaticLinearProblem ,
311
311
alg:: Nothing , args... ; kwargs... )
312
- if alg === nothing || alg isa DirectLdiv!
313
- u = prob. A \ prob. b
314
- elseif alg isa LUFactorization
315
- u = lu (prob. A) \ prob. b
316
- elseif alg isa QRFactorization
317
- u = qr (prob. A) \ prob. b
318
- elseif alg isa CholeskyFactorization
319
- u = cholesky (prob. A) \ prob. b
320
- elseif alg isa NormalCholeskyFactorization
321
- u = cholesky (Symmetric (prob. A' * prob. A)) \ (prob. A' * prob. b)
322
- elseif alg isa SVDFactorization
323
- u = svd (prob. A) \ prob. b
324
- else
325
- # Slower Path but handles all cases
326
- cache = init (prob, alg, args... ; kwargs... )
327
- return solve! (cache)
328
- end
329
- return SciMLBase. build_linear_solution (alg, u, nothing , prob)
312
+ u = prob. A \ prob. b
313
+ return SciMLBase. build_linear_solution (alg, u, nothing , prob; retcode = ReturnCode. Success)
330
314
end
331
315
332
316
function SciMLBase. solve (prob:: StaticLinearProblem ,
@@ -348,5 +332,5 @@ function SciMLBase.solve(prob::StaticLinearProblem,
348
332
cache = init (prob, alg, args... ; kwargs... )
349
333
return solve! (cache)
350
334
end
351
- return SciMLBase. build_linear_solution (alg, u, nothing , prob)
335
+ return SciMLBase. build_linear_solution (alg, u, nothing , prob; retcode = ReturnCode . Success )
352
336
end
0 commit comments