Skip to content

Commit

Permalink
Update test for linear solver
Browse files Browse the repository at this point in the history
  • Loading branch information
astoeriko authored and aseyboldt committed Apr 24, 2024
1 parent 72726d0 commit e91aedd
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions sunode/test_solve.py
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,11 @@ def rhs(t, y, p):
'b': 0.2
}
problem = SympyProblem(params, states, rhs, derivative_params=[])
linear_solver_opts = ["dense", "dense_finitediff", "spgmr_finitediff", "spgmr"]
linear_solver_opts = ["dense", "dense_finitediff", "spgmr_finitediff", "spgmr", "band"]
for linear_solver in linear_solver_opts:
solver = Solver(problem, linear_solver=linear_solver)
if linear_solver == "band":
linear_solver_kwargs = {"upper_bandwidth": 1, "lower_bandwidth": 1}
else:
linear_solver_kwargs = {}
solver = Solver(problem, linear_solver=linear_solver, linear_solver_kwargs=linear_solver_kwargs)
check_call_solve(solver, param_vals, None)

0 comments on commit e91aedd

Please sign in to comment.