[petsc-dev] Problems with MatGetSubMatrices_SeqSBAIJ

Alejandro Cosimo alecosimo at gmail.com
Tue May 3 15:05:46 CDT 2016


Thanks for your fix Hong.

2016-05-03 17:48 GMT+02:00 Hong <hzhang at mcs.anl.gov>:

> Alejandro :
> Fixed
>
> https://bitbucket.org/petsc/petsc/commits/0043d7fe17a5a8a1e4768ab560023392b3862352
> It will merged to petsc-release after our nightly tests.
>
> Your detailed report is very helpful, thanks!
>
> Hong
>
> Hi,
>>
>> After updating petsc from version 3.6.2 to 3.7, I had the following
>> problem:
>>
>> The result that I get from doing something like
>> MatMult(schurComplement,v1,v2); differs between the petsc versions that I
>> mentioned. I traced back the problem to the function
>> MatGetSubMatrices_SeqSBAIJ(). What I did in order to temporarily solve my
>> problem was to use in petsc 3.7 the code of MatGetSubMatrices_SeqSBAIJ()
>> corresponding to petsc 3.6.2.
>>
>> How I solved the problem is not a real solution, but it allows me to keep
>> working. My question is: is it a bug or do you think that there could be
>> something wrong with my code from which I use petsc?
>>
>> I think it should be a bug. If I run the ksp example 59 which uses
>> FETI-DP (whose implementation also uses something like
>> MatMult(schurComplement,v1,v2)) with petsc 3.7, I get the following
>> unexpected answer
>>
>> mpiexec -n 4 ./ex59 -npx 2 -npy 2 -nex 60 -ney 60 -ksp_max_it 3
>> ------------------FETI-DP stats-------------------------------
>> Number of degrees of freedom               :      355
>> Number of iterations                       :        3
>> Eigenvalues preconditioned operator        : 1.49e+00 8.86e+00
>> Error betweeen exact and computed solution : 1.91e+00
>> --------------------------------------------------------------
>>
>> If I run the same problem with petsc 3.7 but with
>> MatGetSubMatrices_SeqSBAIJ() corresponding to petsc 3.6.2, I get the
>> expected answer
>>
>> mpiexec -n 4 ./ex59 -npx 2 -npy 2 -nex 60 -ney 60 -ksp_max_it 3
>> ------------------FETI-DP stats-------------------------------
>> Number of degrees of freedom               :      355
>> Number of iterations                       :        3
>> Eigenvalues preconditioned operator        : 1.08e+00 2.08e+00
>> Error betweeen exact and computed solution : 3.60e-02
>> --------------------------------------------------------------
>>
>>
>> Thanks,
>> Alejandro
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-dev/attachments/20160503/ff68a518/attachment.html>


More information about the petsc-dev mailing list