1

I have to numerically multiply:

$A^{-1} B A$

where B is a diagonal square matrix, and A is symmetric. A is calculated from multiplying two non-square matrices,

$A = XX^T$

I know B and X, and A and its inverse are too large to be computed. X is not sparse, diagonal, anything. This is part of a longer calculation,

$X^T A^{-1} B A H^T$

where $H^T$ is a single column, zeros everywhere except one entry, where it is one. This makes $BAH^T$ computationally tractable - $BX$ and $X^T H^T$ are computed separately which is done easily enough. The biggest problem is in inverting $A$. Is there any way to calculate this without explicitly calculating $A$ or its inverse?

1 Answers1

1

You can apply any iterative solver for $$ Ay = BAH^T. $$ Since your $A=XX^T$ is symmetric positive definite, I suggest you use the CG method, which is advantegeous in terms of convergence speed and memory requirement.

It is only a few lines of code, just make sure you always compute $Ax$ as $X(X^Tx)$. There are a lot of implementations around that come with this feature, as the Python module Krypy written by a colleague of mine.

Jan
  • 1,008