1 /* $Id: mpibaij.h,v 1.1 1996/06/03 19:55:56 balay Exp balay $ */ 2 3 #include "baij.h" 4 5 #if !defined(__MPIBAIJ_H) 6 #define __MPIBAIJ_H 7 8 typedef struct { 9 int *rowners, *cowners; /* ranges owned by each processor */ 10 int m, n; /* local rows and columns */ 11 int M, N; /* global rows and columns */ 12 int rstart, rend; /* starting and ending owned rows */ 13 int cstart, cend; /* starting and ending owned columns */ 14 Mat A, B; /* local submatrices: A (diag part), 15 B (off-diag part) */ 16 int size; /* size of communicator */ 17 int rank; /* rank of proc in communicator */ 18 int bs, bs2; /* block size, bs2 = bs*bs */ 19 int Mbs, Nbs; 20 int mbs, nbs; 21 22 /* The following variables are used for matrix assembly */ 23 24 InsertMode insertmode; /* mode for MatSetValues */ 25 Stash stash; /* stash for non-local elements */ 26 MPI_Request *send_waits; /* array of send requests */ 27 MPI_Request *recv_waits; /* array of receive requests */ 28 int nsends, nrecvs; /* numbers of sends and receives */ 29 Scalar *svalues, *rvalues; /* sending and receiving data */ 30 int rmax; /* maximum message length */ 31 int *colmap; /* local col number of off-diag col */ 32 int *garray; /* work array */ 33 34 /* The following variables are used for matrix-vector products */ 35 36 Vec lvec; /* local vector */ 37 VecScatter Mvctx; /* scatter context for vector */ 38 int roworiented; /* if true, row-oriented input, default true */ 39 40 /* The following variables are for MatGetRow() */ 41 42 int *rowindices; /* column indices for row */ 43 Scalar *rowvalues; /* nonzero values in row */ 44 PetscTruth getrowactive; /* indicates MatGetRow(), not restored */ 45 } Mat_MPIBAIJ; 46 47 48 #endif 49