xref: /petsc/src/mat/impls/baij/mpi/mpibaij.h (revision 90f02eec332fcca4c33b4e7b21cabed76bf0614e)
1 /* $Id: mpibaij.h,v 1.3 1996/08/08 14:43:40 bsmith Exp bsmith $ */
2 
3 #include "src/mat/impls/baij/seq/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   int           donotstash;             /* if 1, off processor entries dropped */
27   MPI_Request   *send_waits;            /* array of send requests */
28   MPI_Request   *recv_waits;            /* array of receive requests */
29   int           nsends, nrecvs;         /* numbers of sends and receives */
30   Scalar        *svalues, *rvalues;     /* sending and receiving data */
31   int           rmax;                   /* maximum message length */
32   int           *colmap;                /* local col number of off-diag col */
33   int           *garray;                /* work array */
34 
35   /* The following variables are used for matrix-vector products */
36 
37   Vec           lvec;              /* local vector */
38   VecScatter    Mvctx;             /* scatter context for vector */
39   int           roworiented;       /* if true, row-oriented input, default true */
40 
41   /* The following variables are for MatGetRow() */
42 
43   int           *rowindices;       /* column indices for row */
44   Scalar        *rowvalues;        /* nonzero values in row */
45   PetscTruth    getrowactive;      /* indicates MatGetRow(), not restored */
46 } Mat_MPIBAIJ;
47 
48 
49 #endif
50