Hello everyone!
I'm writing some C++ code that calculates participation factors and therefore uses matrix and vector multiplications. The point is that the operations coded in Vector.cpp and Matrix.cpp take quite a long time to complete when the model is defined by 500+ nodes and elements. Is there any way to access some faster functions within OpenSees? If so, which files should I include?
Thanks in advance.
Fast Matrix operations
Moderators: silvia, selimgunay, Moderators
Re: Fast Matrix operations
you could rewrite the classes or just methods that are slowing you down and rebuild the coed using your classes.
alternativily, you could write your code using the Matrix and Vector classes to set and obtain values in the double * you would use to store the data. The actual operations on the data (the double *) you code yourself or use the blas or boost libraries directly.
alternativily, you could write your code using the Matrix and Vector classes to set and obtain values in the double * you would use to store the data. The actual operations on the data (the double *) you code yourself or use the blas or boost libraries directly.
Re: Fast Matrix operations
Thanks for the reply!
I think I'll opt for obtaining double* data and using the blas libraries... they should be quite optimized by themselves.
I think I'll opt for obtaining double* data and using the blas libraries... they should be quite optimized by themselves.
Re: Fast Matrix operations
yes. though if you can get the ones optimized for your particular machine, e.g. intel mkl, they will work far better than just compiling and using the routines downloaded and compiled from netlib.
Re: Fast Matrix operations
Ok, thanks! I'll look into it.