Why is the following matrix numerically unstable?

77 Views Asked by At

I am trying to perform LU Decomposition on the following n-dimensional square matrix

$$ C = [c_{ij}], \ c_{ij} = \frac{1}{i + j - 1}, \ i,j = 1, ..., n \ , $$

and use it to solve linear systems. But even using a small $n$ such as $n = 5$ provides an inaccurate solution to a linear system, so I tried to find its condition number from $n = 1, ...., 10$ to see if the matrix is the reason for such numerical inaccuracy. Using Python's numpy.linalg.cond with Frobenius norm as its matrix norm, I got the following result:

$$ \begin{array}[c|c] nn & \text{condition number} \\ 1 & 1.0 \\ 2 & 19.333333333333336 \\ 3 & 526.1588210797212 \\ 4 & 15613.793559642412 \\ 5 & 480849.11699558934 \\ 6 & 15118987.131683761 \\ 7 & 481747254.15379786 \\ 8 & 15493617537.994034 \\ 9 & 501730274777.0853 \\ 10 & 16332405266874.348 \\ \end{array} $$

Clearly, $C$ is an ill-conditioned matrix. But why? Is it because as $n$ gets larger, the entries of $C$ approaches zero? Is this always the case with rational functions where the denominator increases faster compared to the numerator?

1

There are 1 best solutions below

1
On BEST ANSWER

It's not that the entries approach $0$, it's that they approach $0$ in a very regular way, so that the last row is very nearly a linear combination of the other rows.

Look up: Hilbert matrix