[petsc-dev] Questions about MatCreateSeqBAIJWithArrays
Matthew Knepley
knepley at gmail.com
Fri Apr 4 12:44:27 CDT 2014
On Fri, Apr 4, 2014 at 12:38 PM, Travis Austin <austint73 at gmail.com> wrote:
> Hi all,
>
> I want to use MatCreateSeqBAIJWithArrays to set a sequential block matrix
> without allocating new arrays. I believe I understand how PETSc stores the
> matrix in the block format so I can transform my current data appropriately
> but I am confused by the following comments in the code (baij.c:line 3490
> in most recent git version). I've also pasted this comment below:
>
> "When block size is greater than 1 the matrix values must be stored using
> the BAIJ storage format (see the BAIJ code to determine this)."
>
> I then see this in the code (baij.c: line 3507) and have dealt with this
> when trying to use a block size larger than 1.
>
> if (bs != 1) SETERRQ1(PETSC_COMM_SELF,PETSC_ERR_SUP,"block size %D > 1
> is not supported yet",bs);
>
> I'm wondering if this is just an oversight and it really works. Can
> someone provide me an update on MatCreateSeqBAIJWithArrays? If it doesn't
> work, I'll probably go ahead and try and make it work.
>
It looks like whoever coded it only tested this with bs = 1. Feel free to
take that out and run. Even better would be
to write a little test as a PETSc example. That would make us pus hit into
master faster.
Thanks,
Matt
> Thanks,
> Travis
>
--
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-dev/attachments/20140404/06d65479/attachment.html>
More information about the petsc-dev
mailing list