The sparsity check of the Jacobian matrix (semi implicit methods) is done at every integration step. This can be avoided, as the use of a sparse matrix is either true or false for the whole problem.
The best way would be to add a value (whether sparse should be used or not) in the addSolverParam dictionary and check it once at the first step.
Functions to modify:
_euler_semiimplicit
_midpoint_semiimplicit
Code TODO comment (remove once issue is closed):
TODO: change this checking of the sparsity type of the matrix only once
The sparsity check of the Jacobian matrix (semi implicit methods) is done at every integration step. This can be avoided, as the use of a sparse matrix is either true or false for the whole problem.
The best way would be to add a value (whether sparse should be used or not) in the addSolverParam dictionary and check it once at the first step.
Functions to modify: _euler_semiimplicit _midpoint_semiimplicit
Code TODO comment (remove once issue is closed):
TODO: change this checking of the sparsity type of the matrix only once