[petsc-users] ERROR: Cannot pass default in for both input and output indices
Dominik Szczerba
dominik at itis.ethz.ch
Mon Oct 24 15:29:59 CDT 2011
>>> The best solution is for you to pass in an index set for either one or both of the IS arguments.
>>
>> This is changing very many lines in a few codes, so I am looking for a
>> minimalistic approach. Am I rigorously correct, or just lucky till the
>> next release, to replace the first PETSC_NULL with IS created with
>> ISCreateStride?
>
> Yes. Just make the local size of the scatter the same as the local size of the vector.
When doing so, I receive:
[1]PETSC ERROR: VecScatterCreate() line 1136 in
/home/dsz/pack/petsc-3.2-p3/src/vec/vec/utils/vscat.c Local scatter
sizes don't match
Inspecting vscat.c reveals:
ierr = ISGetLocalSize(ix,&nx);CHKERRQ(ierr);
...
ierr = ISGetLocalSize(iy,&ny);CHKERRQ(ierr);
...
if (nx != ny) SETERRQ(PETSC_COMM_SELF,PETSC_ERR_ARG_SIZ,"Local scatter
sizes don't match");
which looks quite suspicious to me, i.e. 1) If iy is PETSC_NULL, how
can its size be queried? 2) looks like NONE of the index sets is
actually allowed to be PETSC_NULL.
I would be very grateful for some clarifications here.
Many thanks and best regards,
Dominik
More information about the petsc-users
mailing list