[petsc-users] About MatLUFactor()

Hong Zhang hzhang at mcs.anl.gov
Fri Feb 25 11:25:33 CST 2011


 Golam:
> Oh, It thought MatMatSolve() was there as you mention something about it in
> the FAQ. Please add it then.

Checking carefully, I realize that petsc supports MatMatSolve() for
all matrix types
by calling MatMatSolve_Basic() which calls MatSolve() for each rhs vector,
except  few matrix types (seqdense is not included) that we provided
more efficient implementation.

A simplified ex1.c  with MatMatSolve() for petsc-dev is attached
(note: this only works with petsc-dev)
for your info.

Hong



>
> Thanks,
> Golam
>
> On Thu, Feb 24, 2011 at 7:31 PM, Hong Zhang <hzhang at mcs.anl.gov> wrote:
>>
>> For sequential dense in-place LU factorization, see
>> /src/mat/examples/tests/ex1.c.
>> For parallel, you need install PLAPACK.
>>
>> It seems we do not have MatMatSolve() for dense matrix format. I can
>> add it if you need it.
>>
>> Hong
>>
>> On Thu, Feb 24, 2011 at 8:43 PM, Golam Rabbani <mgrabbani at gmail.com>
>> wrote:
>> > Hi,
>> >
>> > I need to use MatLUFactor(), but do not know what to pass for the last 3
>> > arguments. Would you please explain a bit; I did not find any example
>> > code
>> > for this one.
>> >
>> > PetscErrorCode  MatLUFactor(Mat mat,IS row,IS col,const MatFactorInfo
>> > *info)
>> >
>> > My matrix is a dense one and the result from this call will be used in
>> > MatMatSolve().
>> >
>> > Regards,
>> > Golam
>> >
>
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ex1.c
Type: text/x-csrc
Size: 6160 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20110225/9d9f0879/attachment-0001.c>


More information about the petsc-users mailing list