#include "petscis.h" PetscErrorCode PetscLayoutCreateFromSizes(MPI_Comm comm,PetscInt n,PetscInt N,PetscInt bs,PetscLayout *map)Collective
comm | - the MPI communicator | |
n | - the local size (or PETSC_DECIDE) | |
N | - the global size (or PETSC_DECIDE) | |
bs | - the block size (or PETSC_DECIDE) |
PetscLayoutCreateFromSizes(comm,n,N,bs,&layout);is a shorthand for
PetscLayoutCreate(comm,&layout); PetscLayoutSetLocalSize(layout,n); PetscLayoutSetSize(layout,N); PetscLayoutSetBlockSize(layout,bs); PetscLayoutSetUp(layout);