25#if defined(HAVE_METIS) 
   28#if defined(HAVE_PARMETIS) 
   35#if defined(METIS_USE_DOUBLEPRECISION) || REALTYPEWIDTH == 64 
   36#error METIS must be compiled in single precision for Octopus. 
   39void FC_FUNC_(oct_metis_setdefaultoptions,
 
   40              OCT_METIS_SETDEFAULTOPTIONS)(idx_t *options) {
 
   41  METIS_SetDefaultOptions(options);
 
   44int FC_FUNC_(oct_metis_partgraphrecursive, OCT_METIS_PARTGRAPHRECURSIVE)(
 
   45    idx_t *nvtxs, idx_t *ncon, idx_t *xadj, idx_t *adjncy, idx_t *nparts,
 
   46    real_t *tpwgts, real_t *ubvec, idx_t *options, idx_t *objval, idx_t *part) {
 
   48  return METIS_PartGraphRecursive(nvtxs, ncon, xadj, adjncy, NULL, NULL, NULL,
 
   49                                  nparts, tpwgts, ubvec, options, objval, part);
 
   52int FC_FUNC_(oct_metis_partgraphkway, OCT_METIS_PARTGRAPHKWAY)(
 
   53    idx_t *nvtxs, idx_t *ncon, idx_t *xadj, idx_t *adjncy, idx_t *nparts,
 
   54    real_t *tpwgts, real_t *ubvec, idx_t *options, idx_t *objval, idx_t *part) {
 
   56  return METIS_PartGraphKway(nvtxs, ncon, xadj, adjncy, NULL, NULL, NULL,
 
   57                             nparts, tpwgts, ubvec, options, objval, part);
 
   64void FC_FUNC_(oct_parmetis_v3_partkway,
 
   65              OCT_PARMETIS_V3_PARTKWAY)(idx_t *vtxdist, idx_t *xadj, idx_t *adjncy,
 
   66                                     idx_t *ncon, idx_t *nparts, real_t *tpwgts,
 
   67                                     real_t *ubvec, idx_t *options,
 
   68                                     idx_t *edgecut, idx_t *part,
 
   70  idx_t wgtflag = 0, numflag = 1;
 
   74  comm = MPI_Comm_f2c(*fcomm);
 
   76  ParMETIS_V3_PartKway(vtxdist, xadj, adjncy, NULL, NULL, &wgtflag, &numflag,
 
   77                       ncon, nparts, tpwgts, ubvec, options, edgecut, part,