AMRLevelCons Class Reference

#include <AMRLevelCons.H>

Inheritance diagram for AMRLevelCons:

Inheritance graph
[legend]

List of all members.


Detailed Description

AMR Level for fourth-order solution to conservation law.

Public Member Functions

 AMRLevelCons ()
 Constructor.
virtual ~AMRLevelCons ()
 Destructor.
virtual void define (AMRLevel *a_coarserLevelPtr, const ProblemDomain &a_problemDomain, int a_level, int a_refRatio)
 Define new AMR level.
virtual Real advance ()
 Advance by one timestep by RK4, and return new timestep.
virtual void addDissipation ()
 add dissipation to m_Unew: Kreiss-Oliger artificial viscosity
virtual void postTimeStep ()
 Things to do after a timestep -- reflux.
virtual void tagCells (IntVectSet &a_tags)
 Create tags for regridding.
virtual void tagCellsInit (IntVectSet &a_tags)
 Create tags at initialization.
virtual void regrid (const Vector< Box > &a_newGrids)
 Set up data on this level after regridding.
virtual void initialGrid (const Vector< Box > &a_newGrids)
 Initialize grids.
virtual void defineDataHolders ()
 Define m_Unew and m_Uold.
virtual void initialData ()
 Initialize data: Set m_Unew at time 0.
virtual void setData (LevelData< FArrayBox > &a_U, Real a_time) const
 Set a_U at time a_time.
virtual void postInitialize ()
 Things to do after initialization.
virtual void writeCheckpointHeader (HDF5Handle &a_handle) const
 Write checkpoint header.
virtual void writeCheckpointLevel (HDF5Handle &a_handle) const
 Write checkpoint data for this level.
virtual void readCheckpointHeader (HDF5Handle &a_handle)
 Read checkpoint header.
virtual void readCheckpointLevel (HDF5Handle &a_handle)
 Read checkpoint data for this level.
virtual void writePlotHeader (HDF5Handle &a_handle) const
 Write plotfile header.
virtual void writePlotLevel (HDF5Handle &a_handle) const
 Write plotfile data for this level.
virtual Real computeDt ()
 Returns the dt computed earlier for this level.
virtual Real computeInitialDt ()
 Compute dt using initial data.
virtual Real getMaxWaveSpeed (const LevelData< FArrayBox > &a_U)
 Return maximum speed from conserved variables.
virtual void CFL (Real a_cfl)
 Set the CFL number.
virtual void spaceOrder (int a_spaceOrder)
 Set the spatial order of accuracy.
virtual void limitFaceValues (bool a_limitFaceValues)
 sets whether to limit face values in operator
virtual void highOrderLimiter (bool a_highOrderLimiter)
virtual void initialAverage (bool a_initialAverage)
 sets whether initial data is average; default false
virtual void useFlattening (bool a_useFlattening)
 sets whether to flatten extrapolations to faces
virtual void useArtVisc (bool a_useArtVisc)
 sets whether to use artificial viscosity
virtual void noPPM (bool a_noPPM)
 sets whether to turn off PPM
virtual void doDeconvolution (bool a_doDeconvolution)
 sets m_doDeconvolution
virtual void doFaceDeconvolution (bool a_doFaceDeconvolution)
 sets m_doFaceDeconvolution
virtual void useArtificialViscosity (bool a_useArtificialViscosity)
 sets whether to use artificial viscosity (from divergence)
virtual void artificialViscosity (Real a_artificialViscosity)
 sets coefficient of artificial viscosity (from divergence)
virtual void ratioArtVisc (Real a_ratioArtVisc)
 sets coefficient of artificial viscosity
virtual void forwardEuler (bool a_forwardEuler)
 sets whether forward Euler is used (instead of RK4)
virtual void enforceMinVal (bool a_enforceMinVal, Real a_minVal)
 sets whether to enforce a min value
virtual void domainLength (Real a_domainLength)
 Set the physical dimension of the longest side of the domain.
virtual void refinementThreshold (Real a_refineThresh)
 Set the refinement threshold.
virtual void refinementIsScaled (bool a_refinementIsScaled)
 Set whether refinement threshold is scaled with dx.
virtual void tagPressure (bool a_tagPressure)
 Set whether to tag on pressure instead of on density.
virtual void tagVorticity (bool a_tagVorticity)
 Set whether to tag on vorticity instead of on density.
void tagBufferSize (int a_tagBufferSize)
 Set the tag buffer size.
