1 #include <petscsys.h> 2 3 static const PetscInt PetscFaceToP4estFace[4] = {2, 1, 3, 0}; 4 static const PetscInt PetscOrntToP4estOrnt[4][4] = {{0, 1, 1, 0},{1, 0, 0, 0},{1, 0, 0, 0},{0, 1, 1, 0}}; 5 6 static PetscInt PetscOrientToP4estOrient(PetscInt p4estFace, PetscInt petscOrient) 7 { 8 return PetscOrntToP4estOrnt[p4estFace][2+petscOrient]; 9 } 10 11 #define _append_pforest(a) a ## _p4est 12 #include "pforest.c" 13