Block-Structured AMR Software Framework
amrex::AmrData Class Reference

#include <AMReX_AmrData.H>

Public Member Functions

 AmrData ()
 
 ~AmrData ()
 
bool ReadData (const std::string &filename, Amrvis::FileType filetype)
 
bool ReadNonPlotfileData (const std::string &filename, Amrvis::FileType filetype)
 
const Vector< std::string > & PlotVarNames () const
 
int FinestLevel () const
 
const Vector< int > & RefRatio () const
 
const BoxArrayboxArray (int level) const
 
const DistributionMappingDistributionMap (int level) const
 
const Vector< Box > & ProbDomain () const
 
const Vector< Real > & ProbSize () const
 
const Vector< Real > & ProbLo () const
 
const Vector< Real > & ProbHi () const
 
void CellLoc (int lev, IntVect ix, Vector< Real > &pos) const
 
void LoNodeLoc (int lev, IntVect ix, Vector< Real > &pos) const
 
void HiNodeLoc (int lev, IntVect ix, Vector< Real > &pos) const
 
Vector< Real > CellSize (int iLevel) const
 
void IntVectFromLocation (const int finestFillLevel, const Vector< Real > &location, IntVect &ivLoc, int &ivLevel, IntVect &ivFinestFillLev) const
 
const Vector< Vector< Vector< Real > > > & GridLocLo () const
 
const Vector< Vector< Vector< Real > > > & GridLocHi () const
 
const Vector< Vector< Real > > & DxLevel () const
 
const Vector< int > & LevelSteps () const
 
int NComp () const
 
int BoundaryWidth () const
 
int NGrow () const
 
int CoordSys () const
 
Real Time () const
 
const std::string & PlotFileVersion () const
 
void FillVar (FArrayBox *destFab, const Box &destBox, int finestFillLevel, const std::string &varName, int procWithFabs)
 
void FillVar (Vector< FArrayBox * > &destFabs, const Vector< Box > &destBoxes, int finestFillLevel, const std::string &varName, int procWithFabs)
 
void FillVar (MultiFab &destMultiFab, int finestFillLevel, const Vector< std::string > &varNames, const Vector< int > &destFillComps)
 
void FillVar (MultiFab &destMultiFab, int finestFillLevel, const std::string &varname, int destcomp=0)
 
const std::string & GetFileName () const
 
void SetFileType (Amrvis::FileType type)
 
Amrvis::FileType GetFileType () const
 
bool CartGrid () const
 
bool GetShowBody () const
 
void SetShowBody (bool tf)
 
int CartGridVersion () const
 
Real VfEps (int level) const
 
void SetVfEps (Real *newvfeps, int finestlev)
 
bool Terrain () const
 
void SetBoundaryWidth (int width)
 
bool CanDerive (const std::string &name) const
 
bool CanDerive (const Vector< std::string > &names) const
 
int NumDeriveFunc () const
 
void ListDeriveFunc (std::ostream &os) const
 
int StateNumber (const std::string &statename) const
 
int FinestContainingLevel (const Box &b, int startLevel) const
 
int FinestIntersectingLevel (const Box &b, int startLevel) const
 
int NIntersectingGrids (int level, const Box &b) const
 
MultiFabGetGrids (int level, int componentIndex)
 
MultiFabGetGrids (int level, int componentIndex, const Box &onBox)
 
void FlushGrids ()
 
void FlushGrids (int componentIndex)
 
bool MinMax (const Box &onBox, const std::string &derived, int level, Real &dataMin, Real &dataMax)
 

Static Public Member Functions

static void SetVerbose (bool tf)
 
static bool Verbose ()
 
static void SetSkipPltLines (int spl)
 
static void SetStaticBoundaryWidth (int bw)
 

Protected Attributes

Vector< Vector< MultiFab * > > dataGrids
 
Vector< Vector< std::vector< bool > > > dataGridsDefined
 
Vector< Vector< VisMF * > > visMF
 
Vector< intcompIndexToVisMFMap
 
Vector< intcompIndexToVisMFComponentMap
 
int finestLevel
 
Vector< intrefRatio
 
Vector< Vector< Real > > dxLevel
 
Vector< Vector< Vector< Real > > > gridLocLo
 