void molPhysics (const MOLPhysics *const a_molPhysics)
 Set the MOLPhysics class.
LevelData< FArrayBox > * U ()
 Accessors.
void computeVorticity (LevelData< FArrayBox > &a_vorticity, const LevelData< FArrayBox > &a_U) const

Protected Member Functions

virtual void setDefaultValues ()
DisjointBoxLayout loadBalance (const Vector< Box > &a_grids)
virtual void levelSetup ()
virtual void transferSettingsToLevelOp ()
virtual void transferSettingsFromAMRLevel (AMRLevelCons *a_amrConsPtr)
AMRLevelConsgetCoarserLevel () const
AMRLevelConsgetFinerLevel () const
virtual void advanceU ()
 Advance by one timestep by RK4.
virtual Real computeNewDt ()
 Compute new timestep from m_Unew, and store it in m_dtNew.
virtual Real maxVorticity (LevelData< FArrayBox > &a_vecMag)
 Compute max vorticity of m_Unew, and store their magnitudes in a_vecMag.
virtual int indexForTagging ()
 Index within primitive variables for tagging cells.

Protected Attributes

LevelData< FArrayBoxm_Uold
LevelData< FArrayBoxm_Unew
Real m_r0
Real m_cfl
int m_spaceOrder
bool m_limitFaceValues
bool m_highOrderLimiter
 if true, use high-order limiter
bool m_initialAverage
bool m_useFlattening
bool m_useArtVisc
Real m_ratioArtVisc
bool m_forwardEuler
bool m_enforceMinVal
bool m_noPPM
bool m_doDeconvolution
bool m_doFaceDeconvolution
bool m_useArtificialViscosity
Real m_artificialViscosity
Real m_minVal
Real m_dx
CoarseAveragem_coarseAveragePtr
Real m_dtNew
int m_numStates
Vector< std::string > m_stateNames
int m_numGhost
IntVect m_ghostVect
Real m_domainLength
FourthOrderFineInterp m_fineInterp
LevelConsOperatorm_levelConsOperatorPtr
LevelFluxRegister m_fluxRegister
MOLPhysicsm_molPhysics
Real m_refineThresh
bool m_refinementIsScaled
bool m_tagPressure
bool m_tagVorticity
int m_tagBufferSize
bool m_hasCoarser
bool m_hasFiner
DisjointBoxLayout m_grids

Private Member Functions

void operator= (const AMRLevelCons &a_input)
 AMRLevelCons (const AMRLevelCons &a_input)

Friends

class AMRLevelConsFactory

Constructor & Destructor Documentation

AMRLevelCons::AMRLevelCons (  ) 

Constructor.

virtual AMRLevelCons::~AMRLevelCons (  )  [virtual]

Destructor.

AMRLevelCons::AMRLevelCons ( const AMRLevelCons a_input  )  [private]


Member Function Documentation

virtual void AMRLevelCons::define ( AMRLevel a_coarserLevelPtr,
const ProblemDomain a_problemDomain,
int  a_level,
int  a_refRatio 
) [virtual]

Define new AMR level.

Reimplemented from AMRLevel.

Reimplemented in AMRLevelMappedCons.

virtual Real AMRLevelCons::advance (  )  [virtual]

Advance by one timestep by RK4, and return new timestep.

Implements AMRLevel.

Reimplemented in AMRLevelMappedCons.

virtual void AMRLevelCons::addDissipation (  )  [virtual]

add dissipation to m_Unew: Kreiss-Oliger artificial viscosity

virtual void AMRLevelCons::postTimeStep (  )  [virtual]

Things to do after a timestep -- reflux.

If (!m_hasFiner) then this does nothing except write out some diagnostics depending on the verbosity level.

Implements AMRLevel.

Reimplemented in AMRLevelMappedCons.

virtual void AMRLevelCons::tagCells ( IntVectSet a_tags  )  [virtual]

Create tags for regridding.

Implements AMRLevel.

Reimplemented in AMRLevelMappedCons.

virtual void AMRLevelCons::tagCellsInit ( IntVectSet a_tags  )  [virtual]

Create tags at initialization.

Implements AMRLevel.

Reimplemented in AMRLevelMappedCons.

virtual void AMRLevelCons::regrid ( const Vector< Box > &  a_newGrids  )  [virtual]

Set up data on this level after regridding.

Implements AMRLevel.

Reimplemented in AMRLevelMappedCons.

