modelon-community / Assimulo

Assimulo is a simulation package for solving ordinary differential equations.
https://jmodelica.org/assimulo/index.html
GNU Lesser General Public License v3.0
66 stars 16 forks source link

CVODE Parallel #67

Closed ivanZanardi closed 10 months ago

ivanZanardi commented 10 months ago

Hi, thanks for this nice package.

Just wondering if it is possible to run CVODE with multiple threads with DENSE linear solver.

Thanks. Ivan

PeterMeisrimelModelon commented 10 months ago

Hi Ivan,

Multithreaded LU factorization in CVode is currently only available when using Sparse matrices & SuperLU.

From a brief look into CVode's linear solver module, the only type of threading available for dense linear solves would be via using NVector_pthreads, i.e., a threaded vector implementation, which may only have a marginal effect, if any, on speeding up the LU factorization.

I may be missing something here though, I didn't check all linear solver modules available in Sundials.

/Peter

ivanZanardi commented 9 months ago

Hello, thank you for your response. I appreciate your explanation.

Let me rephrase my question: Is it possible to use the dense linear solver in conjunction with OpenBLAS-linked LAPACK for multithreaded operation?

I apologize for any confusion in my previous question. Thank you for your time.

PeterMeisrimelModelon commented 9 months ago

Hi Ivan,

CVode with the dense direct linear solver currently only supports the inbuilt LU factorization routines, not LAPACK/BLAS.

/Peter