Vector< Vector< Vector< Real > > > gridLocHi
 
Vector< BoxprobDomain
 
Vector< BoxmaxDomain
 
Vector< Real > probSize
 
Vector< Real > probLo
 
Vector< Real > probHi
 
Real time
 
Vector< std::string > plotVars
 
Vector< Real > vfEps
 
Vector< Real > afEps
 
int nComp
 
int nGrow
 
int nRegions
 
int boundaryWidth
 
int coordSys
 
Vector< Vector< FArrayBox * > > regions
 
BoxArray fabBoxArray
 
std::string plotFileVersion
 
Amrvis::FileType fileType
 
bool bCartGrid
 
bool bShowBody
 
int vCartGrid
 
bool bTerrain
 
Vector< intlevelSteps
 

Private Member Functions

void FillInterior (FArrayBox &dest, int level, const Box &subbox)
 
void PcInterp (FArrayBox &fine, const FArrayBox &crse, const Box &subbox, int lrat)
 
FArrayBoxReadGrid (std::istream &is, int numVar)
 
bool DefineFab (int level, int componentIndex, int fabIndex)
 

Private Attributes

std::string fileName
 

Static Private Attributes

static Amrvis::FileType defaultFileType
 
static bool verbose = false
 
static int skipPltLines = 0
 
static int sBoundaryWidth = 0
 

Constructor & Destructor Documentation

◆ AmrData()

amrex::AmrData::AmrData ( )

◆ ~AmrData()

amrex::AmrData::~AmrData ( )

Member Function Documentation

◆ BoundaryWidth()

int amrex::AmrData::BoundaryWidth ( ) const
inline

◆ boxArray()

const BoxArray& amrex::AmrData::boxArray ( int  level) const
inline

◆ CanDerive() [1/2]

bool amrex::AmrData::CanDerive ( const std::string &  name) const

◆ CanDerive() [2/2]

bool amrex::AmrData::CanDerive ( const Vector< std::string > &  names) const

◆ CartGrid()

bool amrex::AmrData::CartGrid ( ) const
inline

◆ CartGridVersion()

int amrex::AmrData::CartGridVersion ( ) const
inline

◆ CellLoc()

void amrex::AmrData::CellLoc ( int  lev,
IntVect  ix,
Vector< Real > &  pos 
) const

◆ CellSize()

Vector<Real> amrex::AmrData::CellSize ( int  iLevel) const
inline

◆ CoordSys()

int amrex::AmrData::CoordSys ( ) const
inline

◆ DefineFab()

bool amrex::AmrData::DefineFab ( int  level,
int  componentIndex,
int  fabIndex 
)
private

◆ DistributionMap()

const DistributionMapping& amrex::AmrData::DistributionMap ( int  level) const
inline

◆ DxLevel()

const Vector< Vector<Real> >& amrex::AmrData::DxLevel ( ) const
inline

◆ FillInterior()

void amrex::AmrData::FillInterior ( FArrayBox dest,
int  level,
const Box subbox 
)
private

◆ FillVar() [1/4]

void amrex::AmrData::FillVar ( FArrayBox destFab,
const Box destBox,
int  finestFillLevel,
const std::string &  varName,
int  procWithFabs 
)

◆ FillVar() [2/4]

void amrex::AmrData::FillVar ( MultiFab destMultiFab,
int  finestFillLevel,
const std::string &  varname,
int  destcomp = 0 
)

◆ FillVar() [3/4]

void amrex::AmrData::FillVar ( MultiFab destMultiFab,
int  finestFillLevel,
const Vector< std::string > &  varNames,
const Vector< int > &  destFillComps 
)

◆ FillVar() [4/4]

void amrex::AmrData::FillVar ( Vector< FArrayBox * > &  destFabs,
const Vector< Box > &  destBoxes,
int  finestFillLevel,
const std::string &  varName,
int  procWithFabs 
)

◆ FinestContainingLevel()

int amrex::AmrData::FinestContainingLevel ( const Box b,
int  startLevel 
) const

◆ FinestIntersectingLevel()

int amrex::AmrData::FinestIntersectingLevel ( const Box b,
int  startLevel 
) const

◆ FinestLevel()