virtual void AMRLevelCons::initialGrid ( const Vector< Box > &  a_newGrids  )  [virtual]

Initialize grids.

Implements AMRLevel.

Reimplemented in AMRLevelMappedCons.

virtual void AMRLevelCons::defineDataHolders (  )  [virtual]

Define m_Unew and m_Uold.

virtual void AMRLevelCons::initialData (  )  [virtual]

Initialize data: Set m_Unew at time 0.

Implements AMRLevel.

Reimplemented in AMRLevelMappedCons.

virtual void AMRLevelCons::setData ( LevelData< FArrayBox > &  a_U,
Real  a_time 
) const [virtual]

Set a_U at time a_time.

virtual void AMRLevelCons::postInitialize (  )  [virtual]

Things to do after initialization.

Implements AMRLevel.

Reimplemented in AMRLevelMappedCons.

virtual void AMRLevelCons::writeCheckpointHeader ( HDF5Handle a_handle  )  const [virtual]

Write checkpoint header.

Implements AMRLevel.

Reimplemented in AMRLevelMappedCons.

virtual void AMRLevelCons::writeCheckpointLevel ( HDF5Handle a_handle  )  const [virtual]

Write checkpoint data for this level.

Implements AMRLevel.

Reimplemented in AMRLevelMappedCons.

virtual void AMRLevelCons::readCheckpointHeader ( HDF5Handle a_handle  )  [virtual]

Read checkpoint header.

Implements AMRLevel.

Reimplemented in AMRLevelMappedCons.

virtual void AMRLevelCons::readCheckpointLevel ( HDF5Handle a_handle  )  [virtual]

Read checkpoint data for this level.

Implements AMRLevel.

Reimplemented in AMRLevelMappedCons.

virtual void AMRLevelCons::writePlotHeader ( HDF5Handle a_handle  )  const [virtual]

Write plotfile header.

Implements AMRLevel.

Reimplemented in AMRLevelMappedCons.

virtual void AMRLevelCons::writePlotLevel ( HDF5Handle a_handle  )  const [virtual]

Write plotfile data for this level.

Implements AMRLevel.

Reimplemented in AMRLevelMappedCons.

virtual Real AMRLevelCons::computeDt (  )  [virtual]

Returns the dt computed earlier for this level.

Implements AMRLevel.

virtual Real AMRLevelCons::computeInitialDt (  )  [virtual]

Compute dt using initial data.

Implements AMRLevel.

Reimplemented in AMRLevelMappedCons.

virtual Real AMRLevelCons::getMaxWaveSpeed ( const LevelData< FArrayBox > &  a_U  )  [virtual]

Return maximum speed from conserved variables.

Reimplemented in AMRLevelMappedCons.

virtual void AMRLevelCons::CFL ( Real  a_cfl  )  [virtual]

Set the CFL number.

virtual void AMRLevelCons::spaceOrder ( int  a_spaceOrder  )  [virtual]

Set the spatial order of accuracy.

can be 2 or 4 (default)

virtual void AMRLevelCons::limitFaceValues ( bool  a_limitFaceValues  )  [virtual]

sets whether to limit face values in operator

virtual void AMRLevelCons::highOrderLimiter ( bool  a_highOrderLimiter  )  [virtual]

virtual void AMRLevelCons::initialAverage ( bool  a_initialAverage  )  [virtual]

sets whether initial data is average; default false

virtual void AMRLevelCons::useFlattening ( bool  a_useFlattening  )  [virtual]

sets whether to flatten extrapolations to faces

virtual void AMRLevelCons::useArtVisc ( bool  a_useArtVisc  )  [virtual]

sets whether to use artificial viscosity

virtual void AMRLevelCons::noPPM ( bool  a_noPPM  )  [virtual]

sets whether to turn off PPM

virtual void AMRLevelCons::doDeconvolution ( bool  a_doDeconvolution  )  [virtual]

sets m_doDeconvolution

virtual void AMRLevelCons::doFaceDeconvolution ( bool  a_doFaceDeconvolution  )  [virtual]

sets m_doFaceDeconvolution

virtual void AMRLevelCons::useArtificialViscosity ( bool  a_useArtificialViscosity  )  [virtual]

sets whether to use artificial viscosity (from divergence)

virtual void AMRLevelCons::artificialViscosity ( Real  a_artificialViscosity  )  [virtual]

sets coefficient of artificial viscosity (from divergence)

virtual void AMRLevelCons::ratioArtVisc ( Real  a_ratioArtVisc  )  [virtual]

