2
$\begingroup$

Essentially, the following does not work, and I'm wondering if it can be made to:

NSum[ MatrixPower[B,n], {n,0,∞}]

(Here B is a large, square, primitive matrix.)

I.e., if eigenvalues, inverses and determinants are too taxing to compute, is there a way to approximate this series, in the manner of NSum?

$\endgroup$
2
  • 2
    $\begingroup$ Maybe NDSolveValue[{y'[t] == B . y[t] . y[t], y[0] == IdentityMatrix[4]}, y[1], {t, 0, 1}]? $\endgroup$
    – Michael E2
    Oct 25, 2022 at 16:21
  • $\begingroup$ Multiplying two matrices of size $5000 \times 5000$ takes about $3.2$ seconds on my machine, inverting one such matrix takes about $4.5$ seconds. (I mean matrices with floating point, machine precision entries, and packed.) The difference is small. What is the situation that you have in mind where inversion is much more expensive? $\endgroup$
    – user293787
    Oct 25, 2022 at 17:09

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.