int amrex::AmrData::FinestLevel ( ) const
inline

◆ FlushGrids() [1/2]

void amrex::AmrData::FlushGrids ( )

◆ FlushGrids() [2/2]

void amrex::AmrData::FlushGrids ( int  componentIndex)

◆ GetFileName()

const std::string& amrex::AmrData::GetFileName ( ) const
inline

◆ GetFileType()

Amrvis::FileType amrex::AmrData::GetFileType ( ) const
inline

◆ GetGrids() [1/2]

MultiFab & amrex::AmrData::GetGrids ( int  level,
int  componentIndex 
)

◆ GetGrids() [2/2]

MultiFab & amrex::AmrData::GetGrids ( int  level,
int  componentIndex,
const Box onBox 
)

◆ GetShowBody()

bool amrex::AmrData::GetShowBody ( ) const
inline

◆ GridLocHi()

const Vector< Vector< Vector<Real> > >& amrex::AmrData::GridLocHi ( ) const
inline

◆ GridLocLo()

const Vector< Vector< Vector<Real> > >& amrex::AmrData::GridLocLo ( ) const
inline

◆ HiNodeLoc()

void amrex::AmrData::HiNodeLoc ( int  lev,
IntVect  ix,
Vector< Real > &  pos 
) const

◆ IntVectFromLocation()

void amrex::AmrData::IntVectFromLocation ( const int  finestFillLevel,
const Vector< Real > &  location,
IntVect ivLoc,
int ivLevel,
IntVect ivFinestFillLev 
) const

◆ LevelSteps()

const Vector<int>& amrex::AmrData::LevelSteps ( ) const
inline

◆ ListDeriveFunc()

void amrex::AmrData::ListDeriveFunc ( std::ostream &  os) const

◆ LoNodeLoc()

void amrex::AmrData::LoNodeLoc ( int  lev,
IntVect  ix,
Vector< Real > &  pos 
) const

◆ MinMax()

bool amrex::AmrData::MinMax ( const Box onBox,
const std::string &  derived,
int  level,
Real &  dataMin,
Real &  dataMax 
)

◆ NComp()

int amrex::AmrData::NComp ( ) const
inline

◆ NGrow()

int amrex::AmrData::NGrow ( ) const
inline

◆ NIntersectingGrids()

int amrex::AmrData::NIntersectingGrids ( int  level,
const Box b 
) const

◆ NumDeriveFunc()

int amrex::AmrData::NumDeriveFunc ( ) const

◆ PcInterp()

void amrex::AmrData::PcInterp ( FArrayBox fine,
const FArrayBox crse,
const Box subbox,
int  lrat 
)
private

◆ PlotFileVersion()

const std::string& amrex::AmrData::PlotFileVersion ( ) const
inline

◆ PlotVarNames()

const Vector<std::string>& amrex::AmrData::PlotVarNames ( ) const
inline

◆ ProbDomain()

const Vector<Box>& amrex::AmrData::ProbDomain ( ) const
inline

◆ ProbHi()

const Vector<Real>& amrex::AmrData::ProbHi ( ) const
inline

◆ ProbLo()

const Vector<Real>& amrex::AmrData::ProbLo ( ) const
inline

◆ ProbSize()

const Vector<Real>& amrex::AmrData::ProbSize ( ) const
inline

◆ ReadData()

bool amrex::AmrData::ReadData ( const std::string &  filename,
Amrvis::FileType  filetype 
)

◆ ReadGrid()

FArrayBox * amrex::AmrData::ReadGrid ( std::istream &  is,
int  numVar 
)
private

◆ ReadNonPlotfileData()

bool amrex::AmrData::ReadNonPlotfileData ( const std::string &  filename,
Amrvis::FileType  filetype 
)

◆ RefRatio()

const Vector<int>& amrex::AmrData::RefRatio ( ) const
inline

◆ SetBoundaryWidth()

void amrex::AmrData::SetBoundaryWidth ( int  width)
inline

◆ SetFileType()

void amrex::AmrData::SetFileType ( Amrvis::FileType  type)

◆ SetShowBody()

void amrex::AmrData::SetShowBody ( bool  tf)
inline

◆ SetSkipPltLines()

