Page 1 of 1
(3 posts)

I've only been working with Eigen for a couple weeks and I'm also fairly new to coding in general. I'm working on a program which will use fairly large matrices and vectors (anywhere from 50 to 1000+ rows and columns). Most of my code runs very fast but the the small portion of my code that I've copied below runs very slowly. When the matrices are small ( < 15 x 15) the multiplication takes about a minute or two to compute, but when the matrices are larger ( > 40 x 40) it takes an hour if not much, much longer to compute.

Thanks very much for your help! The expression is only executed once, and optimizations were on. Your suggestion of performing only matrix-vector products helped a lot though and it now runs much much much faster.