3
$\begingroup$

Ok, so I know that if I have a system that looks like Ax=b it is foolish to solve it by solving for the inverse of A and one should instead use something like Gaussian elimination, or something like that. However, I am trying to calculate H(s) = B*(sI-A)^-1*C, where s is some scalar and A,B,C are matrices (of dimensions such that H(s) is a scalar too, if that helps). Now, this is a large system and I can't do this calculation symbolically, but when I try and plug in the s values that I am interested in, the (sI-A) matrix has really bad condition numbers (something like 10^10) and I highly doubt that my numeric results are in any way accurate --- it's not just the condition numbers, the answer comes out completely unlike what I would expect it to be. Do you have any ideas on either some algorithm that could help me out, or a math trick that would scale things in a such a way that inversion would not run into machine precision problems?

Just so everyone knows, this comes up when trying to calculate a transfer function from the state space representation of a linear system.

  • 1
    Might want to try the [computational science](http://scicomp.stackexchange.com/?as=1) stack exchange. SO tends to be more focused on programming qua programming.2012-03-06
  • 0
    It is not necessarily true that computing the inverse is bad for numerical stability. http://arxiv.org/abs/1201.60352012-03-09

3 Answers 3