由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Computation版 - calculation of inverse of "almost-singular" matrix
相关主题
Singular Value Decomposition一个matrix问题
有没有这种SVD的程序求助
Fast solver of linear equation system如何normalize矩阵
about Gaussian elimination zzcomplex matrices partitions help
请教如何用MATLAB去fit一个多项式?谁的学校有苏联的journal...
Matlab计算精度请教Multiplication of two Toeplitz matrices
lapack++ and blitz++编写 network coding 仿真的一个问题 (转载)
Questionkarmarkar's paper
相关话题的讨论汇总
话题: matrix话题: singular话题: inverse话题: almost话题: what
进入Computation版参与讨论
1 (共1页)
n**f
发帖数: 121
1
Assume I have a n*k matrix G where n>k. And I know rank(G) = k. According to
matrix theory G'G has full-rank and its inverse can be calculated. However
when I plug in the data to a numerical software, the software actually
complained that G'G is singular. For my problem, k is between 100 ~ 1000,
and
n is between 500 and 5000.
I manually wrote a C++ Gauss Elimination algorithm to verify that G'G has
rank
of k. But I notice that the Gauss Elimination algorithm would report the
matrix as singular if I set a threshold too high (i.e., 1e-7) to detect zero
elements. My suspicion is that the matrix is "almost singular".
I have the following questions:
1. What software (for example MATLAB) would automatically detect these
nearly
singular matrices and provide robust solution to the inverse?
2. What matrix metrics can be used to measure how close a matrix is to
singularity?
Many thanks!
t***s
发帖数: 4666
2
rule #1 in matrix computation, avoid calculating inverse explicitly at
all expense. use QR or SVD.

to
However
zero

【在 n**f 的大作中提到】
: Assume I have a n*k matrix G where n>k. And I know rank(G) = k. According to
: matrix theory G'G has full-rank and its inverse can be calculated. However
: when I plug in the data to a numerical software, the software actually
: complained that G'G is singular. For my problem, k is between 100 ~ 1000,
: and
: n is between 500 and 5000.
: I manually wrote a C++ Gauss Elimination algorithm to verify that G'G has
: rank
: of k. But I notice that the Gauss Elimination algorithm would report the
: matrix as singular if I set a threshold too high (i.e., 1e-7) to detect zero

n**f
发帖数: 121
3
how about LU?

【在 t***s 的大作中提到】
: rule #1 in matrix computation, avoid calculating inverse explicitly at
: all expense. use QR or SVD.
:
: to
: However
: zero

t***s
发帖数: 4666
4
no good.

【在 n**f 的大作中提到】
: how about LU?
n**f
发帖数: 121
5
I tried SVD and the condition number (i.e., max singular value / min
singular value) is huge ~1e14. I guess the singularity comes from the
problem formulation now...

【在 t***s 的大作中提到】
: no good.
s*******g
发帖数: 483
6
pinv() in matlab will solve the problem
it adds a diagonal identity matrix multiplied with a very small factor to
improve numerical stability
if you want to solve linear system, you can transfer it trivially to an
optimization problem and use conjugate gradient which is supposed to be
robust
n**f
发帖数: 121
7
Thanks. But I do not have access to MATLAB
All svd type of stuff is copied from Numerical Recipe.

【在 s*******g 的大作中提到】
: pinv() in matlab will solve the problem
: it adds a diagonal identity matrix multiplied with a very small factor to
: improve numerical stability
: if you want to solve linear system, you can transfer it trivially to an
: optimization problem and use conjugate gradient which is supposed to be
: robust

1 (共1页)
进入Computation版参与讨论
相关主题
karmarkar's paper请教如何用MATLAB去fit一个多项式?
a MatLab questionMatlab计算精度请教
问一个orthogonal transformation 的问题lapack++ and blitz++
Matlab Out of Memory 的问题Question
Singular Value Decomposition一个matrix问题
有没有这种SVD的程序求助
Fast solver of linear equation system如何normalize矩阵
about Gaussian elimination zzcomplex matrices partitions help
相关话题的讨论汇总
话题: matrix话题: singular话题: inverse话题: almost话题: what