[petsc-users] Questions about MatConvert BAIJ to AIJ
Barry Smith
bsmith at mcs.anl.gov
Wed Mar 18 12:50:44 CDT 2015
Do you mean that some entries in the matrices are different? That the nonzero structure is different? Something else?
In general if you are putting the values in with MatSetValuesBlocked() then I would expect the resulting matrices to have the same entries (though once you start solvers such as ILU you will have different convergence results).
Barry
> On Mar 18, 2015, at 12:12 PM, Chung-Kan Huang <ckhuangf at gmail.com> wrote:
>
> Hi,
>
> I created matrix with MATBAIJ and I use
> MatConvert(J, MATAIJ, MAT_REUSE_MATRIX, & J);
> to convert it to MATAIJ.
>
> I ran some tests
> MATBAIJ: create & use MATBAIJ for later assembly
> MATBAIJ2MATAIJ: create as MATBAIJ then convert to MATAIJ & use MATAIJ for later assembly
> MATAIJ: create & use MATAIJ for later assembly
>
> and I found following results
>
>
> MATBAIJ == MATBAIJ2MATAIJ != MATAIJ
> as I was expected to see
> MATBAIJ != MATBAIJ2MATAIJ == MATAIJ
>
> Is it a potential of bug or it is what I should actually expect?
>
> Thanks,
> Kan
> --
> Cheers
>
More information about the petsc-users
mailing list