how to resolve linear equations of system

Andrew Colombi acolombi at gmail.com
Wed Jun 25 16:48:23 CDT 2008


> 1.

In general the answer is no, as there is no solution.  But, there are
some situations where an acceptable solution is found using
appropriate pre-conditioning.  It all depends on the exact
circumstance you are in. (For example, if the singularity is due to a
zero row in K, then using the Jacobi pre-conditioner will make it an
identity row.  This may or may not be acceptable depending on your
application.)

> 2.

Solving the linear system is almost always preferred as finding the
inverse to K explicitly boils down to repeatedly solving Kx=u where u
are individual columns of I.  Even if you are interested in solving
for many u's it is preferable to save K's factorization rather than
K's inverse.

Read Matrix Computations by Gene Golub, or an introductory Scientific
Computing book.  Many of these questions are addressed there.

-Andrew

On Wed, Jun 25, 2008 at 4:29 PM,  <enjoywm at cs.wm.edu> wrote:
> Hi,
> I have a linear equations of system such as Kx=u.
> 1. If K is singular, can I use KSPSolve to solve it?
> 2. If K is non-singular I also can use x= inverse(K)u to do it.
> Which one is better?
>
> Best,
> Yixun
>
>




More information about the petsc-users mailing list