18 #include "ParmParse.H" 19 #include "NamespaceHeader.H" 23 #define DAMAGE_MAX_VAL 0.9 24 #define DAMAGE_N_GHOST 4 25 #define DAMAGE_N_COMP 1 26 #define WATER_N_GHOST 4 27 #define WATER_N_COMP 1 42 Vector<DisjointBoxLayout> m_grids;
44 Vector<RealVect> m_dx;
49 Vector<LevelData<FluxBox>*> m_faceMinDamage;
56 const LevelData<FArrayBox>*
damage(
int a_level)
const;
58 const LevelData<FArrayBox>*
water(
int a_level)
const;
64 void define(
const Vector<DisjointBoxLayout>& a_grids,
65 const Vector<int>& a_ratio,
67 const RealVect& a_crseDx);
79 void writePlotData(LevelData<FArrayBox>& a_data,
int a_level);
91 void readCheckData(HDF5Handle& a_handle, HDF5HeaderData& a_header,
int a_level,
const DisjointBoxLayout& a_grids);
96 mutable Vector<LevelData<FArrayBox>* >
m_damage;
98 mutable Vector<LevelData<FArrayBox>* >
m_water;
102 void computeDamageSource(Vector<LevelData<FArrayBox>* >& a_source,
103 const Vector<LevelData<FArrayBox>* >& a_damage,
104 const Vector<RefCountedPtr<LevelSigmaCS> >& geometry,
105 const Vector<LevelData<FArrayBox>
const *>& a_visTensor,
106 const Vector<LevelData<FArrayBox>
const * >& a_surfThickSource,
107 const Vector<LevelData<FArrayBox>
const * >& a_baseThickSource,
110 void computeWaterSource(Vector<LevelData<FArrayBox>* >& a_source, Real a_dt,
AmrIce& a_amrIce);
112 void updateWater(Vector<LevelData<FArrayBox>* >& a_water,
113 const Vector<LevelData<FluxBox>* >& a_faceFlux,
114 const Vector<LevelData<FluxBox>* >& a_faceVel,
115 const Vector<LevelData<FArrayBox>* >& a_source,
118 void computeFlux( Vector<LevelData<FluxBox>* >& a_faceFlux,
119 const Vector<LevelData<FArrayBox>* >& a_damage,
120 const Vector<LevelData<FArrayBox>* >& a_source,
121 const Vector<LevelData<FArrayBox>* >& a_cellVel,
122 const Vector<LevelData<FluxBox>* >& a_faceVel,
125 void updateDamage(Vector<LevelData<FArrayBox>* >& a_damage,
126 const Vector<LevelData<FluxBox>* >& a_faceFlux,
127 const Vector<LevelData<FluxBox>* >& a_faceMinDamage,
128 const Vector<LevelData<FluxBox>* >& a_faceVel,
129 const Vector<LevelData<FArrayBox>* >& a_source,
130 const Vector<RefCountedPtr<LevelSigmaCS> >& geometry,
131 const Vector<LevelData<FArrayBox>
const * >& a_vt,
134 void initField(Vector<LevelData<FArrayBox>* >& a_field,
136 const IntVect& a_ghost,
137 bool a_setToScalar =
false,
138 const Real& a_scalar = 1.12345678e+300);
140 void regridField(Vector<LevelData<FArrayBox>* >& a_field);
145 const std::string& a_varLabel,
146 const std::string& a_dataLabel,
147 HDF5Handle& a_handle,
148 HDF5HeaderData& a_header,
149 const DisjointBoxLayout& a_grids);
176 void writePlotData(LevelData<FArrayBox>& a_data,
int a_level);
187 void readCheckData(HDF5Handle& a_handle, HDF5HeaderData& a_header,
int a_level,
const DisjointBoxLayout& a_grids);
202 void define(
const ProblemDomain& a_domain,
210 PhysIBC* new_physIBC();
213 void initialize(LevelData<FArrayBox>& a_U);
216 void primBC(FArrayBox& a_WGdnv,
217 const FArrayBox& a_Wextrap,
218 const FArrayBox& a_W,
220 const Side::LoHiSide& a_side,
229 void setBdrySlopes(FArrayBox& a_dW,
230 const FArrayBox& a_W,
237 void artViscBC(FArrayBox& a_F,
238 const FArrayBox& a_U,
239 const FArrayBox& a_divVel,
253 m_calvingModelPtr(a_calvingModelPtr), m_damageModelPtr(a_damageModelPtr)
261 m_damageModelPtr = a.m_damageModelPtr;
268 virtual void applyCriterion(LevelData<FArrayBox>& a_thickness,
269 LevelData<FArrayBox>& a_calvedIce,
270 LevelData<FArrayBox>& a_addedIce,
271 LevelData<FArrayBox>& a_removedIce,
272 LevelData<FArrayBox>& a_iceFrac,
282 #include "NamespaceFooter.H" void timestep(Real a_dt, AmrIce &a_amrIce)
advance by timestep a_dt. a_dt must satisfy CFL
Definition: AMRDamage.cpp:350
PhysIBC for the damage model.
Definition: AMRDamage.H:193
void readCheckData(HDF5Handle &a_handle, HDF5HeaderData &a_header, int a_level, const DisjointBoxLayout &a_grids)
read level a_level checkpoint data
Definition: AMRDamage.cpp:780
part of Observer-Observee implementation
Definition: AmrIce.H:1418
DamageCalvingModel(const DamageCalvingModel &a)
Definition: AMRDamage.H:258
Continuum damage model.
Definition: AMRDamage.H:30
~AMRDamage()
Definition: AMRDamage.cpp:95
friend class DamageCalvingModel
Definition: AMRDamage.H:34
DamagePhysIBC()
Definition: AMRDamage.H:198
AMRDamage()
Definition: AMRDamage.cpp:123
Vector< LevelData< FArrayBox > *> m_water
Definition: AMRDamage.H:98
class to manage non-subcycled AMR ice-sheet model
Definition: AmrIce.H:40
virtual CalvingModel * new_CalvingModel()=0
factory method
DamageCalvingModel(CalvingModel *a_calvingModelPtr, AMRDamage *a_damageModelPtr)
Definition: AMRDamage.H:252
Contains an AMRDamage, responds to changes in the ice sheet state.
Definition: AMRDamage.H:155
Computes the effective viscosity including a factor due to crevassing.
Definition: DamageConstitutiveRelation.H:29
const LevelData< FArrayBox > * damage(int a_level) const
Definition: AMRDamage.cpp:129
virtual CalvingModel * new_CalvingModel()
factory method
Definition: AMRDamage.H:264
const LevelData< FArrayBox > * water(int a_level) const
Definition: AMRDamage.cpp:150
int finestLevel() const
Definition: AMRDamage.H:60
void writeCheckData(HDF5Handle &a_handle, int a_level)
write level a_level checkpoint data
Definition: AMRDamage.cpp:736
void addPlotVars(Vector< std::string > &a_vars)
add the names of variables to add to the plot file to a_var, in the order they will be written ...
Definition: AMRDamage.cpp:710
void computeFlux(Vector< LevelData< FluxBox > * > &fluxOfIce, const Vector< RefCountedPtr< LevelSigmaCS > > &coords, Vector< LevelData< FArrayBox > * > &topography, Vector< LevelData< FArrayBox > * > &thickness, Vector< LevelData< FArrayBox > * > &surfaceThicknessSource, Vector< LevelData< FArrayBox > * > &basalThicknessSource, Vector< Real > &dx, Vector< int > &ratio, Vector< std::string > &name, Vector< LevelData< FArrayBox > * > &data)
Definition: diagnostics.cpp:211
void writePlotData(LevelData< FArrayBox > &a_data, int a_level)
copy level a_level plot data to LevelData<FArrayBox>& a_data
Definition: AMRDamage.cpp:716
void addCheckVars(Vector< std::string > &a_vars)
fill a_var with the names of variables to add to the checkpoint file
Definition: AMRDamage.cpp:729
Notification
Definition: AmrIce.H:1438
void define(const Vector< DisjointBoxLayout > &a_grids, const Vector< int > &a_ratio, int a_finestLevel, const RealVect &a_crseDx)
Definition: AMRDamage.cpp:281
Stage
Definition: CalvingModel.H:28
virtual base for calving models
Definition: CalvingModel.H:23
Vector< LevelData< FArrayBox > *> m_damage
Definition: AMRDamage.H:96
Definition: AMRDamage.H:245