Re: [petsc-users] error: Petsc has generated inconsistent data, MPI_Allreduce() called in different locations (code lines) on different processors

2019-04-07 Thread Eda Oktay via petsc-users
Dear Barry, Thank you for answering. I am sending my code, makefile and 2 PETSc Binary File where airfoil1_binary has odd numbered size (the one I got error) and gr_30_30_binary has even numbered size (I got correct result). I got the error for lines 164 and 169. By the way, I think I have done s

Re: [petsc-users] error: Petsc has generated inconsistent data, MPI_Allreduce() called in different locations (code lines) on different processors

2019-04-07 Thread Mark Adams via petsc-users
You have MatSetOption inside of a loop for the number of rows. This is apparently a collective operation. Move it to line 156. On Sun, Apr 7, 2019 at 5:44 AM Eda Oktay via petsc-users < petsc-users@mcs.anl.gov> wrote: > Dear Barry, > > Thank you for answering. I am sending my code, makefile and 2

Re: [petsc-users] PetscSortIntWithDataArray

2019-04-07 Thread Jed Brown via petsc-users
Fande Kong via petsc-users writes: > Hi All, > > *Input Parameters* > > *n - number of values* > *i - array of integers* > *Ii - second array of data* > *size - sizeof elements in the data array in bytes* > *work - workspace of "size" bytes used when sorting* > > > size is the size of one element