hypre/IJ_mv/IJ_matrix.h
falgout 3ac73987e0 Simplified IJMatrixRead and IJMatrixPrint file formats. Did not change
the corresponding IJVector routines, but should.
Fixed opaque type stuff for IJMatrix and IJVector.
2002-07-30 16:50:32 +00:00

69 lines
2.6 KiB
C

/*BHEADER**********************************************************************
* (c) 1999 The Regents of the University of California
*
* See the file COPYRIGHT_and_DISCLAIMER for a complete copyright
* notice, contact person, and disclaimer.
*
* $Revision$
*********************************************************************EHEADER*/
/******************************************************************************
*
* Header info for the hypre_IJMatrix structures
*
*****************************************************************************/
#ifndef hypre_IJ_MATRIX_HEADER
#define hypre_IJ_MATRIX_HEADER
/*--------------------------------------------------------------------------
* hypre_IJMatrix:
*--------------------------------------------------------------------------*/
typedef struct hypre_IJMatrix_struct
{
MPI_Comm comm;
int *row_partitioning; /* distribution of rows across processors */
int *col_partitioning; /* distribution of columns */
int object_type; /* Indicates the type of "object" */
void *object; /* Structure for storing local portion */
void *translator; /* optional storage_type specfic structure
for holding additional local info */
int assemble_flag; /* indicates whether matrix has been
assembled */
} hypre_IJMatrix;
/*--------------------------------------------------------------------------
* Accessor macros: hypre_IJMatrix
*--------------------------------------------------------------------------*/
#define hypre_IJMatrixComm(matrix) ((matrix) -> comm)
#define hypre_IJMatrixRowPartitioning(matrix) ((matrix) -> row_partitioning)
#define hypre_IJMatrixColPartitioning(matrix) ((matrix) -> col_partitioning)
#define hypre_IJMatrixObjectType(matrix) ((matrix) -> object_type)
#define hypre_IJMatrixObject(matrix) ((matrix) -> object)
#define hypre_IJMatrixTranslator(matrix) ((matrix) -> translator)
#define hypre_IJMatrixAssembleFlag(matrix) ((matrix) -> assemble_flag)
/*--------------------------------------------------------------------------
* prototypes for operations on local objects
*--------------------------------------------------------------------------*/
#ifdef PETSC_AVAILABLE
/* IJMatrix_petsc.c */
int
hypre_GetIJMatrixParCSRMatrix( HYPRE_IJMatrix IJmatrix, Mat *reference )
#endif
#ifdef ISIS_AVAILABLE
/* IJMatrix_isis.c */
int
hypre_GetIJMatrixISISMatrix( HYPRE_IJMatrix IJmatrix, RowMatrix *reference )
#endif
#endif