[petsc-users] MatMatSolve in sequential call

Hong Zhang hzhang at mcs.anl.gov
Mon Aug 13 10:23:16 CDT 2012


Alexander :
Hmm, isrow is a matrix ordering, likely a bug :-(
Can you send us a stand-alone code that reproduces this error?
Do you use an external package for MatMatSolve()?

Hong

 On 13.08.2012 16:54, Hong Zhang wrote:
>
> On Mon, Aug 13, 2012 at 8:17 AM, Alexander Grayver <
> agrayver at gfz-potsdam.de> wrote:
>
>> Hello,
>>
>> Trying to call this routine on 1 proc:
>>
>> call MatMatSolve(F,B,solutions,ierr);CHKERRQ(ierr)
>>
>> I get following crash:
>>
>> [0]PETSC ERROR: --------------------- Error Message
>> ------------------------------------
>> [0]PETSC ERROR: Null argument, when expecting valid pointer!
>> [0]PETSC ERROR: Null Object: Parameter # 1!
>>
>
> This indicates matrix F (factored matrix) is not provided.
>
>  I tested petsc-3.3/src/mat/examples/tests/ex129.c with MatMatSovle():
> ./ex129 -mat_type aij -dof 2
> which works fine.
>
>
> Hong,
>
> I get matrix F as:
> call PCFactorGetMatrix(pc,F,ierr);CHKERRQ(ierr)
>
> Please note that all checks in MatMatSolve are done before this crash.
> So matrix F is provided correctly and it is not zero.
>
> The reason is that iscol and isrow == 0 here:
>
>  PetscErrorCode MatMatSolve_SeqAIJ(Mat A,Mat B,Mat X)
>  {
>    Mat_SeqAIJ      *a = (Mat_SeqAIJ*)A->data;
>    IS              iscol = a->col,isrow = a->row;
>
> ...
>    ierr = ISGetIndices(isrow,&rout);CHKERRQ(ierr); r = rout;  <<<< crash
>
> Again, same code runs fine when nproc > 1
>
>
>  Hong
>
>
>> [0]PETSC ERROR:
>> ------------------------------------------------------------------------
>> [0]PETSC ERROR: Petsc Release Version 3.3.0, Patch 2, Fri Jul 13 15:42:00
>> CDT 2012
>> [0]PETSC ERROR: See docs/changes/index.html for recent updates.
>> [0]PETSC ERROR: See docs/faq.html for hints about trouble shooting.
>> [0]PETSC ERROR: See docs/index.html for manual pages.
>> [0]PETSC ERROR:
>> ------------------------------------------------------------------------
>> [0]PETSC ERROR: /app on a openmpi-i named glic1 by ag Mon Aug 13 15:06:36
>> 2012
>> [0]PETSC ERROR: Libraries linked from
>> /home/lib/petsc-3.3-p2/openmpi-intel-complex-debug-f-ds/lib
>> [0]PETSC ERROR: Configure run at Wed Jul 18 12:14:30 2012
>> [0]PETSC ERROR:
>> ------------------------------------------------------------------------
>> [0]PETSC ERROR: ISGetIndices() line 370 in
>> /home/lib/petsc-3.3-p2/src/vec/is/interface/index.c
>> [0]PETSC ERROR: MatMatSolve_SeqAIJ() line 1109 in
>> /home/lib/petsc-3.3-p2/src/mat/impls/aij/seq/aijfact.c
>> [0]PETSC ERROR: MatMatSolve() line 3122 in
>> /home/lib/petsc-3.3-p2/src/mat/interface/matrix.c
>>
>> The same code works fine on nproc > 1.
>>
>> Any ideas?
>>
>> --
>> Regards,
>> Alexander
>>
>
>
>
> --
> Regards,
> Alexander
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20120813/00c80a89/attachment.html>


More information about the petsc-users mailing list