1 #include <petsc/private/fortranimpl.h> 2 #include <petscmat.h> 3 4 #if defined(PETSC_HAVE_FORTRAN_CAPS) 5 #define matcreatenest_ MATCREATENEST 6 #define matnestgetiss_ MATNESTGETISS 7 #elif !defined(PETSC_HAVE_FORTRAN_UNDERSCORE) 8 #define matcreatenest_ matcreatenest 9 #define matnestgetiss_ matnestgetiss 10 #endif 11 12 PETSC_EXTERN void PETSC_STDCALL matcreatenest_(MPI_Fint *comm,PetscInt *nr,IS is_row[],PetscInt *nc,IS is_col[],Mat a[],Mat *B,int *ierr) 13 { 14 CHKFORTRANNULLOBJECT(is_row); 15 CHKFORTRANNULLOBJECT(is_col); 16 *ierr = MatCreateNest(MPI_Comm_f2c(*comm),*nr,is_row,*nc,is_col,a,B); 17 } 18 19 PETSC_EXTERN void PETSC_STDCALL matnestgetiss_(Mat *A,IS rows[],IS cols[], int *ierr ) 20 { 21 CHKFORTRANNULLOBJECT(rows); 22 CHKFORTRANNULLOBJECT(cols); 23 *ierr = MatNestGetISs(*A,rows,cols); 24 } 25