lib/test/EBAMRTools/restart.cpp
/*  Dumps the field data and the VOF data, but not the geometry (which must be
 *  recomputed when restarting).
*/
Dumps the field data and the VOF data, but not the geometry (which must be
recomputed when restarting).
Dumps the field data and the VOF data but not the geometry ( which must be recomputed when restarting ) .
void
EBRestart::dumpHDF( std::string                          a_filename,
                    Vector<std::string>                  a_compNames,
                    int                                  a_ghosts,
                    const Box&                           a_domainCoar,
                    const EBIndexSpace*                  a_ebIndexSpace,
                    const Vector<LevelData<EBCellFAB>*>& a_ebvector,
                    const Vector<DisjointBoxLayout>&     a_grids,
                    int                                  a_nlevs,
                    int                                  a_ncomps,
                    Real                                 a_dx,
                    int                                  a_refRatio )
{
#ifdef CH_USE_HDF5
  RealVect dxvec( RealVect::Unit*a_dx*pow(double(a_refRatio),
                                          double(a_nlevs-1)) );
  HDF5Handle handle;
  createEBFile(handle, a_filename, a_nlevs,
               Vector<int>(a_nlevs,a_refRatio),
               a_domainCoar, dxvec, a_ghosts*IntVect::Unit);
  writeCellCenteredNames(handle, a_compNames);
  for ( int lev=0;lev<a_nlevs;++lev )
  {
    writeCellCentered(handle, lev, a_ebvector[lev]);
  }
  handle.close();
#endif 
}
void EBRestart :: dumpHDF ( std :: string a_filename , Vector < std :: string > a_compNames , int a_ghosts , const Box & a_domainCoar , const EBIndexSpace * a_ebIndexSpace , const Vector < LevelData < EBCellFAB > * > & a_ebvector , const Vector < DisjointBoxLayout > & a_grids , int a_nlevs , int a_ncomps , Real a_dx , int a_refRatio ) { #ifdef CH_USE_HDF5 RealVect dxvec ( RealVect :: Unit * a_dx * pow ( double ( a_refRatio ) , double ( a_nlevs - 1 ) ) ) ; HDF5Handle handle ; createEBFile ( handle , a_filename , a_nlevs , Vector < int > ( a_nlevs , a_refRatio ) , a_domainCoar , dxvec , a_ghosts * IntVect :: Unit ) ; writeCellCenteredNames ( handle , a_compNames ) ; for ( int lev = 0 ; lev < a_nlevs ; ++ lev ) { writeCellCentered ( handle , lev , a_ebvector [ lev ] ) ; } handle . close ( ) ; #endif }
Dumps the field data and the VOF data, but not the geometry (which must be
  recomputed when restarting).
Dumps the field data and the VOF data but not the geometry ( which must be recomputed when restarting ) .
// CH_USE_HDF5