sets coefficient of artificial viscosity

virtual void AMRLevelCons::forwardEuler ( bool  a_forwardEuler  )  [virtual]

sets whether forward Euler is used (instead of RK4)

virtual void AMRLevelCons::enforceMinVal ( bool  a_enforceMinVal,
Real  a_minVal 
) [virtual]

sets whether to enforce a min value

virtual void AMRLevelCons::domainLength ( Real  a_domainLength  )  [virtual]

Set the physical dimension of the longest side of the domain.

virtual void AMRLevelCons::refinementThreshold ( Real  a_refineThresh  )  [virtual]

Set the refinement threshold.

virtual void AMRLevelCons::refinementIsScaled ( bool  a_refinementIsScaled  )  [virtual]

Set whether refinement threshold is scaled with dx.

virtual void AMRLevelCons::tagPressure ( bool  a_tagPressure  )  [virtual]

Set whether to tag on pressure instead of on density.

virtual void AMRLevelCons::tagVorticity ( bool  a_tagVorticity  )  [virtual]

Set whether to tag on vorticity instead of on density.

void AMRLevelCons::tagBufferSize ( int  a_tagBufferSize  ) 

Set the tag buffer size.

void AMRLevelCons::molPhysics ( const MOLPhysics *const   a_molPhysics  ) 

Set the MOLPhysics class.

LevelData<FArrayBox>* AMRLevelCons::U (  )  [inline]

Accessors.

References m_Unew.

void AMRLevelCons::computeVorticity ( LevelData< FArrayBox > &  a_vorticity,
const LevelData< FArrayBox > &  a_U 
) const

virtual void AMRLevelCons::setDefaultValues (  )  [protected, virtual]

Reimplemented in AMRLevelMappedCons.

DisjointBoxLayout AMRLevelCons::loadBalance ( const Vector< Box > &  a_grids  )  [protected]

virtual void AMRLevelCons::levelSetup (  )  [protected, virtual]

Reimplemented in AMRLevelMappedCons.

virtual void AMRLevelCons::transferSettingsToLevelOp (  )  [protected, virtual]

Reimplemented in AMRLevelMappedCons.

virtual void AMRLevelCons::transferSettingsFromAMRLevel ( AMRLevelCons a_amrConsPtr  )  [protected, virtual]

AMRLevelCons* AMRLevelCons::getCoarserLevel (  )  const [protected]

Reimplemented in AMRLevelMappedCons.

AMRLevelCons* AMRLevelCons::getFinerLevel (  )  const [protected]

Reimplemented in AMRLevelMappedCons.

virtual void AMRLevelCons::advanceU (  )  [protected, virtual]

Advance by one timestep by RK4.

Reimplemented in AMRLevelMappedCons.

virtual Real AMRLevelCons::computeNewDt (  )  [protected, virtual]

Compute new timestep from m_Unew, and store it in m_dtNew.

Reimplemented in AMRLevelMappedCons.

virtual Real AMRLevelCons::maxVorticity ( LevelData< FArrayBox > &  a_vecMag  )  [protected, virtual]

Compute max vorticity of m_Unew, and store their magnitudes in a_vecMag.

virtual int AMRLevelCons::indexForTagging (  )  [protected, virtual]

Index within primitive variables for tagging cells.

Reimplemented in AMRLevelMappedCons.

void AMRLevelCons::operator= ( const AMRLevelCons a_input  )  [private]


Friends And Related Function Documentation

friend class AMRLevelConsFactory [friend]


Member Data Documentation

Referenced by U().

Real AMRLevelCons::m_r0 [protected]

int AMRLevelCons::m_spaceOrder [protected]

if true, use high-order limiter

bool AMRLevelCons::m_useArtVisc [protected]

bool AMRLevelCons::m_forwardEuler [protected]

bool AMRLevelCons::m_noPPM [protected]

Real AMRLevelCons::m_dx [protected]

int AMRLevelCons::m_numStates [protected]

Vector<std::string> AMRLevelCons::m_stateNames [protected]

int AMRLevelCons::m_numGhost [protected]

bool AMRLevelCons::m_tagPressure [protected]

bool AMRLevelCons::m_tagVorticity [protected]

bool AMRLevelCons::m_hasCoarser [protected]

bool AMRLevelCons::m_hasFiner [protected]


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

Generated on Mon Dec 11 03:26:52 2017 for Chombo + EB + MF by  doxygen 1.5.5