static void amrex::AmrData::SetSkipPltLines ( int  spl)
inlinestatic

◆ SetStaticBoundaryWidth()

static void amrex::AmrData::SetStaticBoundaryWidth ( int  bw)
inlinestatic

◆ SetVerbose()

static void amrex::AmrData::SetVerbose ( bool  tf)
inlinestatic

◆ SetVfEps()

void amrex::AmrData::SetVfEps ( Real *  newvfeps,
int  finestlev 
)

◆ StateNumber()

int amrex::AmrData::StateNumber ( const std::string &  statename) const

◆ Terrain()

bool amrex::AmrData::Terrain ( ) const
inline

◆ Time()

Real amrex::AmrData::Time ( ) const
inline

◆ Verbose()

static bool amrex::AmrData::Verbose ( )
inlinestatic

◆ VfEps()

Real amrex::AmrData::VfEps ( int  level) const
inline

Member Data Documentation

◆ afEps

Vector<Real> amrex::AmrData::afEps
protected

◆ bCartGrid

bool amrex::AmrData::bCartGrid
protected

◆ boundaryWidth

int amrex::AmrData::boundaryWidth
protected

◆ bShowBody

bool amrex::AmrData::bShowBody
protected

◆ bTerrain

bool amrex::AmrData::bTerrain
protected

◆ compIndexToVisMFComponentMap

Vector<int> amrex::AmrData::compIndexToVisMFComponentMap
protected

◆ compIndexToVisMFMap

Vector<int> amrex::AmrData::compIndexToVisMFMap
protected

◆ coordSys

int amrex::AmrData::coordSys
protected

◆ dataGrids

Vector<Vector<MultiFab *> > amrex::AmrData::dataGrids
protected

◆ dataGridsDefined

Vector<Vector<std::vector<bool> > > amrex::AmrData::dataGridsDefined
protected

◆ defaultFileType

Amrvis::FileType amrex::AmrData::defaultFileType
staticprivate

◆ dxLevel

Vector< Vector<Real> > amrex::AmrData::dxLevel
protected

◆ fabBoxArray

BoxArray amrex::AmrData::fabBoxArray
protected

◆ fileName

std::string amrex::AmrData::fileName
private

◆ fileType

Amrvis::FileType amrex::AmrData::fileType
protected

◆ finestLevel

int amrex::AmrData::finestLevel
protected

◆ gridLocHi

Vector< Vector< Vector<Real> > > amrex::AmrData::gridLocHi
protected

◆ gridLocLo

Vector< Vector< Vector<Real> > > amrex::AmrData::gridLocLo
protected

◆ levelSteps

Vector<int> amrex::AmrData::levelSteps
protected

◆ maxDomain

Vector<Box> amrex::AmrData::maxDomain
protected

◆ nComp

int amrex::AmrData::nComp
protected

◆ nGrow

int amrex::AmrData::nGrow
protected

◆ nRegions

int amrex::AmrData::nRegions
protected

◆ plotFileVersion

std::string amrex::AmrData::plotFileVersion
protected

◆ plotVars

Vector<std::string> amrex::AmrData::plotVars
protected

◆ probDomain

Vector<Box> amrex::AmrData::probDomain
protected

◆ probHi

Vector<Real> amrex::AmrData::probHi
protected

◆ probLo

Vector<Real> amrex::AmrData::probLo
protected

◆ probSize

Vector<Real> amrex::AmrData::probSize
protected

◆ refRatio

Vector<int> amrex::AmrData::refRatio
protected

◆ regions

Vector< Vector< FArrayBox *> > amrex::AmrData::regions
protected

◆ sBoundaryWidth

int amrex::AmrData::sBoundaryWidth = 0
staticprivate

◆ skipPltLines

int amrex::AmrData::skipPltLines = 0
staticprivate

◆ time

Real amrex::AmrData::time
protected

◆ vCartGrid

int amrex::AmrData::vCartGrid
protected

◆ verbose

bool amrex::AmrData::verbose = false
staticprivate

◆ vfEps

Vector<Real> amrex::AmrData::vfEps
protected

◆ visMF

Vector<Vector<VisMF *> > amrex::AmrData::visMF
protected

The documentation for this class was generated from the following files: