Re: Matrix is singular to working precision



On Sep 16, 3:05 am, "kalyan goutham" <kalyan_gout...@xxxxxxxxxxxxx>
wrote:
Greg Heath <he...@xxxxxxxxxxxxxxxx> wrote in message
<1188039449.065578.306...@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>...

On Aug 25, 12:20 am, sandip....@xxxxxxxxx wrote:
hello everyone,
i am getting this error while computing the inverse of a
matrix Is there a way to circumvent or avoid the problem??

Yes.

Don't calculate the inverse of an ill-conditioned matrix.
If you are trying to solve a linear system of equations
it is not necessary. Just use the BACKSLASH operator.

If it is for another reason, please explain.

i have to perform the inverse of a matrix

"have"? That is rarely the case. If, as I had asked previously,
you would explain the underlying problem, maybe someone
can suggest a way to avoid doing that.

which may turn out
to be singular in the subsequent loops.i donot know how to
avoid this problem.

Go tp the source:

What, in the underlying problem, causes a singular matrix?

i cannot use the linear system of euation
since the inverse of the matrix is required for the
calculation of density function.

I'll make a wild guess that you are calculating the density
function of a Gaussian. Instead of giving you the answer,
I will ask you a question.

What causes the covariance matrix of a set of data to
be singular?

HINT: I can think of two reasons.

Once you understand this, you might be able to go back
and prevent this from happening.

could yo please help me find the solution.
is there a way to avoid the NAN numbers.

1. Reformulate the problem so that singular matrices
do not occur. Typically, this can be done.
2. ONLY if the above is not possible, Try one of the
the following
a. eye(size(A))/A
b. A\eye(size(A))
c. help PINV

Hope this helps.

Greg

.



Relevant Pages

  • Re: Matrix is singular to working precision
    ... is there a way to avoid the NAN numbers. ... I'm guessing that you do not have to use the inverse. ... If the matrix is singular, ... reformulate the problem as a least squares problem. ...
    (comp.soft-sys.matlab)
  • Re: Who, Their, His, Her
    ... Panel is quite representative. ... The abusers are simply folk faced with ... The number of miscalled "singular they" uses where the ... in speech but avoid it in writing.) ...
    (alt.usage.english)
  • Re: Biexponential curve-fitting
    ... One way I thought of to avoid this is to use ... singular except when D->0, which can be excluded easily by bound ... If you can plot z = fin some fashion such as gray-levels, ... then set up a grid; for each point in that grid, plot R_^2 ...
    (sci.math.num-analysis)
  • Re: Biexponential curve-fitting
    ... One problem seems that the model has two identical solutions (by ... One way I thought of to avoid this is to use ... singular except when D->0, which can be excluded easily by bound ... reliability using MATLAB's lsqcurvefit function. ...
    (sci.math.num-analysis)
  • Re: Announcing VYLZ-Protocol for gender-free-vocabulary
    ... I do my best to avoid having to use it. ... When I said "disguise itself as singular" I didn't really mean to ... And in those languages, as in older varieties of English, ...
    (alt.usage.english)