Inputs
BC
BC::BC
This is the mechanism for impositing boundary conditions on Set::Field
objects of
scalar type.
Typical convention is for [prefix]
to be given by the field name. For instance,
bc.temp.type.xhi = dirichlet dirichlet dirichlet
bc.temp.val.xhi = 0.0 1.0 0.0
corresponds to the boundary condition for temperature. See the specific integrator for details.
API definitions in src/BC/BC.H
Classes
BC::BC
Methods
~BC()
define(const amrex::Geometry &a_geom)
FillBoundary(amrex::BaseFab< T > &in, const amrex::Box &box, int ngrow, int dcomp, int ncomp, amrex::Real time, Orientation face=Orientation::All, const amrex::Mask *mask=nullptr)=0
FillBoundary(amrex::FabArray< amrex::BaseFab< T > > &mf, int dcomp, int ncomp, amrex::Real time, int)
FillBoundary(amrex::FabArray< amrex::BaseFab< T > > &mf, int dcomp, int ncomp, amrex::IntVect const &, amrex::Real time, int bccomp)
operator()(amrex::FabArray< amrex::BaseFab< T > > &mf, int dcomp, int ncomp, amrex::IntVect const &, amrex::Real time, int bccomp)
FillBoundary(amrex::MultiFab &mf, int dcomp, int ncomp, amrex::Real time, int)
operator()(amrex::MultiFab &mf, int dcomp, int ncomp, amrex::IntVect const &, amrex::Real time, int bccomp)
GetBCRec()=0
IsPeriodic()
Periodicity() const
Periodicity(const amrex::Box &b)
Variables
amrex::Geometry BC::BC< T >::m_geom
BC::Constant
src/BC/Constant.cpp src/BC/Constant.H
This is the most commonly used standard boundary condition implementation. The name “Constant” refers to the invariance of the BC value or character along each face of the simulation domain; however, you may cause a change in the value with time by using a Numeric::Interpolator::Linear string.
The BC on each face is specified with a type
string that specifies the nature of
the BC, and a val
that specifies the value.
By default, all types are Dirichlet and all values are 0.0.
The complete list of BC types are below:
Dirichlet boundary condition
types can be specified with Dirichlet
, dirichlet
, EXT_DIR
.
Neumann boundary condition
types are specified with Neumann
, neumann
.
Periodic boundary conditions
can be specified with Periodic
, periodic
, INT_DIR
.
Important: Ensure that your geometry is specified to be periodic using geometry.is_periodic
.
For instance, if periodic in x, set to 1 0 0
The BC values can be specified either as a number (e.g. 1.0
) or using a linear interpolator
string (e.g. (0,1:2.3,-0.1)
).
The number of values and types must be either 0 (for defaults), 1 (to set the same for all field components) or N (where N=number of field components).
Parameter |
Type |
Values |
---|---|---|
BC type on the lower x edge (2d) face (3d) |
dirichlet |
|
BC type on the upper x edge (2d) face (3d) |
dirichlet |
|
BC type on the lower y edge (2d) face (3d) |
dirichlet |
|
BC type on the upper y edge (2d) face (3d) |
dirichlet |
|
BC type on the lower z face (processed but ignored in 2d to prevent unused input errors) |
dirichlet |
|
BC type on the upper z face (processed but ignored in 2d to prevent unused input errors) |
dirichlet |
|
BC value on the lower x edge (2d) face (3d) |
0.0 |
|
BC value on the upper x edge (2d) face (3d) |
0.0 |
|
BC value on the lower y edge (2d) face (3d) |
0.0 |
|
BC value on the upper y edge (2d) face (3d) |
0.0 |
|
BC value on the lower z face (processed but ignored in 2d to prevent unused input errors) |
0.0 |
|
BC value on the upper z face (processed but ignored in 2d to prevent unused input errors) |
0.0 |
API definitions in src/BC/Constant.H
Classes
BC::Constant
Methods
Constant(int a_ncomp)
Constant(int a_ncomp, IO::ParmParse &pp, std::string name)
Constant(int ncomp, amrex::Vector< std::string > bc_hi_str, amrex::Vector< std::string > bc_lo_str, AMREX_D_DECL(amrex::Vector< amrex::Real > _bc_lo_1, amrex::Vector< amrex::Real > _bc_lo_2, amrex::Vector< amrex::Real > _bc_lo_3), AMREX_D_DECL(amrex::Vector< amrex::Real > _bc_hi_1, amrex::Vector< amrex::Real > _bc_hi_2, amrex::Vector< amrex::Real > _bc_hi_3))
~Constant()
FillBoundary(amrex::BaseFab< Set::Scalar > &in, const amrex::Box &box, int ngrow, int dcomp, int ncomp, amrex::Real time, Orientation face=Orientation::All, const amrex::Mask *mask=nullptr) override
GetBCRec() override
IsPeriodic() override
Periodicity() const override
Periodicity(const amrex::Box &b) override
GetBCTypes()
FillBoundary(amrex::BaseFab< T > &in, const amrex::Box &box, int ngrow, int dcomp, int ncomp, amrex::Real time, Orientation face=Orientation::All, const amrex::Mask *mask=nullptr)=0
FillBoundary(amrex::FabArray< amrex::BaseFab< T > > &mf, int dcomp, int ncomp, amrex::Real time, int)
FillBoundary(amrex::FabArray< amrex::BaseFab< T > > &mf, int dcomp, int ncomp, amrex::IntVect const &, amrex::Real time, int bccomp)
FillBoundary(amrex::MultiFab &mf, int dcomp, int ncomp, amrex::Real time, int)
Variables
unsigned int BC::Constant::m_ncomp
std::array<std::vector<int>, m_nfaces> BC::Constant::m_bc_type
std::array<std::vector<Numeric::Interpolator::Linear<Set::Scalar> >, m_nfaces> BC::Constant::m_bc_val
BC::Expression
src/BC/Expression.cpp src/BC/Expression.H
Boundary condition similar to BC::Constant, except that “values” are given as strings which are functions of x,y,z,t.
Parameter |
Type |
Values |
---|---|---|
BC type on the lower x edge (2d) face (3d) |
dirichlet |
|
BC type on the upper x edge (2d) face (3d) |
dirichlet |
|
BC type on the lower y edge (2d) face (3d) |
dirichlet |
|
BC type on the upper y edge (2d) face (3d) |
dirichlet |
|
BC type on the lower z face (processed but ignored in 2d to prevent unused input errors) |
dirichlet |
|
BC type on the upper z face (processed but ignored in 2d to prevent unused input errors) |
dirichlet |
API definitions in src/BC/Expression.H
Classes
BC::Expression
Methods
Expression(int a_ncomp)
Expression(int a_ncomp, IO::ParmParse &pp, std::string name)
~Expression()
FillBoundary(amrex::BaseFab< Set::Scalar > &in, const amrex::Box &box, int ngrow, int dcomp, int ncomp, amrex::Real time, Orientation face=Orientation::All, const amrex::Mask *mask=nullptr) override
GetBCRec() override
IsPeriodic() override
Periodicity() const override
Periodicity(const amrex::Box &b) override
GetBCTypes()
FillBoundary(amrex::BaseFab< T > &in, const amrex::Box &box, int ngrow, int dcomp, int ncomp, amrex::Real time, Orientation face=Orientation::All, const amrex::Mask *mask=nullptr)=0
FillBoundary(amrex::FabArray< amrex::BaseFab< T > > &mf, int dcomp, int ncomp, amrex::Real time, int)
FillBoundary(amrex::FabArray< amrex::BaseFab< T > > &mf, int dcomp, int ncomp, amrex::IntVect const &, amrex::Real time, int bccomp)
FillBoundary(amrex::MultiFab &mf, int dcomp, int ncomp, amrex::Real time, int)
Variables
unsigned int BC::Expression::m_ncomp
std::array<std::vector<int>, m_nfaces> BC::Expression::m_bc_type
std::array<std::vector<amrex::Parser>, m_nfaces> BC::Expression::m_bc_func_parser
std::array<std::vector<amrex::ParserExecutor<4> >, m_nfaces> BC::Expression::m_bc_func
BC::Nothing
Empty BC class, used when specifying boundaries that have no ghost cells/nodes but a BC object is still required.
API definitions in src/BC/Nothing.H
Classes
BC::Nothing
Methods
Nothing()
FillBoundary(amrex::BaseFab< Set::Scalar > &, const amrex::Box &, int, int, int, amrex::Real, Orientation=Orientation::All, const amrex::Mask *=nullptr) override
GetBCRec() override
BC::Operator
BC::Operator::Operator
The BC::Operator
family of BC classes are designed to work with implicit
operators.
They are not the same thing as other BC types and cannot be used in that same
way.
(This is not an ideal taxonomy for BC structures - we may transition other BC types
to be subspaces of BC::Integrator.)
API definitions in src/BC/Operator/Operator.H
Classes
BC::Operator::Elastic
BC::Operator::Elastic::Elastic
src/BC/Operator/Elastic/Elastic.H
Class of BC operators that work with Operator::Elastic.
API definitions in src/BC/Operator/Elastic/Elastic.H
Classes
BC::Operator::Elastic::Elastic
Methods
~Elastic()=default
SetTime(const Set::Scalar a_time)
Init(amrex::MultiFab *a_rhs, const amrex::Geometry &a_geom, bool a_homogeneous=false) const =0
Init(amrex::FabArray< amrex::BaseFab< Set::Vector > > *a_rhs, const amrex::Geometry &a_geom, bool a_homogeneous=false) const =0
Init(Set::Field< Set::Scalar > &a_rhs, const amrex::Vector< amrex::Geometry > &a_geom, bool a_homogeneous=false) const
Init(Set::Field< Set::Vector > &a_rhs, const amrex::Vector< amrex::Geometry > &a_geom, bool a_homogeneous=false) const
getType(const int &i, const int &j, const int &k, const amrex::Box &domain)=0
operator()(const Set::Vector &u, const Set::Matrix &gradu, const Set::Matrix &sigma, const int &i, const int &j, const int &k, const amrex::Box &domain)=0
Variables
Set::Scalar BC::Operator::Elastic::Elastic::m_time
BC::Operator::Elastic::Constant
src/BC/Operator/Elastic/Constant.H
This BC defines boundary conditions that are constant with respect to space. However they may change in time using the Numeric::Interpolator::Linear method.
In 2D, BCs are prescribed for each edge (4) and corner (4) on the boundary, for a total of 8 possible regions. In 3D, BCs are prescribed for each face (6), each edge (12), and each corner (8), for a total of 26 possible regions. Care must be taken to define BCs for edges/corners consistently with the faces/edges, or you will get poor convergence and inaccurate behavior. (See BC::Operator::Elastic::TensionTest for a reduced BC with streamlined load options.)
To define a boundary condition, you must define both a “type” and a “value” in each direction. The type can be “displacement”, “disp”, “neumann”, “traction”, “trac”. The value is the corresponding value. All BCs are, by default, dirichlet (displacement) with a value of zero.
Parameter |
Type |
Values |
---|---|---|
3D Corner |
||
3D Corner |
||
3D Corner |
||
3D Corner |
||
3D Corner |
||
3D Corner |
||
3D Corner |
||
3D Corner |
||
3D Edge |
||
3D Edge |
||
3D Edge |
||
3D Edge |
||
3D Edge |
||
3D Edge |
||
3D Edge |
||
3D Edge |
||
3D Edge / 2D Corner |
||
3D Edge / 2D Corner |
||
3D Edge / 2D Corner |
||
3D Edge / 2D Corner |
||
3D Face / 2D Edge |
||
3D Face / 2D Edge |
||
3D Face / 2D Edge |
||
3D Face / 2D Edge |
||
3D Face |
||
3D Face |
||
3D Corner |
||
3D Corner |
||
3D Corner |
||
3D Corner |
||
3D Corner |
||
3D Corner |
||
3D Corner |
||
3D Corner |
||
3D Edge |
||
3D Edge |
||
3D Edge |
||
3D Edge |
||
3D Edge |
||
3D Edge |
||
3D Edge |
||
3D Edge |
||
3D Edge / 2D Corner |
||
3D Edge / 2D Corner |
||
3D Edge / 2D Corner |
||
3D Edge / 2D Corner |
||
3D Face / 2D Edge |
||
3D Face / 2D Edge |
||
3D Face / 2D Edge |
||
3D Face / 2D Edge |
||
3D Face |
||
3D Face |
API definitions in src/BC/Operator/Elastic/Constant.H
Classes
BC::Operator::Elastic::Constant
Methods
Constant()
Constant(IO::ParmParse &pp, std::string name)
~Constant()
Set(const Face face, const Direction direction, const Type type, const Set::Scalar value)
Set(const Face, const Direction, const Type, const Set::Scalar, amrex::Vector< amrex::MultiFab * > &, const amrex::Vector< amrex::Geometry > &)
Set(const Face face, const Direction direction, const Type type, const Set::Scalar value, amrex::Vector< amrex::MultiFab > &a_rhs, const amrex::Vector< amrex::Geometry > &a_geom)
Set(const Face face, const Direction direction, const Type type, const Set::Scalar value, amrex::Vector< std::unique_ptr< amrex::MultiFab > > &a_rhs, const amrex::Vector< amrex::Geometry > &a_geom)
Init(amrex::FabArray< amrex::BaseFab< Set::Vector > > *a_rhs, const amrex::Geometry &a_geom, bool a_homogeneous=false) const
Init(amrex::MultiFab *a_rhs, const amrex::Geometry &a_geom, bool a_homogeneous=false) const
getType(const int &i, const int &j, const int &k, const amrex::Box &domain)
operator()(const Set::Vector &u, const Set::Matrix &gradu, const Set::Matrix &sigma, const int &i, const int &j, const int &k, const amrex::Box &domain)
set(std::array< Type, AMREX_SPACEDIM > &bc_type, const Set::Vector &u, const Set::Matrix &gradu, const Set::Matrix &sigma, Set::Vector n) const
Init(amrex::MultiFab *a_rhs, const amrex::Geometry &a_geom, bool a_homogeneous=false) const=0
Init(amrex::FabArray< amrex::BaseFab< Set::Vector > > *a_rhs, const amrex::Geometry &a_geom, bool a_homogeneous=false) const=0
Init(Set::Field< Set::Scalar > &a_rhs, const amrex::Vector< amrex::Geometry > &a_geom, bool a_homogeneous=false) const
Init(Set::Field< Set::Vector > &a_rhs, const amrex::Vector< amrex::Geometry > &a_geom, bool a_homogeneous=false) const
Variables
std::array<std::array<Type, AMREX_SPACEDIM>, m_nfaces> BC::Operator::Elastic::Constant::m_bc_type
std::array<std::array<Numeric::Interpolator::Linear<Set::Scalar>,AMREX_SPACEDIM>, m_nfaces> BC::Operator::Elastic::Constant::m_bc_val
BC::Operator::Elastic::Expression
src/BC/Operator/Elastic/Expression.H
Use expressions to define space and time varying boundary conditions for elastic problems.
API definitions in src/BC/Operator/Elastic/Expression.H
Classes
BC::Operator::Elastic::Expression
Methods
Expression()
~Expression()
Init(amrex::FabArray< amrex::BaseFab< Set::Vector > > *a_rhs, const amrex::Geometry &a_geom, bool a_homogeneous=false) const override
Init(amrex::MultiFab *a_rhs, const amrex::Geometry &a_geom, bool a_homogeneous=false) const override
getType(const int &i, const int &j, const int &k, const amrex::Box &domain) override
operator()(const Set::Vector &u, const Set::Matrix &gradu, const Set::Matrix &sigma, const int &i, const int &j, const int &k, const amrex::Box &domain) override
set(std::array< Type, AMREX_SPACEDIM > &bc_type, const Set::Vector &u, const Set::Matrix &gradu, const Set::Matrix &sigma, Set::Vector n) const
Expression(IO::ParmParse &pp, std::string name)
Init(amrex::MultiFab *a_rhs, const amrex::Geometry &a_geom, bool a_homogeneous=false) const=0
Init(amrex::FabArray< amrex::BaseFab< Set::Vector > > *a_rhs, const amrex::Geometry &a_geom, bool a_homogeneous=false) const=0
Init(Set::Field< Set::Scalar > &a_rhs, const amrex::Vector< amrex::Geometry > &a_geom, bool a_homogeneous=false) const
Init(Set::Field< Set::Vector > &a_rhs, const amrex::Vector< amrex::Geometry > &a_geom, bool a_homogeneous=false) const
Variables
std::array<std::array<Type, AMREX_SPACEDIM>, m_nfaces> BC::Operator::Elastic::Expression::m_bc_type
std::array<std::array<amrex::Parser,AMREX_SPACEDIM>, m_nfaces> BC::Operator::Elastic::Expression::m_bc_func_parser
std::array<std::array<amrex::ParserExecutor<4>,AMREX_SPACEDIM>, m_nfaces> BC::Operator::Elastic::Expression::m_bc_func
BC::Operator::Elastic::TensionTest
src/BC/Operator/Elastic/TensionTest.H
A boundary condition for mechanics operators that simplifies frequently-used conditions for uniaxial loading.
Types include:
uniaxial_stress_clamp
: fixes both ends and allows for stress concentrations at the corners.uniaxial_kolsky
uniaxial_stress
: 1D stress problemuniaxial_strain
: 1D strain problem
Parameter |
Type |
Values |
---|---|---|
Tension test type. |
uniaxial_stress_clamp uniaxial_kolsky uniaxial_stress uniaxial_strain |
|
Applied displacement (can be interpolator) |
||
Applied traction (can be interpolator) |
API definitions in src/BC/Operator/Elastic/TensionTest.H
Classes
BC::Operator::Elastic::TensionTest
Methods
TensionTest()
TensionTest(IO::ParmParse &pp, std::string name)
~TensionTest()
Init(amrex::FabArray< amrex::BaseFab< Set::Vector > > *a_rhs, const amrex::Geometry &a_geom, bool a_homogeneous=false) const
Init(amrex::MultiFab *a_rhs, const amrex::Geometry &a_geom, bool a_homogeneous=false) const
Init(amrex::MultiFab *a_rhs, const amrex::Geometry &a_geom, bool a_homogeneous=false) const =0
Init(amrex::FabArray< amrex::BaseFab< Set::Vector > > *a_rhs, const amrex::Geometry &a_geom, bool a_homogeneous=false) const =0
Init(Set::Field< Set::Scalar > &a_rhs, const amrex::Vector< amrex::Geometry > &a_geom, bool a_homogeneous=false) const
Init(Set::Field< Set::Vector > &a_rhs, const amrex::Vector< amrex::Geometry > &a_geom, bool a_homogeneous=false) const
set(std::array< Type, AMREX_SPACEDIM > &bc_type, const Set::Vector &u, const Set::Matrix &gradu, const Set::Matrix &sigma, Set::Vector n) const
IC
IC::IC
Initial condition (IC) objects are used to set fields to specified values, through mathematical expressions, images, etc. They are often used as initial conditions, but may be used generally to incorporate static or time-dependent values. All IC methods inherit from the base IC class, and are implemented by overriding the “Add” method. (Initialize uses Add after setting the field to zero.)
API definitions in src/IC/IC.H
Classes
IC::IC
- Pure abstract object from which all other objects inherit.Methods
IC(amrex::Vector< amrex::Geometry > &_geom)
~IC()
Add(const int &lev, Set::Field< T > &field, Set::Scalar time)=0
Add(const int &lev, Set::Field< T > &field)
Initialize(const int &a_lev, Set::Field< T > &a_field, Set::Scalar a_time=0.0)
Initialize(const int &a_lev, Set::Field< T > &a_field, Set::Scalar a_time=0.0)
SetComp(int a_comp) final
Variables
amrex::Vector<amrex::Geometry>& IC::IC< T >::geom
int IC::IC< T >::comp
IC::BMP
Initialize a field using a bitmap image. (2D only)
Note that in GIMP, you must select “do not write color space information” and “24 bit R8 G8 B8” when exporting the BMP file.
Parameter |
Type |
Values |
---|---|---|
BMP filename. |
file path |
|
How to position image in space |
stretch fitheight fitwidth coord |
|
Location of lower-left corner in the domain |
||
Location of upper-right corner in the domain |
||
Color channel to use |
r g b R G B |
|
Scaling value - minimum |
0.0 |
|
Scaling value - maximum |
255.0 |
API definitions in src/IC/BMP.H
Classes
IC::BMP
Methods
BMP(amrex::Vector< amrex::Geometry > &_geom)
BMP(amrex::Vector< amrex::Geometry > &_geom, IO::ParmParse &pp, std::string name)
Define(std::string bmpfilename)
Add(const int &lev, Set::Field< Set::Scalar > &a_field, Set::Scalar)
Variables
Util::BMP IC::BMP::bmp
Fit IC::BMP::fit
Channel IC::BMP::channel
Set::Scalar IC::BMP::min
Set::Scalar IC::BMP::max
Set::Vector IC::BMP::coord_lo
Set::Vector IC::BMP::coord_hi
IC::Constant
Basic IC that just sets the entire field to a constant value. Works with a single or multiple-component field.
Parameter |
Type |
Values |
---|---|---|
Array of constant values. The number of values should equal either 1 or N where N is the number of fab components |
required |
API definitions in src/IC/Constant.H
Classes
IC::Constant
Methods
~Constant()=default
Constant(amrex::Vector< amrex::Geometry > &_geom)
Constant(amrex::Vector< amrex::Geometry > &_geom, IO::ParmParse &pp)
Constant(amrex::Vector< amrex::Geometry > &_geom, IO::ParmParse &pp, std::string name)
Add(const int &lev, Set::Field< Set::Scalar > &a_field, Set::Scalar) override
Add(const int &lev, Set::Field< Set::Vector > &a_field, Set::Scalar) override
Variables
std::vector<Set::Scalar> IC::Constant::m_value
IC::Ellipse
If number_of_inclusions
is specified, then multiple ellipses are specified.
In this case, each parameter must have number_of_inclusion*M values, where M is the
number of values specified for the single ellipse case.
Parameter |
Type |
Values |
---|---|---|
Coorinates of ellipse center |
||
Diffuse boundary thickness |
0.0 |
|
DxD square matrix defining an ellipse. |
||
If |
||
Number of ellipses |
||
center of the ellipse |
||
center of the ellipse |
||
either a vector containing ellipse radii, or a matrix defining the ellipse |
||
Same |
||
Array of radii [depricated] |
||
Regularization for smooth boundary |
||
Flip the inside and the outside |
API definitions in src/IC/Ellipse.H
Classes
IC::Ellipse
Methods
Ellipse(amrex::Vector< amrex::Geometry > &_geom)
Ellipse(amrex::Vector< amrex::Geometry > &_geom, IO::ParmParse &pp, std::string name)
Add(const int &lev, Set::Field< Set::Scalar > &a_field, Set::Scalar)
Variables
int IC::Ellipse::number_of_inclusions
amrex::Vector<Set::Vector> IC::Ellipse::center
amrex::Vector<Set::Matrix> IC::Ellipse::A
amrex::Vector<Set::Scalar> IC::Ellipse::eps
int IC::Ellipse::invert
IC::Expression
Initialize a field using a mathematical expression. Expressions are imported as strings and are compiled real-time using the AMReX Parser.
Works for single or multiple-component fields.
Use the regionN
(N=0,1,2, etc. up to number of components) to pass expression.
For example:
ic.region0 = "sin(x*y*z)"
ic.region1 = "3.0*(x > 0.5 and y > 0.5)"
for a two-component field. It is up to you to make sure your expressions are parsed correctly; otherwise you will get undefined behavior.
Constants
You can add constants to your expressions using the constant
directive.
For instance, in the following code
psi.ic.type=expression
psi.ic.expression.constant.eps = 0.05
psi.ic.expression.constant.R = 0.25
psi.ic.expression.region0 = "0.5 + 0.5*tanh((x^2 + y^2 - R)/eps)"
the constants eps
and R
are defined by the user and then used
in the subsequent expression.
The variables can have any name made up of characters that is not reserved.
However, if multiple ICs are used, they must be defined each time for each IC.
Parameter |
Type |
Values |
---|---|---|
coordinate system to use |
cartesian polar |
API definitions in src/IC/Expression.H
Classes
IC::Expression
Methods
Expression(amrex::Vector< amrex::Geometry > &_geom)
Expression(amrex::Vector< amrex::Geometry > &_geom, IO::ParmParse &pp, std::string name)
Add(const int &lev, Set::Field< Set::Scalar > &a_field, Set::Scalar a_time=0.0) override
Add(const int &lev, Set::Field< Set::Vector > &a_field, Set::Scalar a_time=0.0) override
Variables
std::vector<amrex::Parser> IC::Expression::parser
std::vector<amrex::ParserExecutor<4> > IC::Expression::f
Expression::CoordSys IC::Expression::coord
IC::Laminate
Create a single laminate with specified orientation, thickness, and offset.
Parameter |
Type |
Values |
---|---|---|
How many laminates (MUST be greater than or equal to 1). |
1 |
|
Vector normal to the interface of the laminate |
||
Diffuse thickness |
||
Type of mollifer to use (options: dirac, [gaussian]) |
||
Switch to mode where only one component is used. |
||
Take the complement of the laminate |
API definitions in src/IC/Laminate.H
Classes
IC::Laminate
- Initialize Laminates in a matrix.Methods
Laminate(amrex::Vector< amrex::Geometry > &_geom)
Laminate(amrex::Vector< amrex::Geometry > &_geom, IO::ParmParse &pp, std::string name)
Add(const int &lev, Set::Field< Set::Scalar > &a_field, Set::Scalar)
Variables
int IC::Laminate::number_of_inclusions
amrex::Vector<Set::Vector> IC::Laminate::center
amrex::Vector<Set::Vector> IC::Laminate::orientation
amrex::Vector<Set::Vector> IC::Laminate::normal
amrex::Vector<Set::Scalar> IC::Laminate::eps
amrex::Vector<Set::Scalar> IC::Laminate::thickness
Mollifier IC::Laminate::moll
bool IC::Laminate::singlefab
bool IC::Laminate::invert
IC::PSRead
Fill a domain (region where field=0) with packed spheres (regions where field=1). Sphere locations and radii are determined from an xyzr file.
Parameter |
Type |
Values |
---|---|---|
Diffuseness of the sphere boundary |
||
Location of .xyzr file |
file path |
|
Verbosity (used in parser only) |
||
Coordinate multiplier |
||
Coordinate multiplier |
||
Coordinate offset |
API definitions in src/IC/PSRead.H
Classes
IC::PSRead
Methods
PSRead(amrex::Vector< amrex::Geometry > &_geom)
PSRead(amrex::Vector< amrex::Geometry > &_geom, IO::ParmParse &pp, std::string name)
Define()
Add(const int &lev, Set::Field< Set::Scalar > &a_phi, Set::Scalar)
Variables
std::vector<Set::Vector> IC::PSRead::X
std::vector<Set::Scalar> IC::PSRead::R
Set::Scalar IC::PSRead::eps
Set::Scalar IC::PSRead::mult
Set::Vector IC::PSRead::x0
bool IC::PSRead::invert
IC::PerturbedInterface
Initialize a perturbed interface using Fourier Modes
Notes: 1. todo Extend this class to allow for 3D perturbations, currently only 2D are allowed 2. todo Allow for cosine (or complex exponential) expansions rather than just sin. 3. note This is a two grain only initial condition. 4. note This replaces the depricated “perturbed_bar” initial condition from previous versions
The interface is defined as the \(x=0\) plane (2D), or the \(x=0,z=0\) plane (3D). The equation for the interface is given by \(y(x,z) = \sum_{n\in \{n_1,\ldots,n_N\}} A_n \sin(n\pi x/L_x)\) where \(A_n\) are the amplitudes (stored in #wave_amplitudes), \(n_1,\ldots,n_N\subset\mathbb{Z}_+\) are wave numbers (stored in #wave_numbers), and \(L_x\) is the length in the x direction (obtained using the #geom object).
Grain 1 is defined as being above \(y(x,z)\), Grain 2 is defined as being below.
Parameter |
Type |
Values |
---|---|---|
Wave numbers |
||
Wave amplitudes |
||
Which axis is normal to the interface (x,y,z) |
||
Interface offset from origin |
||
If true, flip the interface (default:false) |
||
Mollifier (options: dirac, [gaussian]) |
||
Magnitude of mollifier |
API definitions in src/IC/PerturbedInterface.H
Classes
IC::PerturbedInterface
Methods
PerturbedInterface(amrex::Vector< amrex::Geometry > &_geom)
PerturbedInterface(amrex::Vector< amrex::Geometry > &_geom, IO::ParmParse &pp, std::string name)
PerturbedInterface(amrex::Vector< amrex::Geometry > &_geom, IO::ParmParse &pp)
Add(const int &lev, Set::Field< Set::Scalar > &a_field, Set::Scalar)
Variables
Direction IC::PerturbedInterface::normal
Set::Scalar IC::PerturbedInterface::offset
amrex::Vector<std::complex<int> > IC::PerturbedInterface::wave_numbers
- Store mode amplitudes .amrex::Vector<Set::Scalar> IC::PerturbedInterface::wave_amplitudes
std::vector<Set::Scalar> IC::PerturbedInterface::phis
Mollifier IC::PerturbedInterface::mol
Set::Scalar IC::PerturbedInterface::eps
int IC::PerturbedInterface::reverse
IC::PNG
Initialize a field using a PNG image. (2D only)
Parameter |
Type |
Values |
---|---|---|
Color channel to use (options: r, R, g, G, b, B, a, A) |
r g b a R G B A |
API definitions in src/IC/PNG.H
Classes
IC::PNG
Methods
~PNG()
PNG(amrex::Vector< amrex::Geometry > &_geom)
PNG(amrex::Vector< amrex::Geometry > &_geom, IO::ParmParse &pp, std::string name)
Add(const int &lev, Set::Field< Set::Scalar > &a_field, Set::Scalar)
Variables
Util::PNG IC::PNG::png
Channel IC::PNG::channel
IC::Random
Set each point in the field to a random value between 0 and 1
Parameter |
Type |
Values |
---|---|---|
offset from the [0,1] random number range |
0.0 |
|
multiplier for the [0,1] random number range |
1.0 |
API definitions in src/IC/Random.H
Classes
IC::Random
- each point to a random value.Methods
Random(amrex::Vector< amrex::Geometry > &_geom, Set::Scalar a_mult)
Random(amrex::Vector< amrex::Geometry > &_geom, IO::ParmParse &pp, std::string name)
Add(const int &lev, Set::Field< Set::Scalar > &a_field, Set::Scalar)
Add(const int &lev, Set::Field< T > &field, Set::Scalar time)=0
Add(const int &lev, Set::Field< T > &field)
Variables
Set::Scalar IC::Random::mult
Set::Scalar IC::Random::offset
IC::Sphere
Initialize a sphere region in which the field (eta=1). Can be a 3D sphere (xyz) or oriented around any of the three axes.
This functionality is replaced by IC::Expression.
Parameter |
Type |
Values |
---|---|---|
Radius of the sphere |
1.0 |
|
Vector location of the sphere center |
||
Value of the field inside the sphere |
1.0 |
|
Value of the field outside teh sphere |
0.0 |
|
Type - can be cylinder oriented along the x, y, z directions or full sphere. |
xyz yz zx xy |
API definitions in src/IC/Sphere.H
Classes
IC::Sphere
Methods
Sphere(amrex::Vector< amrex::Geometry > &_geom)
Sphere(amrex::Vector< amrex::Geometry > &_geom, IO::ParmParse &pp)
Sphere(amrex::Vector< amrex::Geometry > &_geom, IO::ParmParse &pp, std::string name)
Sphere(amrex::Vector< amrex::Geometry > &_geom, Set::Scalar _radius, Set::Vector _center, Type _type=Type::XYZ, Set::Scalar _alpha_in=1, Set::Scalar _alpha_out=0)
- Constructor defining radius, center, dimension/orientation, and field values within and outside of the area.Define(Set::Scalar a_radius, Set::Vector a_center, Type a_type, Set::Scalar a_alpha_in, Set::Scalar a_alpha_out)
Add(const int &lev, Set::Field< Set::Scalar > &a_field, Set::Scalar)
Variables
Set::Vector IC::Sphere::center
Set::Scalar IC::Sphere::radius
Set::Scalar IC::Sphere::alpha_in
Set::Scalar IC::Sphere::alpha_out
Type IC::Sphere::type
IC::Trig
This is an old-fashioned IC. It is kept because it is still used with the Trig regression test, but it is recommended to use IC::Expression instead.
Parameter |
Type |
Values |
---|---|---|
Number of real (cosin) waves |
||
Number of imaginary (sin) waves |
||
Spatial dimension |
||
Multiplier |
API definitions in src/IC/Trig.H
Classes
IC::Trig
- Initialize using a trigonometric series.Methods
Trig(amrex::Vector< amrex::Geometry > &_geom, Set::Scalar _alpha=1.0, AMREX_D_DECL(std::complex< int > _n1=0, std::complex< int > _n2=0, std::complex< int > _n3=0), int _dim=AMREX_SPACEDIM)
Trig(amrex::Vector< amrex::Geometry > &_geom, IO::ParmParse &pp, std::string name)
Define(Set::Scalar _alpha=1.0, AMREX_D_DECL(std::complex< int > _n1=0, std::complex< int > _n2=0, std::complex< int > _n3=0), int _dim=AMREX_SPACEDIM)
Add(const int &lev, Set::Field< Set::Scalar > &a_field, Set::Scalar) override
Add(const int &lev, Set::Field< Set::Vector > &a_field, Set::Scalar) override
AMREX_D_DECL(n1, n2, n3)
AMREX_D_DECL(phi1=0.0, phi2=0.0, phi3=0.0)
Variables
int IC::Trig::dim
Set::Scalar IC::Trig::alpha
IC::TabulatedInterface
Initialize a 2D interface in a 2 component field defind by (x,y) which are an array of points along the interface.
Parameter |
Type |
Values |
---|---|---|
x location of points |
||
y location of points |
API definitions in src/IC/TabulatedInterface.H
Classes
IC::TabulatedInterface
- Initialize a perturbed interface using a linear interpolation.Methods
TabulatedInterface(amrex::Vector< amrex::Geometry > &_geom)
TabulatedInterface(amrex::Vector< amrex::Geometry > &_geom, IO::ParmParse &pp)
TabulatedInterface(amrex::Vector< amrex::Geometry > &_geom, IO::ParmParse &pp, std::string name)
TabulatedInterface(amrex::Vector< amrex::Geometry > &_geom, std::vector< Set::Scalar > a_xs, std::vector< Set::Scalar > a_ys)
TabulatedInterface(amrex::Vector< amrex::Geometry > &_geom, std::vector< Set::Scalar > a_xs, std::vector< Set::Scalar > a_ys, Set::Scalar a_alpha1, Set::Scalar a_alpha2, Type a_type=Type::Values)
Define(std::vector< Set::Scalar > a_xs, std::vector< Set::Scalar > a_ys, Type a_type=Type::Partition, Set::Scalar a_alpha1=1.0, Set::Scalar a_alpha2=1.0)
Add(const int &lev, Set::Field< Set::Scalar > &a_field, Set::Scalar) override
Variables
Type IC::TabulatedInterface::type
std::vector<Set::Scalar> IC::TabulatedInterface::xs
std::vector<Set::Scalar> IC::TabulatedInterface::ys
Set::Scalar IC::TabulatedInterface::alpha1
Set::Scalar IC::TabulatedInterface::alpha2
IC::Trig2
This is an old IC that exist only to support some of the old operator tests. IC::Expression should be used instead. .. dropdown:: API definitions in src/IC/Trig2.H
Classes
IC::Trig2
- Initialize using a trigonometric series.Methods
Trig2(amrex::Vector< amrex::Geometry > &_geom, Set::Scalar _alpha=1.0, AMREX_D_DECL(Set::Scalar _theta1=0, Set::Scalar _theta2=0, Set::Scalar _theta3=0), AMREX_D_DECL(int _n1=0, int _n2=0, int _n3=0), int _dim=AMREX_SPACEDIM)
Define(Set::Scalar _alpha=1.0, AMREX_D_DECL(Set::Scalar _theta1=0, Set::Scalar _theta2=0, Set::Scalar _theta3=0), AMREX_D_DECL(int _n1=0, int _n2=0, int _n3=0), int _dim=AMREX_SPACEDIM)
Add(const int &lev, Set::Field< Set::Scalar > &field, Set::Scalar)
AMREX_D_DECL(n1, n2, n3)
AMREX_D_DECL(theta1, theta2, theta3)
Variables
int IC::Trig2::dim
Set::Scalar IC::Trig2::alpha
IC::Voronoi
Initialize an N component field with a Voronoi tessellation.
(Mostly used by Integrator::PhaseFieldMicrostructure
).
Parameter |
Type |
Values |
---|---|---|
Number of grains |
||
Value to take in the region [1.0] |
||
Random seed to use |
API definitions in src/IC/Voronoi.H
Classes
IC::Voronoi
Methods
Voronoi(amrex::Vector< amrex::Geometry > &_geom)
Voronoi(amrex::Vector< amrex::Geometry > &_geom, IO::ParmParse &pp, std::string name)
Voronoi(amrex::Vector< amrex::Geometry > &_geom, int _number_of_grains, Set::Scalar a_alpha)
Voronoi(amrex::Vector< amrex::Geometry > &a_geom, int a_number_of_grains)
Define(int a_number_of_grains, Set::Scalar a_alpha)
Define(int a_number_of_grains, std::vector< Set::Scalar > a_alpha, Type a_type=Type::Values)
Add(const int &lev, Set::Field< Set::Scalar > &a_field, Set::Scalar)
Variables
int IC::Voronoi::number_of_grains
int IC::Voronoi::seed
std::vector<Set::Scalar> IC::Voronoi::alpha
std::vector<Set::Vector> IC::Voronoi::voronoi
Type IC::Voronoi::type
IO
IO::FileNameParse
src/IO/FileNameParse.cpp src/IO/FileNameParse.H
This manages the processing of the plot_file
input, which defines the output file.
Both variable substitution and time wildcards are supported.
Variable substitution: you can use braces to substitute variable names in the input file.
For example, if your input file contains myinput.value = 3
, then you can specify
plot_file = output_{myinput.value}
to substitute the input’s value.
Time and dimension wildcards: You can use the following strings:
%Y
: 4-digit year%m
: 2-digit month (01-12)%d
: 2-digit day (00-31)%H
: 2 digit hour (00-23)%M
: 2 digit minute (00-59)%S
: 2 digit second (00-59)%f
: 2 digit microsecond (00-59)%D
: spatial dimension
So a plot_file = output_%Y%m%d_%H%M%S
may resolve to
output_20250307_211201
(etc) depending on the time the
output was created.
.. dropdown:: API definitions in src/IO/FileNameParse.H
Classes
IO::ParmParse
src/IO/ParmParse.cpp src/IO/ParmParse.H
This is a thin wrapper to the amrex::ParmParse class This class exists to add some additional parsing capability, e.g. parsing Set::Matrix and Set::Vector data types.
IO::ParmParse uses static Parse()
functions to
perform cascading class-based input parsing.
See the Autodoc and Autotest section for instructions on adding documentation.
This is standard infrastructure code; make sure you know what you ard doing before you change it.
Query directives
Alamo uses different query directives to standardize reading inputs and automatic documentation.
The type of query that is used (query vs query_required, etc) triggers different handlers and different
automatic documentation procedures.
For instance, the use of a query_default
causes a default value to be set and added to the metadata
file, and it also serves as a flag for the autodoc system to document that a default value is available.
The following table is a reference for the different kinds of query directives.
BC Type |
Description |
---|---|
query |
Standard IO for bool, string, Set::Scalarthat does not enforce defaults or required values. Not recommended for general use. |
query_required |
Similar to query, but will abort if no value is specified. Required values are indicated by required. |
query_default |
Similar to query, but will fill with default value if no value is provided. Will also add default value to metadata. Default values are indicated by green badge values, e.g. 0.0. |
query_validate |
For strings, read in a value and enforce that the value is one of a supplied number of values. Optionally make required, or set the default value to the first supplied value. Acceptable options are indicated by blue badge values, e.g. 1.0, 2.0. If a default value is available, it is indicated by a green badge, e.g. 1.0. |
query_file |
Read in a string that defines a file name. Check to make sure that the file exists and is a regular file, and print an informative error message if not (this can be disabled). Also, copy the file to the output directory, with the full path preserved by replacing / with _. (This can also be disabled, but doing so is discouraged.) Default values are not allowed. File paths are indicated by file path. |
queryarr |
Read in an array of numbers into either a standard vector or
into a |
queryclass |
Read a class object with a specified prefix.
How that class is read in is determined by its |
Query macros
A set of preprocessor macros are defined so that you can call a query function using pp_
instead
of pp.
.
For instance, the following two can be used interchangeably:
pp.query_required("myvar",myvar); /* function version */
pp_query_required("myvar",myvar); /* preprocessor macro version - preferred*/
Using the preprocessor macros enables code location information to be passed to the parser, so that
more informative error messages will be printed out.
Note that the ParmParse object must always be called pp
for this to work.
API definitions in src/IO/ParmParse.H
Classes
IO::ParmParse
Methods
Define()
ParmParse(std::string arg)
ParmParse()
getPrefix() const
ignore(std::string name)
forbid(std::string name, std::string explanation, std::string file="", std::string func="", int line=-1)
contains(std::string name)
query_required(std::string name, T &value, std::string file="", std::string func="", int line=-1)
query_default(std::string name, T &value, T defaultvalue, std::string="", std::string="", int=-1)
query_validate(std::string name, int &value, std::vector< int > possibleintvals, std::string file="", std::string func="", int line=-1)
query_validate(std::string name, std::string &value, std::vector< const char * > possiblecharvals, bool firstbydefault, std::string file="", std::string func="", int line=-1)
query_validate(std::string name, std::string &value, std::vector< const char * > possiblecharvals, std::string file="", std::string func="", int line=-1)
query_default(std::string name, std::string &value, const char *defaultvalue, std::string file="", std::string func="", int line=-1)
query_default(std::string name, int &value, bool defaultvalue, std::string file="", std::string func="query_default", int line=-1)
query_file(std::string name, std::string &value, bool copyfile, bool checkfile, std::string file="", std::string func="query_file", int line=-1)
query_file(std::string name, std::string &value, bool copyfile, std::string file="", std::string func="query_file", int line=-1)
query_file(std::string name, std::string &value, std::string file="", std::string func="query_file", int line=-1)
queryarr(std::string name, std::vector< T > &value, std::string, std::string, int)
queryarr(std::string name, Set::Vector &value, std::string file="", std::string func="queryarr", int line=-1)
queryarr(std::string name, Set::Matrix &value, std::string file="", std::string func="queryarr", int line=-1)
queryarr_required(std::string name, std::vector< T > &value, std::string file, std::string func, int line)
queryarr_default(std::string name, std::vector< std::string > &value, std::string defaultvalue, std::string="", std::string="", int=-1)
queryclass_enumerate(std::string a_name, std::vector< T > &value, int number=1, std::string file="", std::string func="", int line=__LINE__)
query_enumerate(std::string a_name, std::vector< T > &value, int number=1, std::string file="", std::string func="", int line=__LINE__)
AnyUnusedInputs()
GetUnusedInputs()
prefix()
full(std::string name)
queryclass(std::string name, T *value, std::string file="", std::string func="", int line=-1)
queryclass(std::string name, T &value, std::string file="", std::string func="", int line=__LINE__)
queryclass(T *value, std::string file="", std::string func="", int line=__LINE__)
queryclass(T &value, std::string file="", std::string func="", int line=__LINE__)
select(std::string name, PTRTYPE *&ic_eta, Args &&... args)
select_default(std::string name, PTRTYPE *&ic_eta, Args &&... args)
select_main(PTRTYPE *&ic_eta, Args &&... args)
select_only(PTRTYPE *&ic_eta, Args &&args)
select_only(PTRTYPE *&ic_eta)
query_exactly(std::vector< std::string > names, std::pair< std::string, Set::Scalar > values[N])
IO::WriteMetaData
src/IO/WriteMetaData.cpp src/IO/WriteMetaData.H
This provide an IO routine for generating run-specific output.
Every Alamo run produces a metadata file and (if applicable) a diff.patch
file that reflects the exact state when the simulation was run.
Note that the file WriteMetaData.cpp
file is _always_ recompiled
upon make
, in order to pull the latest information about the local
state at build.
This is standard infrastructure code; make sure you know what you ard doing before you change it.
API definitions in src/IO/WriteMetaData.H
Classes
Integrator
Integrator::Integrator
src/Integrator/Integrator.cpp src/Integrator/Integrator.H
Pure abstract class for managing data structures, time integration (with substepping), mesh refinement, and I/O.
Native input file parameters:
max_step = [maximum number of timesteps]
stop_time = [maximum simulation time]
timestep = [time step for coarsest level]
amr.regrid_int = [number of timesteps between regridding]
amr.plot_int = [number of timesteps between dumping output]
amr.plot_file = [base name of output directory]
amr.nsubsteps = [number of temporal substeps at each level. This can be
either a single int (which is then applied to every refinement
level) or an array of ints (equal to amr.max_level)
corresponding to the refinement for each level.]
Inherited input file parameters (from amrex AmrMesh class):
amr.v = [verbosity level]
amr.max_level = [maximum level of refinement]
amr.n_proper =
amr.grid_eff =
amr.n_error_buff =
amr.ref_ratio_vect = [refinement ratios in each direction]
amr.ref_ratio = [refinement ratio in all directions (cannot be used with ref_ratio_vect)]
amr.max_grid_x =
amr.blocking_factor =
amr.n_cell = [number of cells on coarsest level]
amr.refine_grid_layout =
amr.check_input =
Parameter |
Type |
Values |
---|---|---|
Number of iterations before ending (default is maximum possible int) |
2147483647 |
|
Simulation time before ending |
required |
|
Nominal timestep on amrlev = 0 |
required |
|
Name of restart file to READ from |
||
Name of cell-fab restart file to read from |
||
Name of node-fab restart file to read from |
||
Space-separated list of entries to ignore |
||
Regridding interval in step numbers |
2 |
|
Regridding interval based on coarse level only |
0 |
|
Interval (in timesteps) between plotfiles (Default negative value will cause the plot interval to be ignored.) |
-1 |
|
Interval (in simulation time) between plotfiles (Default negative value will cause the plot dt to be ignored.) |
-1.0 |
|
Output file: see IO::FileNameParse for wildcards and variable substitution |
output |
|
Turn on to write all output in cell fabs (default: off) |
false |
|
Turn off to prevent any cell based output (default: on) |
true |
|
Turn on to write all output in node fabs (default: off) |
false |
|
Turn off to prevent any node based output (default: on) |
true |
|
Abort if a plotfile contains nan or inf. |
true |
|
Specify a maximum level of refinement for output files (NO REFINEMENT) |
-1 |
|
Number of substeps to take on each level (default: 2) |
||
Number of substeps to take on each level (set all levels to this value) |
required |
|
activate dynamic CFL-based timestep |
||
how much information to print |
0 1 |
|
number of previous timesteps for rolling average |
5 |
|
dynamic teimstep CFL condition |
1.0 |
|
minimum timestep size allowed shen stepping dynamically |
timestep |
|
maximum timestep size allowed shen stepping dynamically |
timestep |
|
Integration interval (1) |
1 |
|
Interval (in timesteps) between writing (Default negative value will cause the plot interval to be ignored.) |
-1 |
|
Interval (in simulation time) between writing (Default negative value will cause the plot dt to be ignored.) |
-1.0 |
|
Use explicit mesh instead of AMR |
0 |
API definitions in src/Integrator/Integrator.H
Classes
Integrator::Integrator
Methods
Integrator()
- This is the constructor for the intetgrator class, which reads timestep information, simulation output and AMR, initialized time substep, and creates a new directory.~Integrator()
- Virtual destructure; make sure delete any pointers that you create here.InitData()
- Front-end method to initialize simulation on all levels.Restart(std::string restartfile, bool a_node=false)
- Read in output from previous simulation and start simulation at that point - Not currently tested.Evolve()
- Front-end method to start simulation.SetFilename(std::string _plot_file)
- Simple setter to set filename.GetFilename()
- Simple getter to get filename.regrid(int lbase, Set::Scalar time, bool initial=false) override
- This overrides an AMReX method just to allow for explicit meshing when desired.InitFromScratch(Set::Scalar time)
- This creates a new levels that have not previously been used.AddField(Set::Field< T > &new_field, BC::BC< T > *new_bc, int ncomp, int nghost, std::string name, bool writeout, bool evolving, std::vector< std::string >)
RegisterGeneralFab(Set::Field< T > &new_fab, int ncomp, int nghost, bool evolving)
RegisterGeneralFab(Set::Field< T > &new_fab, int ncomp, int nghost, std::string a_name, bool evolving)
RegisterGeneralFab(Set::Field< T > &new_fab, int ncomp, int nghost, bool writeout, std::string a_name, bool evolving)
Initialize(int lev)=0
- You must override this function to inherit this class; this function is called before the simulation begins, and is where initial conditions should be applied.Advance(int lev, amrex::Real time, amrex::Real dt)=0
- You must override this function to inherit this class; Advance is called every time(sub)step, and implements the evolution of the system in time.TagCellsForRefinement(int lev, amrex::TagBoxArray &tags, amrex::Real time, int ngrow)=0
- You must override this function to inherit this class; Advance is called every time(sub)step, and implements the evolution of the system in time.TimeStepBegin(Set::Scalar, int)
- This optional function is called at the beginning of every timestep, and can be used to complete additional global solves, e.g.TimeStepComplete(Set::Scalar, int)
- This optional function is called at the end of every timestep, and can be used to complete additional global solves, e.g.Integrate(int, Set::Scalar, int, const amrex::MFIter &, const amrex::Box &)
- This is a function that is called by to update the variables registered in RegisterIntegratedVariable; you can override this to do your integration.Regrid(int, Set::Scalar)
- An optionally overridable method to trigger behavior whenver a regrid occurs.RegisterNewFab(Set::Field< Set::Scalar > &new_fab, BC::BC< Set::Scalar > *new_bc, int ncomp, int nghost, std::string name, bool writeout, std::vector< std::string > suffix={})
- Add a new cell-based scalar field.RegisterNewFab(Set::Field< Set::Scalar > &new_fab, int ncomp, std::string name, bool writeout, std::vector< std::string > suffix={})
- Add a new cell-based scalar field (with additional arguments).RegisterNodalFab(Set::Field< Set::Scalar > &new_fab, int ncomp, int nghost, std::string name, bool writeout, std::vector< std::string > suffix={})
- Add a new node-based scalar field.RegisterNodalFab(Set::Field< Set::Scalar > &new_fab, BC::BC< Set::Scalar > *new_bc, int ncomp, int nghost, std::string name, bool writeout, std::vector< std::string > suffix={})
- Add a new node-based scalar field (wtih additional arguments)RegisterGeneralFab(Set::Field< T > &new_fab, int ncomp, int nghost, bool evolving=true)
- Add a templated nodal field.RegisterGeneralFab(Set::Field< T > &new_fab, int ncomp, int nghost, std::string a_name, bool evolving=true)
- Add a templated nodal field (additional arguments)RegisterGeneralFab(Set::Field< T > &new_fab, int ncomp, int nghost, bool writeout, std::string a_name, bool evolving=true)
- Add a templated nodal field (additional arguments)AddField(Set::Field< T > &new_field, BC::BC< T > *new_bc, int ncomp, int nghost, std::string, bool writeout, bool evolving, std::vector< std::string > suffix={})
- Add a field with arbitrary type (templated with T) and grid location (templated with d).SetFinestLevel(const int a_finestlevel)
- Utility to ensure that all fields know what the finest level is.RegisterIntegratedVariable(Set::Scalar *integrated_variable, std::string name, bool extensive=true)
- Register a variable to be integrated over the spatial domain using the Integrate function.SetTimestep(Set::Scalar _timestep)
- Utility to set the coarse-grid timestep.SetPlotInt(int plot_int)
- Utility to set the frequency (in timesteps) of plotfile dumping.SetThermoInt(int a_thermo_int)
- Utility to set the frequency (in timesteps) of thermo data calculation.SetThermoPlotInt(int a_thermo_plot_int)
- Utility to set the frequency (in timesteps) of thermo data writing to file.SetStopTime(Set::Scalar a_stop_time)
- Utility to set the global stop time.DynamicTimestep_SyncTimeStep(int lev, Set::Scalar dt_min)
- Params for the dynamic timestp.DynamicTimestep_Reset()
DynamicTimestep_Update()
IntegrateVariables(Set::Scalar cur_time, int step)
WritePlotFile(bool initial=false) const
WritePlotFile(std::string prefix, Set::Scalar time, int step) const
WritePlotFile(Set::Scalar time, amrex::Vector< int > iter, bool initial=false, std::string prefix="") const
MakeNewLevelFromScratch(int lev, amrex::Real time, const amrex::BoxArray &ba, const amrex::DistributionMapping &dm) override
MakeNewLevelFromCoarse(int lev, amrex::Real time, const amrex::BoxArray &ba, const amrex::DistributionMapping &dm) override
- Wrapper to call FillCoarsePatch.RemakeLevel(int lev, amrex::Real time, const amrex::BoxArray &ba, const amrex::DistributionMapping &dm) override
- RESETS ALL MULTIFABS AT A GIVEN LEVEL.ClearLevel(int lev) override
ErrorEst(int lev, amrex::TagBoxArray &tags, amrex::Real time, int ngrow) override
FillPatch(int lev, amrex::Real time, amrex::Vector< std::unique_ptr< amrex::MultiFab > > &source_mf, amrex::MultiFab &destination_multifab, BC::BC< Set::Scalar > &physbc, int icomp)
- This is the function that is responsible for updating patch data.CountCells(int lev)
- Simple utility to count cells.TimeStep(int lev, amrex::Real time, int iteration)
- Timestep marching.FillCoarsePatch(int lev, amrex::Real time, Set::Field< Set::Scalar > &mf, BC::BC< Set::Scalar > &physbc, int icomp, int ncomp)
- Fill a fab at current level with the data from one level up.GetData(const int lev, const amrex::Real time, amrex::Vector< amrex::MultiFab * > &data, amrex::Vector< amrex::Real > &datatime)
PlotFileName(int lev, std::string prefix="") const
Variables
bool Integrator::Integrator::on
int Integrator::Integrator::verbose
int Integrator::Integrator::nprevious
Set::Scalar Integrator::Integrator::cfl
Set::Scalar Integrator::Integrator::min
Set::Scalar Integrator::Integrator::max
std::vector<Set::Scalar> Integrator::Integrator::dt_limit_min
std::vector<Set::Scalar> Integrator::Integrator::previous_timesteps
int Integrator::Integrator::number_of_fabs
std::vector<Set::Field<Set::Scalar>*> Integrator::Integrator::fab_array
std::vector<int> Integrator::Integrator::ncomp_array
std::vector<int> Integrator::Integrator::nghost_array
std::vector<std::vector<std::string> > Integrator::Integrator::name_array
std::vector<BC::BC<Set::Scalar>*> Integrator::Integrator::physbc_array
std::vector<bool> Integrator::Integrator::writeout_array
bool Integrator::Integrator::any
bool Integrator::Integrator::all
int Integrator::Integrator::interval
Set::Scalar Integrator::Integrator::dt
int Integrator::Integrator::plot_int
- How frequently to dump plot file (default: never)Set::Scalar Integrator::Integrator::plot_dt
int Integrator::Integrator::number
std::vector<Set::Scalar*> Integrator::Integrator::vars
std::vector<std::string> Integrator::Integrator::names
std::vector<bool> Integrator::Integrator::extensives
int Integrator::Integrator::on
std::vector<amrex::Box> Integrator::Integrator::box
struct Integrator::Integrator Integrator::Integrator::dynamictimestep
amrex::Vector<amrex::Real> Integrator::Integrator::t_new
- Keep track of current old simulation time on each level.amrex::Vector<int> Integrator::Integrator::istep
- Keep track of where each level is.std::string Integrator::Integrator::plot_file
- Plotfile name.amrex::Real Integrator::Integrator::timestep
- Timestep for the base level of refinement.amrex::Vector<amrex::Real> Integrator::Integrator::dt
- Timesteps for each level of refinement.amrex::Vector<int> Integrator::Integrator::nsubsteps
- how many substeps on each level?bool Integrator::Integrator::integrate_variables_before_advance
bool Integrator::Integrator::integrate_variables_after_advance
struct Integrator::Integrator Integrator::Integrator::node
struct Integrator::Integrator Integrator::Integrator::cell
std::vector<BaseField*> Integrator::Integrator::m_basefields
std::vector<BaseField*> Integrator::Integrator::m_basefields_cell
BC::Nothing Integrator::Integrator::bcnothing
struct Integrator::Integrator Integrator::Integrator::thermo
int Integrator::Integrator::regrid_int
- Determine how often to regrid (default: 2)int Integrator::Integrator::base_regrid_int
- Determine how often to regrid based on coarse level only (default: 0)std::string Integrator::Integrator::restart_file_cell
std::string Integrator::Integrator::restart_file_node
struct Integrator::Integrator Integrator::Integrator::explicitmesh
int Integrator::Integrator::abort_on_nan
int Integrator::Integrator::max_plot_level
amrex::Vector<amrex::Real> Integrator::Integrator::t_old
- Keep track of current old simulation time on each level.int Integrator::Integrator::max_step
- Maximum allowable timestep.amrex::Real Integrator::Integrator::tstart
- Default start time (default: 0)amrex::Real Integrator::Integrator::stop_time
- Default stop time.
Integrator::AllenCahn
This is a simple implementation of an Allen-Cahn equation governed by
where \(\alpha(x,t)\) is the order parameter.
Parameter |
Type |
Values |
---|---|---|
Criterion for mesh refinement [0.01] |
0.01 |
|
Value for \(L\) (mobility) |
1.0 |
|
Value for \(\epsilon\) (diffuse boundary width) |
0.1 |
|
Value for \(\kappa\) (Interface energy parameter) |
1.0 |
|
Value for \(\lambda\) (Chemical potential coefficient) |
1.0 |
|
Force directional growth: 0=no growth, 1=only positive, -1=only negative |
0 1 -1 |
|
Time to start forcing directional growth |
0.0 |
|
Set the initial condition for the alpha field |
sphere constant expression bmp png random psread |
|
Use a constant BC object for temperature value.bc = new BC::Constant(1); :ref:`BC::Constant` parameters |
constant |
API definitions in src/Integrator/AllenCahn.H
Classes
Integrator::AllenCahn
- This is the definition of the Allen Cahn class.Methods
AllenCahn()
AllenCahn(IO::ParmParse &pp)
~AllenCahn()
Initialize(int lev)
Advance(int lev, Set::Scalar time, Set::Scalar dt)
TagCellsForRefinement(int lev, amrex::TagBoxArray &a_tags, Set::Scalar, int)
Variables
Set::Field<Set::Scalar> Integrator::AllenCahn::alpha_mf
Set::Field<Set::Scalar> Integrator::AllenCahn::alpha_old_mf
- Temperature field variable (current timestep)IC::IC<Set::Scalar>* Integrator::AllenCahn::ic
- Temperature field variable (previous timestep)Set::Field<Set::Scalar>& Integrator::AllenCahn::eta_mf
- Object used to initialize temperature field.Set::Field<Set::Scalar>& Integrator::AllenCahn::eta_old_mf
struct Integrator::AllenCahn Integrator::AllenCahn::ch
Set::Scalar Integrator::AllenCahn::L
Set::Scalar Integrator::AllenCahn::eps
Set::Scalar Integrator::AllenCahn::grad
Set::Scalar Integrator::AllenCahn::chempot
Set::Scalar Integrator::AllenCahn::direction_tstart
int Integrator::AllenCahn::direction
int Integrator::AllenCahn::number_of_components
int Integrator::AllenCahn::number_of_ghost_cells
Set::Scalar Integrator::AllenCahn::refinement_threshold
BC::BC<Set::Scalar>* Integrator::AllenCahn::bc
Integrator::BaseField
API definitions in src/Integrator/BaseField.H
Classes
Integrator::BaseField
Methods
~BaseField()=default
RemakeLevel(int lev, amrex::Real time, const amrex::BoxArray &cgrids, const amrex::DistributionMapping &dm)=0
MakeNewLevelFromCoarse(int lev, amrex::Real time, const amrex::BoxArray &cgrids, const amrex::DistributionMapping &dm)=0
MakeNewLevelFromScratch(int lev, amrex::Real t, const amrex::BoxArray &cgrids, const amrex::DistributionMapping &dm)=0
SetFinestLevel(const int a_finestlevel)=0
FillPatch(const int lev, const Set::Scalar time)=0
FillBoundary(const int lev, Set::Scalar time)=0
AverageDown(const int lev, amrex::IntVect refRatio)=0
NComp()=0
Copy(int, amrex::MultiFab &, int, int)=0
Name(int)=0
setName(std::string a_name)=0
setBC(void *a_bc)=0
getBC()=0
Variables
bool Integrator::BaseField::writeout
bool Integrator::BaseField::evolving
Set::Hypercube Integrator::BaseField::m_gridtype
Integrator::Field
Methods
Field(Set::Field< T > &a_field, const amrex::Vector< amrex::Geometry > &a_geom, const amrex::Vector< amrex::IntVect > &a_refRatio, int a_ncomp, int a_nghost)
FillPatch(int lev, amrex::Real time, amrex::Vector< std::unique_ptr< amrex::FabArray< amrex::BaseFab< T > > > > &source_mf, amrex::FabArray< amrex::BaseFab< T > > &destination_mf, int icomp)
FillPatch(int lev, amrex::Real time) override
FillCoarsePatch(int lev, amrex::Real time, int icomp, int ncomp)
RemakeLevel(int lev, amrex::Real time, const amrex::BoxArray &cgrids, const amrex::DistributionMapping &dm) override
MakeNewLevelFromCoarse(int lev, amrex::Real time, const amrex::BoxArray &cgrids, const amrex::DistributionMapping &dm) override
MakeNewLevelFromScratch(int lev, amrex::Real, const amrex::BoxArray &cgrids, const amrex::DistributionMapping &dm) override
SetFinestLevel(const int a_finestlevel) override
FillBoundary(const int lev, Set::Scalar time) override
AverageDown(const int lev, amrex::IntVect refRatio) override
NComp() override
Copy(int a_lev, amrex::MultiFab &a_dst, int a_dstcomp, int a_nghost) override
setName(std::string a_name) override
Name(int i) override
setBC(void *a_bc) override
getBC() override
Variables
Set::Field<T>& Integrator::Field< T >::m_field
const amrex::Vector<amrex::Geometry>& Integrator::Field< T >::m_geom
const amrex::Vector<amrex::IntVect>& Integrator::Field< T >::m_refRatio
const int Integrator::Field< T >::m_ncomp
const int Integrator::Field< T >::m_nghost
BC::BC<T>* Integrator::Field< T >::m_bc
Numeric::Interpolator::NodeBilinear<T> Integrator::Field< T >::node_bilinear
Integrator::Field::EmptyBC
Methods
operator()(amrex::FabArray< amrex::BaseFab< T > > &, int, int, amrex::IntVect const &, amrex::Real, int)
GetBCRec()
Integrator::CahnHilliard
src/Integrator/CahnHilliard.cpp src/Integrator/CahnHilliard.H
This implements a basic two-phase field model with Cahn-Hilliard kinetics.
The free energy is
The corresponding governing equation under conservative kinetics is
which is integrated using a forward Euler scheme.
This is tested in CahnHilliard
Parameter |
Type |
Values |
---|---|---|
Interface energy |
0.0005 |
|
Mobility |
1.0 |
|
Regridding criterion |
1E100 |
|
initial condition for \(\eta\) |
random |
|
boundary condition for \(\eta\) |
constant |
|
Which method to use - realspace or spectral method. |
realspace spectral |
API definitions in src/Integrator/CahnHilliard.H
Classes
Integrator::CahnHilliard
Methods
CahnHilliard()
- Basic constructor (don’t use)~CahnHilliard()
- Destroy pointers defined in Parse.CahnHilliard(IO::ParmParse &pp)
- Use this constructor.Initialize(int lev) override
- values in fields.Advance(int lev, Set::Scalar time, Set::Scalar dt) override
- Integrate eta over one timestep on lev.AdvanceSpectral(int lev, Set::Scalar time, Set::Scalar dt)
- spectral version of advanceAdvanceReal(int lev, Set::Scalar time, Set::Scalar dt)
- realspace version of advanceTagCellsForRefinement(int lev, amrex::TagBoxArray &tags, amrex::Real time, int ngrow) override
- Mark any cells that need to be refined.
Variables
Set::Field<Set::Scalar> Integrator::CahnHilliard::etanew_mf
Set::Field<Set::Scalar> Integrator::CahnHilliard::etaold_mf
- The new value for eta this timestep.Set::Field<Set::Scalar> Integrator::CahnHilliard::intermediate
- Last timestep’s value for eta.BC::BC<Set::Scalar>* Integrator::CahnHilliard::bc
- Intermediate field used for CH kinetics.IC::IC<Set::Scalar>* Integrator::CahnHilliard::ic
- eta’s bc objectSet::Scalar Integrator::CahnHilliard::gamma
- eta’s ic objectSet::Scalar Integrator::CahnHilliard::L
Set::Scalar Integrator::CahnHilliard::refinement_threshold
std::string Integrator::CahnHilliard::method
Integrator::Dendrite
This is a BASIC phase field method for dendritic growth as described in “A Numerical Approach to Three-Dimensional Dendritic Solidification” by Ryo Kobayashi (1994) Reference: https://doi.org/10.1080/10586458.1994.10504577
Parameter |
Type |
Values |
---|---|---|
Pre-multiplier of "m" barrier height |
required |
|
Anisotropy factor |
required |
|
Anisotropic temperature coupling factor |
required |
|
Thermal constant |
1.0 |
|
Diffuse boundary width |
required |
|
Diffusive timescale |
required |
|
Orientation about z axis (Deg) |
0.0 |
|
Refinement criteria for temperature |
0.01 |
|
Refinement criteria for phi |
0.01 |
|
boundary conditions for temperature field |
constant |
|
boundary conditions for \(\phi\) field |
constant |
API definitions in src/Integrator/Dendrite.H
Classes
Integrator::Dendrite
Methods
Dendrite()
Dendrite(IO::ParmParse &pp)
~Dendrite()
Initialize(int lev)
Advance(int lev, Set::Scalar, Set::Scalar dt)
TagCellsForRefinement(int lev, amrex::TagBoxArray &a_tags, Set::Scalar, int)
Variables
Set::Field<Set::Scalar> Integrator::Dendrite::temp_mf
Set::Field<Set::Scalar> Integrator::Dendrite::temp_old_mf
Set::Field<Set::Scalar> Integrator::Dendrite::phi_mf
Set::Field<Set::Scalar> Integrator::Dendrite::phi_old_mf
Set::Field<Set::Scalar>& Integrator::Dendrite::eta_mf
Set::Field<Set::Scalar>& Integrator::Dendrite::eta_old_mf
int Integrator::Dendrite::number_of_components
int Integrator::Dendrite::number_of_ghost_cells
Set::Scalar Integrator::Dendrite::alpha
Set::Scalar Integrator::Dendrite::delta
Set::Scalar Integrator::Dendrite::gamma
Set::Scalar Integrator::Dendrite::diffusion
Set::Scalar Integrator::Dendrite::eps
Set::Scalar Integrator::Dendrite::tau
Set::Scalar Integrator::Dendrite::theta
Set::Matrix Integrator::Dendrite::R
Set::Scalar Integrator::Dendrite::refinement_threshold_temp
Set::Scalar Integrator::Dendrite::refinement_threshold_phi
IC::IC<Set::Scalar>* Integrator::Dendrite::ic_temp
IC::IC<Set::Scalar> * Integrator::Dendrite::ic_phi
BC::BC<Set::Scalar>* Integrator::Dendrite::bc_temp
BC::BC<Set::Scalar> * Integrator::Dendrite::bc_phi
Integrator::Flame
src/Integrator/Flame.cpp src/Integrator/Flame.H
Parameter |
Type |
Values |
---|---|---|
Whether to include extra fields (such as mdot, etc) in the plot output |
true |
|
Simulation timestep |
1.0e-4 |
|
Burn width thickness |
0.0 |
|
Interface energy param |
0.0 |
|
Scaling factor for mobility |
1.0 |
|
Chemical potential multiplier |
0.0 |
|
Unburned rest energy |
0.0 |
|
Barrier energy |
0.0 |
|
Burned rest energy |
0.0 |
|
number of ghost cells in all fields |
2 |
|
Domain x length |
0.001 |
|
Domain y length |
0.001 |
|
Boundary conditions for phase field order params |
constant |
|
phase field initial condition |
laminate constant expression bmp png |
|
IO::ParmParse pp("thermal"); Whether to use the Thermal Transport Model |
false |
|
Whether to use Neo-hookean Elastic model |
0 |
|
System Initial Temperature |
0.0 |
|
Body force |
0.0 |
|
Phi refinement criteria |
1 |
|
AP Density |
required |
|
HTPB Density |
required |
|
AP Thermal Conductivity |
required |
|
HTPB Thermal Conductivity |
required |
|
AP Specific Heat |
required |
|
HTPB Specific Heat |
required |
|
Baseline heat flux |
0.0 |
|
AP Pre-exponential factor for Arrhenius Law |
required |
|
HTPB Pre-exponential factor for Arrhenius Law |
required |
|
AP Activation Energy for Arrhenius Law |
required |
|
HTPB Activation Energy for Arrhenius Law |
required |
|
Used to change heat flux units |
1.0 |
|
Systen AP mass fraction |
0.8 |
|
AP mass flux reference value |
0.0 |
|
HTPB mass flux reference value |
0.0 |
|
AP/HTPB mass flux reference value |
0.0 |
|
Temperature of the Standin Fluid |
300.0 |
|
K; dispersion variables are use to set the outter field properties for the void grain case. |
||
rho; dispersion variables are use to set the outter field properties for the void grain case. |
||
cp; dispersion variables are use to set the outter field properties for the void grain case. |
||
Scaling factor for AP thermal conductivity (default = 1.0) |
1.0 |
|
Scaling factor for HTPB thermal conductivity (default = 1.0) |
1.0 |
|
Temperature boundary condition |
constant |
|
laser initial condition |
constant expression |
|
thermal initial condition |
constant expression bmp png |
|
Constant pressure value |
1.0 |
|
Surgate heat flux model paramater - AP |
required |
|
Surgate heat flux model paramater - HTPB |
required |
|
Surgate heat flux model paramater - Total |
required |
|
Surgate heat flux model paramater - AP |
required |
|
Surgate heat flux model paramater - HTPB |
required |
|
Surgate heat flux model paramater - Total |
required |
|
Surgate heat flux model paramater - Total |
required |
|
Whether to include pressure to the arrhenius law |
0 |
|
Whether to use pressure to determined the reference Zeta |
1 |
|
Surgate heat flux model paramater - Homogenized |
1.81 |
|
Surgate heat flux model paramater - Homogenized |
1.34 |
|
AP power pressure law parameter (r*P^n) |
required |
|
HTPB power pressure law parameter (r*P^n) |
required |
|
AP/HTPB power pressure law parameter (r*P^n) |
required |
|
AP power pressure law parameter (r*P^n) |
required |
|
HTPB power pressure law parameter (r*P^n) |
required |
|
AP/HTPB power pressure law parameter (r*P^n) |
required |
|
Whether to compute the pressure evolution |
0 |
|
Whether to initialize Phi with homogenized properties |
0 |
|
Refinement criterion for eta field |
0.001 |
|
Refinement criterion for temperature field |
0.001 |
|
Eta value to restrict the refinament for the temperature field |
0.1 |
|
Refinement criterion for phi field [infinity] |
1.0e100 |
|
Lowest value of Eta. |
1.0e-8 |
|
IC type (psread, laminate, constant) |
psread laminate expression constant bmp png |
|
value.ic_phicell = new IC::PSRead(value.geom, pp, "phi.ic.psread"); AP/HTPB interface length |
1.0e-5 |
|
Reference interface length for heat integration |
1.0e-5 |
|
value.ic_phicell = new IC::Laminate(value.geom, pp, "phi.ic.laminate"); AP/HTPB interface length |
1.0e-5 |
|
Reference interface length for heat integration |
1.0e-5 |
|
value.ic_phicell = new IC::Expression(value.geom, pp, "phi.ic.expression"); Reference interface length for heat integration |
1.0e-5 |
|
AP/HTPB interface length |
1.0e-5 |
|
value.ic_phicell = new IC::Constant(value.geom, pp, "phi.ic.constant"); Reference interface length for heat integration |
1.0e-5 |
|
AP/HTPB interface length |
1.0e-5 |
|
value.ic_phicell = new IC::BMP(value.geom, pp, "phi.ic.bmp"); Reference interface length for heat integration |
1.0e-5 |
|
AP/HTPB interface length |
1.0e-5 |
|
Reference interface length for heat integration |
1.0e-5 |
|
AP/HTPB interface length |
1.0e-5 |
|
Initial temperature for thermal expansion computation |
300.0 |
|
Set this to true to allow unused inputs without error. (Not recommended.) |
false |
API definitions in src/Integrator/Flame.H
Classes
Integrator::Flame
Methods
Flame()
Flame(IO::ParmParse &pp)
~Flame()
Initialize(int lev) override
TimeStepBegin(Set::Scalar a_time, int a_iter) override
TimeStepComplete(Set::Scalar a_time, int a_iter) override
Advance(int lev, Set::Scalar time, Set::Scalar dt) override
TagCellsForRefinement(int lev, amrex::TagBoxArray &tags, amrex::Real, int) override
Regrid(int lev, Set::Scalar time) override
Integrate(int amrlev, Set::Scalar time, int step, const amrex::MFIter &mfi, const amrex::Box &box) override
UpdateModel(int a_step, Set::Scalar a_time) override
Variables
Set::Field<Set::Scalar> Integrator::Flame::temp_mf
Set::Field<Set::Scalar> Integrator::Flame::temp_old_mf
Set::Field<Set::Scalar> Integrator::Flame::temps_mf
Set::Field<Set::Scalar> Integrator::Flame::temps_old_mf
Set::Field<Set::Scalar> Integrator::Flame::eta_mf
Set::Field<Set::Scalar> Integrator::Flame::eta_old_mf
Set::Field<Set::Scalar> Integrator::Flame::mob_mf
Set::Field<Set::Scalar> Integrator::Flame::mdot_mf
Set::Field<Set::Scalar> Integrator::Flame::phi_mf
Set::Field<Set::Scalar> Integrator::Flame::field
Set::Field<Set::Scalar> Integrator::Flame::alpha_mf
Set::Field<Set::Scalar> Integrator::Flame::heatflux_mf
Set::Field<Set::Scalar> Integrator::Flame::laser_mf
BC::BC<Set::Scalar>* Integrator::Flame::bc_temp
BC::BC<Set::Scalar>* Integrator::Flame::bc_eta
IC::IC<Set::Scalar>* Integrator::Flame::ic_phi
IC::IC<Set::Scalar>* Integrator::Flame::ic_laser
Set::Scalar Integrator::Flame::phi_refinement_criterion
Set::Scalar Integrator::Flame::m_refinement_criterion
Set::Scalar Integrator::Flame::t_refinement_criterion
Set::Scalar Integrator::Flame::t_refinement_restriction
Set::Scalar Integrator::Flame::zeta
Set::Scalar Integrator::Flame::zeta_0
Set::Scalar Integrator::Flame::small
Set::Scalar Integrator::Flame::base_time
IC::IC<Set::Scalar>* Integrator::Flame::ic_eta
int Integrator::Flame::ghost_count
int Integrator::Flame::homogeneousSystem
bool Integrator::Flame::plot_field
int Integrator::Flame::variable_pressure
struct Integrator::Flame Integrator::Flame::pf
struct Integrator::Flame Integrator::Flame::pressure
struct Integrator::Flame Integrator::Flame::thermal
struct Integrator::Flame Integrator::Flame::elastic
Set::Scalar Integrator::Flame::volume
Set::Scalar Integrator::Flame::area
Set::Scalar Integrator::Flame::chamber_area
Set::Scalar Integrator::Flame::chamber_pressure
Set::Scalar Integrator::Flame::massflux
Set::Scalar Integrator::Flame::x_len
Set::Scalar Integrator::Flame::y_len
BC::BC<Set::Scalar>* Integrator::Flame::bc_psi
Set::Scalar Integrator::Flame::gamma
Set::Scalar Integrator::Flame::eps
Set::Scalar Integrator::Flame::lambda
Set::Scalar Integrator::Flame::kappa
Set::Scalar Integrator::Flame::w1
Set::Scalar Integrator::Flame::w12
Set::Scalar Integrator::Flame::w0
Set::Scalar Integrator::Flame::min_eta
int Integrator::Flame::evolve
Set::Scalar Integrator::Flame::P
Set::Scalar Integrator::Flame::a1
Set::Scalar Integrator::Flame::a2
Set::Scalar Integrator::Flame::a3
Set::Scalar Integrator::Flame::b1
Set::Scalar Integrator::Flame::b2
Set::Scalar Integrator::Flame::b3
Set::Scalar Integrator::Flame::c1
int Integrator::Flame::mob_ap
int Integrator::Flame::dependency
Set::Scalar Integrator::Flame::h1
Set::Scalar Integrator::Flame::h2
struct Integrator::Flame Integrator::Flame::arrhenius
Set::Scalar Integrator::Flame::r_ap
Set::Scalar Integrator::Flame::r_htpb
Set::Scalar Integrator::Flame::r_comb
Set::Scalar Integrator::Flame::n_ap
Set::Scalar Integrator::Flame::n_htpb
Set::Scalar Integrator::Flame::n_comb
Set::Scalar Integrator::Flame::a_fit
Set::Scalar Integrator::Flame::b_fit
Set::Scalar Integrator::Flame::c_fit
struct Integrator::Flame Integrator::Flame::power
bool Integrator::Flame::on
Set::Scalar Integrator::Flame::rho_ap
Set::Scalar Integrator::Flame::rho_htpb
Set::Scalar Integrator::Flame::k_ap
Set::Scalar Integrator::Flame::k_htpb
Set::Scalar Integrator::Flame::cp_ap
Set::Scalar Integrator::Flame::cp_htpb
Set::Scalar Integrator::Flame::q0
Set::Scalar Integrator::Flame::bound
Set::Scalar Integrator::Flame::m_ap
Set::Scalar Integrator::Flame::m_htpb
Set::Scalar Integrator::Flame::m_comb
Set::Scalar Integrator::Flame::E_ap
Set::Scalar Integrator::Flame::E_htpb
Set::Scalar Integrator::Flame::hc
Set::Scalar Integrator::Flame::modeling_ap
Set::Scalar Integrator::Flame::modeling_htpb
Set::Scalar Integrator::Flame::mlocal_ap
Set::Scalar Integrator::Flame::mlocal_htpb
Set::Scalar Integrator::Flame::mlocal_comb
Set::Scalar Integrator::Flame::T_fluid
Set::Scalar Integrator::Flame::massfraction
Set::Scalar Integrator::Flame::disperssion1
Set::Scalar Integrator::Flame::disperssion2
Set::Scalar Integrator::Flame::disperssion3
IC::IC<Set::Scalar>* Integrator::Flame::ic_temp
int Integrator::Flame::on
Set::Scalar Integrator::Flame::Tref
model_type Integrator::Flame::model_ap
model_type Integrator::Flame::model_htpb
Set::Scalar Integrator::Flame::traction
int Integrator::Flame::phirefinement
Integrator::Fracture
Parameter |
Type |
Values |
---|---|---|
Type of crack {notch,ellipsoid} |
API definitions in src/Integrator/Fracture.H
Classes
Integrator::Fracture
Methods
Fracture()
Initialize(int ilev) override
TimeStepBegin(Set::Scalar, int) override
Advance(int lev, Set::Scalar, Set::Scalar dt) override
TagCellsForRefinement(int lev, amrex::TagBoxArray &a_tags, amrex::Real, int) override
Integrate(int amrlev, Set::Scalar, int, const amrex::MFIter &mfi, const amrex::Box &box) override
TimeStepComplete(amrex::Real, int) override
Variables
int Integrator::Fracture::number_of_ghost_nodes
- Number of ghost nodes.int Integrator::Fracture::number_of_materials
int Integrator::Fracture::nlevels
struct Integrator::Fracture Integrator::Fracture::elastic
struct Integrator::Fracture Integrator::Fracture::crack
struct Integrator::Fracture Integrator::Fracture::material
struct Integrator::Fracture Integrator::Fracture::loading
Set::Field<Set::Scalar> Integrator::Fracture::disp_mf
- displacement fieldSet::Field<Set::Scalar> Integrator::Fracture::strain_mf
- total strain field (gradient of displacement)Set::Field<Set::Scalar> Integrator::Fracture::stress_mf
- stress fieldSet::Field<Set::Scalar> Integrator::Fracture::rhs_mf
- rhs fab for elastic solutionSet::Field<Set::Scalar> Integrator::Fracture::residual_mf
- residual field for solverSet::Field<Set::Scalar> Integrator::Fracture::energy_mf
- total elastic energySet::Field<Set::Scalar> Integrator::Fracture::energy_pristine_mf
- energy of the prisitne material as if no crack is presentSet::Field<Set::Scalar> Integrator::Fracture::energy_pristine_old_mf
- energy of the pristine material for previous time step.Set::Scalar Integrator::Fracture::int_energy
- integrated energy over the entire domain.BC::Operator::Elastic::Constant Integrator::Fracture::brittlebc
- elastic if using brittle fractureSet::Scalar Integrator::Fracture::df_mult
- mulitplier for elastic driving force.bool Integrator::Fracture::do_solve_now
int Integrator::Fracture::interval
Set::Scalar Integrator::Fracture::omega
Set::Field<Set::Scalar> Integrator::Fracture::c_mf
- crack field at current time stepSet::Field<Set::Scalar> Integrator::Fracture::c_old_mf
- crack field at previous time stepSet::Field<Set::Scalar> Integrator::Fracture::driving_force_mf
- crack driving forces.Set::Scalar Integrator::Fracture::int_crack
- integrated crack field over the entire domain.Set::Scalar Integrator::Fracture::driving_force_reference
Set::Scalar Integrator::Fracture::driving_force_norm
Set::Scalar Integrator::Fracture::driving_force_norminf
Set::Scalar Integrator::Fracture::driving_force_tolerance_rel
Set::Scalar Integrator::Fracture::driving_force_tolerance_abs
Model::Interface::Crack::Constant Integrator::Fracture::cracktype
- type of crack. See Crack/Constant or Crack/Sinamrex::Vector<std::string> Integrator::Fracture::ic_type
- crack type. See IC/Notch and IC/Ellipsoidamrex::Vector<IC::IC<Set::Scalar>*> Integrator::Fracture::ic
- crack . See IC/Notch and IC/Ellipsoidbool Integrator::Fracture::is_ic
Set::Scalar Integrator::Fracture::scaleModulusMax
- material modulus ratio inside crack (default = 0.02).Set::Scalar Integrator::Fracture::refinement_threshold
Set::Scalar Integrator::Fracture::mult_df_Gc
- Multiplier for Gc/zeta term.Set::Scalar Integrator::Fracture::mult_df_lap
- Multiplier for the laplacian term.Set::Scalar Integrator::Fracture::beta
amrex::Vector<brittle_fracture_model_type_test> Integrator::Fracture::brittlemodeltype
Set::Field<Set::Scalar> Integrator::Fracture::material_mf
Set::Field<brittle_fracture_model_type_test> Integrator::Fracture::model_mf
std::string Integrator::Fracture::input_material
IC::IC<Set::Scalar>* Integrator::Fracture::ic
std::string Integrator::Fracture::ic_type
Set::Vector Integrator::Fracture::body_force
Set::Scalar Integrator::Fracture::val
Integrator::Hydro
src/Integrator/Hydro.cpp src/Integrator/Hydro.H
Parameter |
Type |
Values |
---|---|---|
eta-based refinement |
0.01 |
|
vorticity-based refinement |
0.01 |
|
velocity gradient-based refinement |
0.01 |
|
pressure-based refinement |
1e100 |
|
density-based refinement |
1e100 |
|
gamma for gamma law |
required |
|
cfl condition |
required |
|
cfl condition |
1E100 |
|
linear viscosity coefficient |
required |
|
pp_query_default("Pfactor", value.Pfactor,1.0); // (to be removed) test factor for viscous source reference pressure for Roe solver |
1.0 |
|
Boundary condition for density |
constant expression |
|
Boundary condition for energy |
constant expression |
|
Boundary condition for momentum |
constant expression |
|
Boundary condition for phase field order parameter |
constant expression |
|
small regularization value |
1E-8 |
|
cutoff value |
-1E100 |
|
lagrange no-penetration factor |
0.0 |
|
eta initial condition |
constant laminate expression bmp png |
|
velocity initial condition |
constant expression |
|
solid pressure initial condition |
constant expression |
|
density initial condition type |
constant expression |
|
solid momentum initial condition |
constant expression |
|
solid density initial condition |
constant expression |
|
solid energy initial condition |
constant expression |
|
diffuse boundary prescribed mass flux |
constant expression |
|
diffuse boundary prescribed velocity |
constant expression |
|
diffuse boundary prescribed heat flux |
constant expression |
|
Riemann solver |
roe |
API definitions in src/Integrator/Hydro.H
Classes
Integrator::HeatConduction
src/Integrator/HeatConduction.H
This implements a basic heat conduction method in Alamo. The partial differential equation to be solved is
where \(T\) is temperature, \(t\) is time, and \(alpha\) is the thermal diffusivity. Integration is performed explicitly in time using forward Euler, and differentiation is performed using the finite difference method.
Parameter |
Type |
Values |
---|---|---|
Diffusion coefficient \(\alpha\). *This is an example of a required input variable - - program will terminate unless it is provided.* |
required |
|
Criterion for mesh refinement. *This is an example of a default input variable. The default value is provided here, not in the definition of the variable.* |
0.01 |
|
Initial condition type. |
constant sphere expression |
|
Select BC object for temperature |
constant expression |
|
Select between using a realspace solve or the spectral method |
realspace spectral |
API definitions in src/Integrator/HeatConduction.H
Classes
Integrator::HeatConduction
Methods
HeatConduction(int a_nghost=2)
HeatConduction(IO::ParmParse &pp)
~HeatConduction()
Initialize(int lev)
Advance(int lev, Set::Scalar time, Set::Scalar dt)
AdvanceSpectral(int, Set::Scalar, Set::Scalar)
TagCellsForRefinement(int lev, amrex::TagBoxArray &a_tags, Set::Scalar, int)
Variables
Set::Field<Set::Scalar> Integrator::HeatConduction::temp_mf
Set::Field<Set::Scalar> Integrator::HeatConduction::temp_old_mf
std::string Integrator::HeatConduction::method
const int Integrator::HeatConduction::number_of_components
const int Integrator::HeatConduction::number_of_ghost_cells
Set::Scalar Integrator::HeatConduction::alpha
Set::Scalar Integrator::HeatConduction::refinement_threshold
IC::IC<Set::Scalar>* Integrator::HeatConduction::ic
BC::BC<Set::Scalar>* Integrator::HeatConduction::bc
Integrator::Mechanics
This is a general purpose integrator that focuses on solving
elasticity/mechanics equations in the absence of other multiphysics
simulations.
It is enabled by alamo.program=mechanics
if used on its own, in
which case there is no prefix.
If it is being used by another integrator, see that integrator to determine
the value of [prefix]
(often equal to elastic
).
This integrator inherits from Integrator::Base::Mechanics; see documentation for that integrator for additional parameters.
Model setup There are two basic tools for setting up a mechanics problem in this integrator.
The
eta
field: this is used to mix models of different types. Usenmodels
to specify how many material models to use, and then specify each model asmodel1
,model2
, etc. The type of moel is specified using thealamo.program.mechanics.model
input.Once you have done this, you must determine the spatial distribution of each model. This is done by choosing an IC for the eta field with
ic.type
. TheIC::Expression
is the most general and recommended. The models are then mixed linearly, i.e.\[W_{\textrm{eff}} = \sum_{i=1}^N W_i\,\eta_i(\mathbf{x})\]See the Eshelby test for an example of model mixing.
The
psi
field: this is used specifically for cases where a “void” region is desired. Its usage is similar to theeta
case, and is conceptually similar in that it scales the model field to near-zero in order to mimic the (lack of) mechanical behavior in an empty region. It is important to usepsi
here, for reasons that are discussed in detail in this paper. The initialization ofpsi
is similar to that foreta
.See the PlateHole and RubberPlateHole for canonical exmaples. The Integrator::Fracture and Integrator::TopOp integrators are examples of integrators that leverage the psi property.
Body forces currently have limited support due to the relatively low number of times they are needed. See the Integrator::Base::Mechanics documentation for detail. See the TrigTest test for examples of current body force implementation.
Boundary conditions are implemented using the BC::Operator::Elastic classes. See the documentation on these classes for more detail. See any of the mechanics-based tests for examples of boundary condition application.
Parameter |
Type |
Values |
---|---|---|
Number of elastic model varieties |
1 |
|
Refinement threshold for eta field |
0.01 |
|
Refinement threshold for strain gradient |
0.01 |
|
Explicity impose neumann condition on model at domain boundaries (2d only) |
false |
|
Select the initial condition for eta |
constant ellipse voronoi bmp png expression psread |
|
Whether to re-initialize eta when re-gridding occurs. Default is false unless eta ic is set, then default is. true. |
true |
|
Select initial condition for psi field |
ellipse constant expression psread png |
|
Whether to re-initialize psi when re-gridding occurs. Default is false unless a psi ic is set, then default is true. |
true |
|
Read in IC for the "normal traction" field (applied at diffuse boundaries) |
ellipse constant expression psread |
API definitions in src/Integrator/Mechanics.H
Classes
Integrator::Mechanics
Methods
Mechanics()
Mechanics(IO::ParmParse &pp)
~Mechanics()
Initialize(int lev) override
UpdateModel(int a_step, Set::Scalar time) override
TagCellsForRefinement(int lev, amrex::TagBoxArray &a_tags, Set::Scalar a_time, int a_ngrow) override
Regrid(int lev, Set::Scalar time) override
Variables
Set::Field<Set::Scalar> Integrator::Mechanics< MODEL >::eta_mf
Set::Scalar Integrator::Mechanics< MODEL >::m_eta_ref_threshold
std::vector<MODEL> Integrator::Mechanics< MODEL >::models
IC::IC<Set::Scalar>* Integrator::Mechanics< MODEL >::ic_eta
IC::IC<Set::Scalar>* Integrator::Mechanics< MODEL >::ic_psi
IC::IC<Set::Scalar>* Integrator::Mechanics< MODEL >::ic_trac_normal
BC::BC<Set::Scalar>* Integrator::Mechanics< MODEL >::bc_psi
BC::BC<Set::Scalar>* Integrator::Mechanics< MODEL >::bc_trac_normal
bool Integrator::Mechanics< MODEL >::psi_reset_on_regrid
bool Integrator::Mechanics< MODEL >::eta_reset_on_regrid
bool Integrator::Mechanics< MODEL >::model_neumann_boundary
Set::Field<Set::Scalar> Integrator::Mechanics< MODEL >::trac_normal_mf
Integrator::PFC
src/Integrator/PFC.cpp src/Integrator/PFC.H
Basic implementation of the phase field crystal model of Elder et al, 2002.
Free energy functional is:
Order parameter evolves with Cahn-Hilliard kinetics:
The variational derivative is
The semi-implicit spectral update is
Parameter |
Type |
Values |
---|---|---|
frequency term |
required |
|
chemical potential width |
required |
|
initial condition for \(\eta\) |
random |
|
boundary condition for \(\eta\) |
constant |
API definitions in src/Integrator/PFC.H
Classes
Integrator::PFC
Methods
PFC()
- Basic constructor (don’t use)~PFC()
- Destroy pointers defined in Parse.PFC(IO::ParmParse &pp)
- Use this constructor.Initialize(int lev) override
- values in fields.Advance(int lev, Set::Scalar time, Set::Scalar dt) override
- Integrate eta over one timestep on lev.TagCellsForRefinement(int lev, amrex::TagBoxArray &tags, amrex::Real time, int ngrow) override
- Mark any cells that need to be refined.
Variables
Set::Field<Set::Scalar> Integrator::PFC::eta_mf
Set::Field<Set::Scalar> Integrator::PFC::grad_chempot_mf
- Order parameter field.BC::BC<Set::Scalar>* Integrator::PFC::bc
- to calculate FFT of nonlinar part.IC::IC<Set::Scalar>* Integrator::PFC::ic
- eta’s bc objectSet::Scalar Integrator::PFC::q0
- eta’s ic objectSet::Scalar Integrator::PFC::eps
Integrator::PhaseFieldMicrostructure
src/Integrator/PhaseFieldMicrostructure.cpp src/Integrator/PhaseFieldMicrostructure.H
file PhaseFieldMicrostructure.H
Parameter |
Type |
Values |
---|---|---|
Number of grain fields (may be more if using different IC) |
2 |
|
Mobility |
required |
|
Phase field \(\gamma\) |
required |
|
Initial GB energy if not using anisotropy |
required |
|
Mobility |
required |
|
Determine whether to use elastic driving force |
false |
|
Multiplier of elastic energy |
1.0 |
|
Value used for thresholding kinetic relation |
0.0 |
|
Whether to include chemical potential in threshold |
false |
|
Whether to include boundary energy in threshold |
false |
|
Whether to include corner regularization in threshold |
false |
|
Whether to include lagrange multiplier in threshold |
false |
|
Whether to include mechanical driving force in threshold |
false |
|
Type of thresholding to use |
continuous chop |
|
Maximum AMR level |
required |
|
Phase field refinement threshold |
0.1 |
|
Reading this is redundant but necessary because of the way the code was originally structured (need to fix eventually) |
disable static dynamic |
|
Elasticity |
0.0 |
|
Mixing order |
1 2 |
|
Force Neumann BCs on the model |
false |
|
Lagrange multiplier method for enforcing volumes |
false |
|
Lagrange multiplier value |
required |
|
Prescribed volume |
required |
|
Lagrange multipler start time |
0.0 |
|
synthetic driving force (SDF) |
false |
|
value of SDF for each grain |
||
time to begin applying SDF |
0.0 |
|
Turn on |
false |
|
Regularization para m |
required |
|
Time to turn on anisotropy |
required |
|
Modify timestep when turned on |
required |
|
Modify plot_int when turned on |
-1 |
|
Modify plot_dt when turned on |
-1.0 |
|
Modify thermo int when turned on |
-1 |
|
Modify thermo plot int when turned on |
-1 |
|
Frequency of elastic calculation |
-1 |
|
Type of regularization to use |
k12 wilmore |
|
Type of GB to use |
abssin sin read sh |
|
Thermal fluctuations |
||
fluctuation amplitude |
||
fluctuation stadard deviation |
||
time to start applying fluctuation |
||
Disconnection generation |
||
Shear coupling matrices |
false |
|
Boundary condition for eta |
constant |
|
Initial condition for the order parameter eta |
constant perturbedinterface voronoi expression sphere ellipse random |
|
Anisotropic mobility |
0 |
|
simulation time when anisotropic kinetics is activated |
0.0 |
|
file containing anisotropic mobility data |
file path |
|
file containing anisotropic mobility data |
file path |
API definitions in src/Integrator/PhaseFieldMicrostructure.H
Classes
Integrator::PhaseFieldMicrostructure
- Solve the Allen-Cahn evolution equation for microstructure with parameters , where n corresponds to the number of grains.Methods
PhaseFieldMicrostructure()
PhaseFieldMicrostructure(IO::ParmParse &pp)
~PhaseFieldMicrostructure()
Advance(int lev, Real time, Real dt) override
- Evolve phase field in time.Initialize(int lev) override
TagCellsForRefinement(int lev, amrex::TagBoxArray &tags, amrex::Real time, int ngrow) override
TimeStepBegin(amrex::Real time, int iter) override
TimeStepComplete(amrex::Real time, int iter) override
Integrate(int amrlev, Set::Scalar time, int step, const amrex::MFIter &mfi, const amrex::Box &box) override
UpdateEigenstrain(int lev)
UpdateEigenstrain()
UpdateModel(int, Set::Scalar) override
Variables
const std::string Integrator::PhaseFieldMicrostructure< model_type >::name
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::M
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::L
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::mu
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::gamma
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::sigma0
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::l_gb
bool Integrator::PhaseFieldMicrostructure< model_type >::elastic_df
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::elastic_mult
bool Integrator::PhaseFieldMicrostructure< model_type >::on
bool Integrator::PhaseFieldMicrostructure< model_type >::chempot
bool Integrator::PhaseFieldMicrostructure< model_type >::boundary
bool Integrator::PhaseFieldMicrostructure< model_type >::corner
bool Integrator::PhaseFieldMicrostructure< model_type >::lagrange
bool Integrator::PhaseFieldMicrostructure< model_type >::mechanics
bool Integrator::PhaseFieldMicrostructure< model_type >::sdf
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::value
ThresholdType Integrator::PhaseFieldMicrostructure< model_type >::type
struct Integrator::PhaseFieldMicrostructure Integrator::PhaseFieldMicrostructure< model_type >::threshold
int Integrator::PhaseFieldMicrostructure< model_type >::on
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::tstart
Numeric::Interpolator::Linear<Set::Scalar> Integrator::PhaseFieldMicrostructure< model_type >::mobility
Numeric::Interpolator::Linear<Set::Scalar> Integrator::PhaseFieldMicrostructure< model_type >::threshold
Set::Field<Set::Scalar> Integrator::PhaseFieldMicrostructure< model_type >::L_mf
Set::Field<Set::Scalar> Integrator::PhaseFieldMicrostructure< model_type >::threshold_mf
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::beta
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::timestep
int Integrator::PhaseFieldMicrostructure< model_type >::plot_int
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::plot_dt
int Integrator::PhaseFieldMicrostructure< model_type >::thermo_int
int Integrator::PhaseFieldMicrostructure< model_type >::thermo_plot_int
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::theta0
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::sigma1
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::phi0
int Integrator::PhaseFieldMicrostructure< model_type >::elastic_int
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::vol0
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::lambda
std::vector<Numeric::Interpolator::Linear<Set::Scalar> > Integrator::PhaseFieldMicrostructure< model_type >::val
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::amp
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::sd
std::normal_distribution<double> Integrator::PhaseFieldMicrostructure< model_type >::norm_dist
std::default_random_engine Integrator::PhaseFieldMicrostructure< model_type >::rand_num_gen
Model::Defect::Disconnection Integrator::PhaseFieldMicrostructure< model_type >::model
std::vector<Set::Matrix> Integrator::PhaseFieldMicrostructure< model_type >::Fgb
std::vector<model_type> Integrator::PhaseFieldMicrostructure< model_type >::model
int Integrator::PhaseFieldMicrostructure< model_type >::model_mix_order
bool Integrator::PhaseFieldMicrostructure< model_type >::model_neumann_boundary
int Integrator::PhaseFieldMicrostructure< model_type >::number_of_grains
int Integrator::PhaseFieldMicrostructure< model_type >::number_of_ghost_cells
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::ref_threshold
Set::Field<Set::Scalar> Integrator::PhaseFieldMicrostructure< model_type >::eta_mf
Set::Field<Set::Scalar> Integrator::PhaseFieldMicrostructure< model_type >::eta_old_mf
Set::Field<Set::Scalar> Integrator::PhaseFieldMicrostructure< model_type >::driving_force_mf
Set::Field<Set::Scalar> Integrator::PhaseFieldMicrostructure< model_type >::driving_force_threshold_mf
Set::Field<Set::Scalar> Integrator::PhaseFieldMicrostructure< model_type >::fluct_mf
Set::Field<Set::Scalar> Integrator::PhaseFieldMicrostructure< model_type >::totaldf_mf
BC::BC<Set::Scalar>* Integrator::PhaseFieldMicrostructure< model_type >::mybc
RegularizationType Integrator::PhaseFieldMicrostructure< model_type >::regularization
struct Integrator::PhaseFieldMicrostructure Integrator::PhaseFieldMicrostructure< model_type >::pf
struct Integrator::PhaseFieldMicrostructure Integrator::PhaseFieldMicrostructure< model_type >::anisotropic_kinetics
struct Integrator::PhaseFieldMicrostructure Integrator::PhaseFieldMicrostructure< model_type >::anisotropy
struct Integrator::PhaseFieldMicrostructure Integrator::PhaseFieldMicrostructure< model_type >::lagrange
struct Integrator::PhaseFieldMicrostructure Integrator::PhaseFieldMicrostructure< model_type >::sdf
struct Integrator::PhaseFieldMicrostructure Integrator::PhaseFieldMicrostructure< model_type >::fluctuation
struct Integrator::PhaseFieldMicrostructure Integrator::PhaseFieldMicrostructure< model_type >::disconnection
struct Integrator::PhaseFieldMicrostructure Integrator::PhaseFieldMicrostructure< model_type >::shearcouple
std::string Integrator::PhaseFieldMicrostructure< model_type >::gb_type
std::string Integrator::PhaseFieldMicrostructure< model_type >::filename
Model::Interface::GB::GB* Integrator::PhaseFieldMicrostructure< model_type >::boundary
IC::IC<Set::Scalar>* Integrator::PhaseFieldMicrostructure< model_type >::ic
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::volume
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::area
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::gbenergy
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::realgbenergy
Set::Scalar Integrator::PhaseFieldMicrostructure< model_type >::regenergy
struct Integrator::PhaseFieldMicrostructure Integrator::PhaseFieldMicrostructure< model_type >::mechanics
Integrator::SFI
Parameter |
Type |
Values |
---|---|---|
time to activate hydro integrator |
0.0 |
|
If true, set hydro_eta to 1-pf_eta |
false |
API definitions in src/Integrator/SFI.H
Classes
Integrator::SutureCrack
Parameter |
Type |
Values |
---|---|---|
Crack type to use {notch} |
API definitions in src/Integrator/SutureCrack.H
Classes
Integrator::SutureCrack
Methods
SutureCrack()
Initialize(int ilev) override
TimeStepBegin(Set::Scalar, int iter) override
Advance(int lev, Set::Scalar, Set::Scalar dt) override
TagCellsForRefinement(int lev, amrex::TagBoxArray &a_tags, amrex::Real, int) override
Integrate(int amrlev, Set::Scalar, int, const amrex::MFIter &mfi, const amrex::Box &box)
TimeStepComplete(amrex::Real, int)
Variables
int Integrator::SutureCrack::number_of_ghost_nodes
- Number of ghost nodes.int Integrator::SutureCrack::number_of_materials
int Integrator::SutureCrack::nlevels
struct Integrator::SutureCrack Integrator::SutureCrack::elastic
struct Integrator::SutureCrack Integrator::SutureCrack::crack
struct Integrator::SutureCrack Integrator::SutureCrack::material
struct Integrator::SutureCrack Integrator::SutureCrack::sol
struct Integrator::SutureCrack Integrator::SutureCrack::loading
Set::Field<Set::Scalar> Integrator::SutureCrack::disp
- displacement fieldSet::Field<Set::Scalar> Integrator::SutureCrack::strain
- total strain field (gradient of displacement)Set::Field<Set::Scalar> Integrator::SutureCrack::stress
- stress fieldSet::Field<Set::Scalar> Integrator::SutureCrack::rhs
- rhs fab for elastic solutionSet::Field<Set::Scalar> Integrator::SutureCrack::residual
- residual field for solverSet::Field<Set::Scalar> Integrator::SutureCrack::energy
- total elastic energySet::Field<Set::Scalar> Integrator::SutureCrack::energy_pristine
- energy of the prisitne material as if no crack is presentSet::Field<Set::Scalar> Integrator::SutureCrack::energy_pristine_old
- energy of the pristine material for previous time step.BC::Operator::Elastic::Constant Integrator::SutureCrack::brittlebc
- elastic if using brittle fractureSet::Scalar Integrator::SutureCrack::df_mult
- mulitplier for elastic driving force.bool Integrator::SutureCrack::do_solve_now
Set::Field<Set::Scalar> Integrator::SutureCrack::field
- crack field at current time stepSet::Field<Set::Scalar> Integrator::SutureCrack::field_old
- crack field at previous time stepSet::Field<Set::Scalar> Integrator::SutureCrack::driving_force
- crack driving forces.Set::Scalar Integrator::SutureCrack::driving_force_reference
Set::Scalar Integrator::SutureCrack::driving_force_norm
Set::Scalar Integrator::SutureCrack::driving_force_tolerance_rel
Set::Scalar Integrator::SutureCrack::driving_force_tolerance_abs
Model::Interface::Crack::Crack* Integrator::SutureCrack::cracktype
- type of crack. See Crack/Constant or Crack/Sinstd::string Integrator::SutureCrack::ic_type
- crack type. See IC/Notch and IC/EllipsoidIC::IC* Integrator::SutureCrack::ic
- crack . See IC/Notch and IC/Ellipsoidbool Integrator::SutureCrack::is_ic
Set::Scalar Integrator::SutureCrack::scaleModulusMax
- material modulus ratio inside crack (default = 0.02).Set::Scalar Integrator::SutureCrack::refinement_threshold
Set::Scalar Integrator::SutureCrack::mult_df_Gc
- Multiplier for Gc/zeta term.Set::Scalar Integrator::SutureCrack::mult_df_lap
- Multiplier for the laplacian term.suture_fracture_model_type Integrator::SutureCrack::brittlemodeltype
Set::Field<Set::Scalar> Integrator::SutureCrack::modulus_field
Set::Field<suture_fracture_model_type> Integrator::SutureCrack::brittlemodel
std::string Integrator::SutureCrack::input_material
Set::Scalar Integrator::SutureCrack::bottom_tol
int Integrator::SutureCrack::interval
std::string Integrator::SutureCrack::type
int Integrator::SutureCrack::max_iter
int Integrator::SutureCrack::max_fmg_iter
int Integrator::SutureCrack::bottom_max_iter
int Integrator::SutureCrack::max_fixed_iter
int Integrator::SutureCrack::verbose
int Integrator::SutureCrack::cgverbose
Set::Scalar Integrator::SutureCrack::tol_rel
Set::Scalar Integrator::SutureCrack::tol_abs
Set::Scalar Integrator::SutureCrack::cg_tol_rel
Set::Scalar Integrator::SutureCrack::cg_tol_abs
Set::Scalar Integrator::SutureCrack::tstart
Set::Scalar Integrator::SutureCrack::tend
std::string Integrator::SutureCrack::bottom_solver
int Integrator::SutureCrack::linop_maxorder
bool Integrator::SutureCrack::use_fsmooth
int Integrator::SutureCrack::max_coarsening_level
bool Integrator::SutureCrack::agglomeration
bool Integrator::SutureCrack::consolidation
int Integrator::SutureCrack::pre_smooth
int Integrator::SutureCrack::post_smooth
Set::Vector Integrator::SutureCrack::body_force
Set::Scalar Integrator::SutureCrack::val
Integrator::TopOp
Parameter |
Type |
Values |
---|---|---|
Initial condition for psi field |
ellipse constant |
|
Refinement threshold based on eta |
0.01 |
|
\(\alpha\) parameter |
1.0 |
|
\(\beta\) parameter |
1.0 |
|
\(\gamma\) parameter |
1.0 |
|
Prescribed volume fraction |
0.5 |
|
Prescribed total vlume |
0.5 |
API definitions in src/Integrator/TopOp.H
Classes
Integrator::TopOp
Methods
TopOp()
TopOp(IO::ParmParse &pp)
~TopOp()
Initialize(int lev) override
UpdateModel(int a_step, Set::Scalar) override
Advance(int lev, Set::Scalar time, Set::Scalar dt) override
Integrate(int amrlev, Set::Scalar time, int step, const amrex::MFIter &mfi, const amrex::Box &box) override
TagCellsForRefinement(int lev, amrex::TagBoxArray &a_tags, Set::Scalar a_time, int a_ngrow) override
Variables
MODEL Integrator::TopOp< MODEL >::model
IC::IC<Set::Scalar>* Integrator::TopOp< MODEL >::ic_psi
BC::BC<Set::Scalar>* Integrator::TopOp< MODEL >::bc_psi
Set::Scalar Integrator::TopOp< MODEL >::m_eta_ref_threshold
Set::Field<Set::Scalar> Integrator::TopOp< MODEL >::psi_old_mf
Set::Scalar Integrator::TopOp< MODEL >::alpha
Set::Scalar Integrator::TopOp< MODEL >::beta
Set::Scalar Integrator::TopOp< MODEL >::gamma
Numeric::Interpolator::Linear<Set::Scalar> Integrator::TopOp< MODEL >::L
Set::Scalar Integrator::TopOp< MODEL >::volume0
Numeric::Interpolator::Linear<Set::Scalar> Integrator::TopOp< MODEL >::lambda
Set::Scalar Integrator::TopOp< MODEL >::volume
Set::Scalar Integrator::TopOp< MODEL >::w_chem_potential
Set::Scalar Integrator::TopOp< MODEL >::w_bndry
Set::Scalar Integrator::TopOp< MODEL >::w_elastic
Integrator::ThermoElastic
src/Integrator/ThermoElastic.H
Parameter |
Type |
Values |
---|---|---|
Diffusion coefficient |
API definitions in src/Integrator/ThermoElastic.H
Classes
Integrator::ThermoElastic
Methods
ThermoElastic()
~ThermoElastic()=default
ThermoElastic(IO::ParmParse &pp)
Initialize(int lev) override
UpdateModel(int a_step, Set::Scalar a_time) override
TimeStepBegin(Set::Scalar a_time, int a_step) override
Advance(int a_lev, amrex::Real a_time, amrex::Real a_dt) override
TagCellsForRefinement(int a_lev, amrex::TagBoxArray &a_tags, Set::Scalar a_time, int a_ngrow) override
Variables
std::vector<Set::Scalar> Integrator::ThermoElastic::alpha
Integrator::Base
Integrator::Base::Mechanics
src/Integrator/Base/Mechanics.H
Parameter |
Type |
Values |
---|---|---|
Type of mecahnics to use. Static: do full implicit solve. Dynamic: evolve dynamic equations with explicit dynamics Disable: do nothing. |
disable static dynamic |
|
Treat mechanics fields as changing in time. [false] You should use this if you care about other physics driven by the output of this integrator. |
false |
|
Include displacement field in output |
true |
|
Include right-hand side in output |
true |
|
Include \(\psi\) field in output |
true |
|
Include stress in output |
true |
|
Include strain in output |
true |
|
Dashpot damping (damps velocity) |
0.0 |
|
Newtonian viscous damping (damps velocity gradient) |
0.0 |
|
Initializer for RHS |
none expression |
|
Select the mechanical boundary conditions |
constant tensiontest expression |
|
Print out model variables (if enabled by model) |
false |
|
initial condition for right hand side (body force) |
constant expression trig |
|
Timestep interval for elastic solves (default - solve every time) |
0 |
|
Maximum multigrid coarsening level (default - none, maximum coarsening) |
-1 |
|
Whether to include residual output field |
false |
|
Whether to refine based on elastic solution |
0.01 |
|
Set this to true to zero out the displacement before each solve. (This is a temporary fix - we need to figure out why this is needed.) |
false |
|
Time to start doing the elastic solve (by default, start immediately) |
-1.0 |
API definitions in src/Integrator/Base/Mechanics.H
Classes
Integrator::Base::Mechanics
Methods
Mechanics()
~Mechanics()
Initialize(int lev) override
- Use the #ic object to initialize::Temp.UpdateModel(int a_step, Set::Scalar a_time)=0
TimeStepBegin(Set::Scalar a_time, int a_step) override
Advance(int lev, Set::Scalar time, Set::Scalar dt) override
Integrate(int amrlev, Set::Scalar, int, const amrex::MFIter &mfi, const amrex::Box &a_box) override
TagCellsForRefinement(int lev, amrex::TagBoxArray &a_tags, Set::Scalar, int) override
Variables
Set::Field<MODEL> Integrator::Base::Mechanics< MODEL >::model_mf
Set::Field<MATRIX4> Integrator::Base::Mechanics< MODEL >::ddw_mf
Set::Field<Set::Scalar> Integrator::Base::Mechanics< MODEL >::psi_mf
bool Integrator::Base::Mechanics< MODEL >::psi_on
int Integrator::Base::Mechanics< MODEL >::m_interval
Type Integrator::Base::Mechanics< MODEL >::m_type
Set::Field<Set::Vector> Integrator::Base::Mechanics< MODEL >::disp_mf
Set::Field<Set::Vector> Integrator::Base::Mechanics< MODEL >::rhs_mf
Set::Field<Set::Vector> Integrator::Base::Mechanics< MODEL >::res_mf
Set::Field<Set::Matrix> Integrator::Base::Mechanics< MODEL >::stress_mf
Set::Field<Set::Matrix> Integrator::Base::Mechanics< MODEL >::strain_mf
Set::Field<Set::Vector> Integrator::Base::Mechanics< MODEL >::disp_old_mf
Set::Field<Set::Vector> Integrator::Base::Mechanics< MODEL >::vel_mf
Set::Field<Set::Vector> Integrator::Base::Mechanics< MODEL >::vel_old_mf
Set::Scalar Integrator::Base::Mechanics< MODEL >::rho
Set::Scalar Integrator::Base::Mechanics< MODEL >::mu_dashpot
Set::Scalar Integrator::Base::Mechanics< MODEL >::mu_newton
Set::Vector Integrator::Base::Mechanics< MODEL >::trac_hi[AMREX_SPACEDIM]
Set::Vector Integrator::Base::Mechanics< MODEL >::disp_hi[AMREX_SPACEDIM]
IC::IC<Set::Vector>* Integrator::Base::Mechanics< MODEL >::ic_rhs
IC::IC<Set::Vector>* Integrator::Base::Mechanics< MODEL >::velocity_ic
Solver::Nonlocal::Newton<MODEL> Integrator::Base::Mechanics< MODEL >::solver
BC::Operator::Elastic::Elastic* Integrator::Base::Mechanics< MODEL >::bc
Set::Scalar Integrator::Base::Mechanics< MODEL >::m_elastic_ref_threshold
bool Integrator::Base::Mechanics< MODEL >::m_print_model
bool Integrator::Base::Mechanics< MODEL >::m_print_residual
bool Integrator::Base::Mechanics< MODEL >::m_time_evolving
int Integrator::Base::Mechanics< MODEL >::m_max_coarsening_level
bool Integrator::Base::Mechanics< MODEL >::m_zero_out_displacement
bool Integrator::Base::Mechanics< MODEL >::plot_disp
bool Integrator::Base::Mechanics< MODEL >::plot_stress
bool Integrator::Base::Mechanics< MODEL >::plot_strain
bool Integrator::Base::Mechanics< MODEL >::plot_psi
bool Integrator::Base::Mechanics< MODEL >::plot_rhs
Set::Scalar Integrator::Base::Mechanics< MODEL >::tstart
Model
Model::Model
In Alamo, any type of constitutive behavior is encapsulated in a “Model”. There is a broad range of model types, and so there is no abstract Model class. Rather, the base Model classes are stored in subsets of Model.
API definitions in src/Model/Model.H
Classes
Model::Defect
Model::Defect::Disconnection
src/Model/Defect/Disconnection.H
This simulates the creation of “disconnection pairs” at a GB by perturbing the order parameter \(\eta\) with a gaussian.
Disconnections can be nucleated randomly, or they can be added in a controlled way through the “fixed” option.
See the following reference for further details
Mahi Gokuli and Brandon Runnels. Multiphase field modeling of grain boundary migration mediated by emergent disconnections. Acta Materialia, 217:117149, 2021.
Parameter |
Type |
Values |
---|---|---|
time to start applying disconnections |
0.0 |
|
nucleation energy |
0.0 |
|
characteristic time |
1.0 |
|
temperature |
0.0 |
|
characteristic size |
0.0 |
|
interval between generation events |
required |
|
regularization epsilon |
1E-20 |
|
whether to manually specify disconnection nucleation points |
||
array of x locations |
||
array of y locations |
||
array of order parameter number |
||
time to appear |
||
verbosity |
false |
API definitions in src/Model/Defect/Disconnection.H
Classes
Model::Defect::Disconnection
Methods
Disconnection()
~Disconnection()
Nucleate(Set::Field< Set::Scalar > &eta_mf, std::vector< amrex::Geometry > &geom, Set::Scalar timestep, Set::Scalar time, int iter)
- This operates on an entire field, and manages all of the MPI communication necessary for consistent nucleation.
Variables
bool Model::Defect::Disconnection::verbose
Set::Scalar Model::Defect::Disconnection::tstart
Set::Scalar Model::Defect::Disconnection::nucleation_energy
Set::Scalar Model::Defect::Disconnection::tau_vol
Set::Scalar Model::Defect::Disconnection::temp
Set::Scalar Model::Defect::Disconnection::box_size
Set::Scalar Model::Defect::Disconnection::epsilon
int Model::Defect::Disconnection::interval
std::uniform_real_distribution<double> Model::Defect::Disconnection::unif_dist
std::uniform_int_distribution<int> Model::Defect::Disconnection::int_dist
- random number distribution for spatial locationstd::default_random_engine Model::Defect::Disconnection::rand_num_gen
- random number generator for phasestruct Model::Defect::Disconnection Model::Defect::Disconnection::fixed
- generator objectconst Set::Scalar Model::Defect::Disconnection::K_b
- list of nucleation site phases (up or down)int Model::Defect::Disconnection::on
std::vector< Set::Scalar > Model::Defect::Disconnection::sitex
std::vector< Set::Scalar > Model::Defect::Disconnection::sitey
- list of nucleation site x coordinatesstd::vector< int > Model::Defect::Disconnection::phases
- list of nucleation stie y coordinatesstd::vector<Set::Scalar> Model::Defect::Disconnection::time
std::vector<bool> Model::Defect::Disconnection::done
Model::Interface
Model::Interface::Crack
Model::Interface::Crack::Crack
src/Model/Interface/Crack/Crack.H
API definitions in src/Model/Interface/Crack/Crack.H
Classes
Model::Interface::Crack::Crack
Methods
Crack()
w_phi(Set::Scalar c, Set::Scalar)
g_phi(Set::Scalar c, Set::Scalar p=0.)
Dw_phi(Set::Scalar c, Set::Scalar)
Dg_phi(Set::Scalar c, Set::Scalar p=0.)
Gc(Set::Scalar theta)=0
DGc(Set::Scalar theta)=0
DDGc(Set::Scalar theta)=0
Zeta(Set::Scalar theta)=0
Mobility(Set::Scalar theta)=0
DrivingForceThreshold(Set::Scalar theta)=0
ExportToFile(std::string filename, amrex::Real dTheta)
SetGType(const GType a_type)
SetWType(const WType a_type)
SetDuctileExponent(const Set::Scalar m)
Variables
GType Model::Interface::Crack::Crack::g_type
WType Model::Interface::Crack::Crack::w_type
Set::Scalar Model::Interface::Crack::Crack::m_d_exponent
Model::Interface::Crack::Constant
src/Model/Interface/Crack/Constant.H
Parameter |
Type |
Values |
---|---|---|
Fracture energy |
||
Lengthscale regularization |
||
Mobility (speed) |
||
Threshold |
||
Type of g function to use {square, multiwell, 4c3, squarep, squarepexp, cubicm} |
||
Type o w function to use {square, multiwell, multiwell2, 4c3} |
API definitions in src/Model/Interface/Crack/Constant.H
Classes
Model::Interface::Crack::Constant
Methods
Constant()
Gc(Set::Scalar)
DGc(Set::Scalar)
DDGc(Set::Scalar)
Zeta(Set::Scalar)
Mobility(Set::Scalar)
DrivingForceThreshold(Set::Scalar)
Variables
Set::Scalar Model::Interface::Crack::Constant::_Gc
Set::Scalar Model::Interface::Crack::Constant::zeta
Set::Scalar Model::Interface::Crack::Constant::mobility
Set::Scalar Model::Interface::Crack::Constant::threshold
Model::Interface::Crack::Sin
src/Model/Interface/Crack/Sin.H
Parameter |
Type |
Values |
---|---|---|
Min Gc (fracture energy) value |
||
Max Gc (fracture energy)value |
||
Angle offset |
||
Regularization |
||
Crack mobiilty |
||
Threshold for kinetics |
||
Type of g function to use {square, multiwell, 4c3, squarep, squarepexp, cubicm} |
||
Type o w function to use {square, multiwell, multiwell2, 4c3} |
API definitions in src/Model/Interface/Crack/Sin.H
Classes
Model::Interface::Crack::Sin
Methods
Sin()
Gc(Set::Scalar theta)
DGc(Set::Scalar theta)
DDGc(Set::Scalar theta)
Zeta(Set::Scalar)
Mobility(Set::Scalar)
DrivingForceThreshold(Set::Scalar)
Variables
Set::Scalar Model::Interface::Crack::Sin::zeta
Set::Scalar Model::Interface::Crack::Sin::mobility
Set::Scalar Model::Interface::Crack::Sin::Gc0
Set::Scalar Model::Interface::Crack::Sin::Gc1
Set::Scalar Model::Interface::Crack::Sin::theta0
Set::Scalar Model::Interface::Crack::Sin::threshold
Model::Interface::GB
Model::Interface::GB::GB
API definitions in src/Model/Interface/GB/GB.H
Classes
Model::Interface::GB::GB
Methods
GB()
~GB()
W(const Set::Scalar theta) const =0
DW(const Set::Scalar theta) const =0
DDW(const Set::Scalar theta) const =0
W(const Set::Vector &a_n) const
DW(const Set::Vector &, const Set::Vector &) const
DDW(const Set::Vector &, const Set::Vector &) const
ExportToFile(std::string filename, amrex::Real dTheta)
DrivingForce(const Set::Vector &Deta, const Set::Matrix &DDeta, const Set::Matrix4< AMREX_SPACEDIM, Set::Sym::Full > &DDDDeta)
Variables
Regularization Model::Interface::GB::GB::regularization
Model::Interface::GB::AbsSin
src/Model/Interface/GB/AbsSin.H
Parameter |
Type |
Values |
---|---|---|
Angle offset (degrees) |
||
Minimum energy |
||
Energy multiplier |
API definitions in src/Model/Interface/GB/AbsSin.H
Classes
Model::Interface::GB::AbsSin
Methods
AbsSin()
AbsSin(IO::ParmParse &pp)
AbsSin(IO::ParmParse &pp, std::string name)
AbsSin(amrex::Real _theta0, amrex::Real _sigma0, amrex::Real _sigma1)
Define(amrex::Real _theta0, amrex::Real _sigma0, amrex::Real _sigma1)
Randomize()
W(const Set::Scalar theta) const
DW(const Set::Scalar theta) const
DDW(const Set::Scalar theta) const
Variables
Set::Scalar Model::Interface::GB::AbsSin::theta0
Set::Scalar Model::Interface::GB::AbsSin::sigma0
Set::Scalar Model::Interface::GB::AbsSin::sigma1
Model::Interface::GB::Read
Parameter |
Type |
Values |
---|---|---|
Filename containing GB data |
file path |
API definitions in src/Model/Interface/GB/Read.H
Classes
Model::Interface::GB::Read
- Reads the data from a file and computes energies and its derivates.Methods
Read()
- in data.Read(IO::ParmParse &pp)
Read(IO::ParmParse &pp, std::string name)
Read(std::string filename)
Define(std::string filename)
W(const Set::Scalar theta) const
DW(const Set::Scalar theta) const
DDW(const Set::Scalar theta) const
Variables
Numeric::Interpolator::Linear<Set::Scalar> Model::Interface::GB::Read::m_w
Numeric::Interpolator::Linear<Set::Scalar> Model::Interface::GB::Read::m_dw
Numeric::Interpolator::Linear<Set::Scalar> Model::Interface::GB::Read::m_ddw
Model::Interface::GB::SH
Parameter |
Type |
Values |
---|---|---|
Theta offset (degrees) |
||
Phi offset (radians) |
||
Minimum energy value |
||
Energy multiplier |
||
Type of regularization to use: {wilhelm,k23} |
API definitions in src/Model/Interface/GB/SH.H
Classes
Model::Interface::GB::SH
- A 2D interface model class.Methods
SH()
SH(IO::ParmParse &pp)
SH(IO::ParmParse &pp, std::string name)
SH(const amrex::Real a_theta0, const amrex::Real a_phi0, const amrex::Real a_sigma0, const amrex::Real a_sigma1)
Define(const amrex::Real a_theta0, const amrex::Real a_phi0, const amrex::Real a_sigma0, const amrex::Real a_sigma1)
Randomize()
W(const Set::Scalar a_theta, const Set::Scalar a_phi) const
DW(const Set::Scalar a_theta, const Set::Scalar a_phi) const
W(const Set::Vector &a_n) const override
DW(const Set::Vector &a_n, const Set::Vector &t_n) const override
DDW(const Set::Vector &a_n, const Set::Vector &t_n) const override
W(const Set::Scalar) const override
DW(const Set::Scalar) const override
DDW(const Set::Scalar) const override
Variables
Set::Scalar Model::Interface::GB::SH::theta0
Set::Scalar Model::Interface::GB::SH::phi0
Set::Scalar Model::Interface::GB::SH::sigma0
Set::Scalar Model::Interface::GB::SH::sigma1
Model::Interface::GB::Sin
Parameter |
Type |
Values |
---|---|---|
Theta offset (degrees) |
||
Minimum energy |
||
Energy multiplier |
||
Frequency number (integer) |
API definitions in src/Model/Interface/GB/Sin.H
Classes
Model::Interface::GB::Sin
Methods
Sin()
Sin(IO::ParmParse &pp)
Sin(IO::ParmParse &pp, std::string name)
Sin(amrex::Real _theta0, amrex::Real _sigma0, amrex::Real _sigma1)
Define(amrex::Real _theta0, amrex::Real _sigma0, amrex::Real _sigma1)
Randomize()
W(const Set::Scalar theta) const
DW(const Set::Scalar theta) const
DDW(const Set::Scalar theta) const
Variables
Set::Scalar Model::Interface::GB::Sin::theta0
Set::Scalar Model::Interface::GB::Sin::sigma0
Set::Scalar Model::Interface::GB::Sin::sigma1
Set::Scalar Model::Interface::GB::Sin::n
Model::Solid
Model::Solid::Solid
Solid models are used with the Integrator::Mechanics integrator, which
implements the Solver::Nonlocal::Newton elasticity solver.
All solid models inherit from the Model::Solid
base class, which requires
all of the necessary components to be used in a mechanics solve.
Model classes have basically two functions:
Provide energy (W), stress (DW), and modulus (DDW) based on a kinematic variable
Evolve internal variables in time.
API definitions in src/Model/Solid/Solid.H
Classes
Model::Solid::Solid
Methods
Solid()
~Solid()
W(const Set::Matrix &) const
DW(const Set::Matrix &) const
DDW(const Set::Matrix &) const
Advance(Set::Scalar, Set::Matrix, Set::Matrix, Set::Scalar)
ContainsNan()
Print(std::ostream &out) const
Model::Solid::ExtClassOperators
src/Model/Solid/ExtClassOperators.H
API definitions in src/Model/Solid/ExtClassOperators.H
Classes
Model::Solid::InClassOperators
src/Model/Solid/InClassOperators.H
API definitions in src/Model/Solid/InClassOperators.H
Classes
Model::Solid::Affine
Model::Solid::Affine::Affine
src/Model/Solid/Affine/Affine.H
“Affine” generally means “linear with an offset”. Here we use “affine” to refer to models that are elastic with an eigenstrain, i.e.
The quantity \(\varepsilon_0\) is any kind of eigenstrain - examples include thermal strain, plastic strain, or viscous strain. This class can be used directly, where the eigenstrain is read in or set by the integrator. There are also classes (particularly visco/plastic models) that inherit from this type of model.
API definitions in src/Model/Solid/Affine/Affine.H
Classes
Model::Solid::Affine::Affine
Methods
SetF0(Set::Matrix a_F0)
Variables
Set::Matrix4<AMREX_SPACEDIM,SYM> Model::Solid::Affine::Affine< SYM >::ddw
Set::Matrix Model::Solid::Affine::Affine< SYM >::F0
Model::Solid::Affine::Cubic
src/Model/Solid/Affine/Cubic.H
This class extends Model::Solid::Linear::Cubic by adding an eigenstrain \(\mathbf{F}_0\).
Parameter |
Type |
Values |
---|---|---|
Eigenstrain |
API definitions in src/Model/Solid/Affine/Cubic.H
Classes
Model::Solid::Affine::Cubic
Methods
Cubic()
Cubic(Linear::Cubic base)
~Cubic()
Define(Set::Scalar C11, Set::Scalar C12, Set::Scalar C44, Set::Scalar phi1, Set::Scalar Phi, Set::Scalar phi2, Set::Matrix a_F0=Set::Matrix::Zero())
Define(Set::Scalar C11, Set::Scalar C12, Set::Scalar C44, Eigen::Matrix3d R, Set::Matrix a_F0=Set::Matrix::Zero())
W(const Set::Matrix &gradu) const override
DW(const Set::Matrix &gradu) const override
DDW(const Set::Matrix &gradu) const override
Print(std::ostream &out) const override
SetF0(Set::Matrix &a_F0)
Variables
Set::Matrix Model::Solid::Affine::Cubic::F0
Model::Solid::Affine::Hexagonal
src/Model/Solid/Affine/Hexagonal.H
This model implements an affine hexagonal material:
where \(W_{aff}\) is the present model, \(\mathbf{F}_0\) is the eigenstrain, and \(W_{lin}\) is the cubic model defined in Model::Solid::Linear::Hexagonal.
Parameter |
Type |
Values |
---|---|---|
Eigenstrain matrix. Can be defined in 2D or 3D. |
API definitions in src/Model/Solid/Affine/Hexagonal.H
Classes
Model::Solid::Affine::Hexagonal
Methods
Hexagonal()
Hexagonal(Linear::Hexagonal base)
~Hexagonal()
Define(Set::Scalar C11, Set::Scalar C12, Set::Scalar C13, Set::Scalar C33, Set::Scalar C44, Set::Scalar phi1, Set::Scalar Phi, Set::Scalar phi2, Set::Matrix a_F0=Set::Matrix::Zero())
Define(Set::Scalar C11, Set::Scalar C12, Set::Scalar C13, Set::Scalar C33, Set::Scalar C44, Eigen::Matrix3d R, Set::Matrix a_F0=Set::Matrix::Zero())
W(const Set::Matrix &gradu) const override
DW(const Set::Matrix &gradu) const override
DDW(const Set::Matrix &gradu) const override
Print(std::ostream &out) const override
SetF0(Set::Matrix &a_F0)
Variables
Set::Matrix Model::Solid::Affine::Hexagonal::F0
Model::Solid::Affine::Isotropic
src/Model/Solid/Affine/Isotropic.H
Parameter |
Type |
Values |
---|---|---|
Eigendeformation gradient |
API definitions in src/Model/Solid/Affine/Isotropic.H
Classes
Model::Solid::Affine::Isotropic
Methods
Isotropic()
Isotropic(Affine< Set::Sym::Isotropic > base)
Isotropic(Set::Scalar a_mu, Set::Scalar a_lambda, Set::Matrix a_F0=Set::Matrix::Zero())
Define(Set::Scalar a_mu, Set::Scalar a_lambda, Set::Matrix a_F0)
Define(Set::Scalar a_mu, Set::Scalar a_lambda)
W(const Set::Matrix &F) const override
DW(const Set::Matrix &F) const override
DDW(const Set::Matrix &) const override
Print(std::ostream &out) const override
ContainsNan() override
Model::Solid::Affine::J2Plastic
src/Model/Solid/Affine/J2Plastic.H
Parameter |
Type |
Values |
---|---|---|
Lame constant |
||
Shear modulus |
||
Young's modulus |
||
Poisson's ratio |
||
Yield strength |
||
Hardening constant |
||
Hardening theta |
API definitions in src/Model/Solid/Affine/J2Plastic.H
Classes
Model::Solid::Affine::J2Plastic
Methods
J2Plastic()
J2Plastic(Solid< Set::Sym::Isotropic > base)
J2Plastic(Set::Scalar a_mu, Set::Scalar a_lambda, Set::Scalar a_yield, Set::Scalar a_hardening, Set::Scalar a_theta=1.0)
Define(Set::Scalar a_mu, Set::Scalar a_lambda, Set::Scalar a_yield, Set::Scalar a_hardening, Set::Scalar a_theta)
YieldSurface()
PlasticEnergy()
EvolvePlasticStrain(Set::Matrix sigma, Set::Matrix strain, Set::Scalar)
SetPlasticStrains()
SetPlasticStrains(PlasticState &a_state)
GetPlasticState()
operator+=(const J2Plastic &rhs)
operator*(const Set::Scalar alpha) const
Variables
PlasticState Model::Solid::Affine::J2Plastic::curr
PlasticState Model::Solid::Affine::J2Plastic::prev
Set::Scalar Model::Solid::Affine::J2Plastic::theta
Set::Scalar Model::Solid::Affine::J2Plastic::yield_strength
Set::Scalar Model::Solid::Affine::J2Plastic::hardening_modulus
Set::Scalar Model::Solid::Affine::J2Plastic::m_mu
Model::Solid::Affine::J2
This models an isotropic elastic-perfectly-plastic, non-time-dependent solid model.
The energy and derivatives are:
where \(\mathbb{C}\) is an isotropic Set::Matrix4
and \(\varepsilon_p\) is
is stored in the F0
eigenstrain.
The plastic strain is evolved according to the following:
Calculate the deviatoric stress \(\sigma_v=\sigma - \frac{1}{3}tr(\sigma)\mathbf{I}\)
Calculate \(J_2=\sqrt{\frac{3}{2}\sigma_v:\sigma_v}\)
If \(J_2<\sigma_0\) then quit - no plasticity occurs
Calculate \(\Delta\sigma = (1-\frac{\sigma_0}{J_2})\), which projects the stress back on the yield surface.
Convert to change in plastic strain, \(\Delta\varepsilon=\mathbb{C}^{-1}\Delta\sigma\)
Update plastic strain: \(\varepsilon_p += \Delta\varepsilon\)
Notes:
This does not implement any kind of hardening model. Rate hardening, isotropic hardening, and kinematic hardening have yet to be implemneted.
Parameter |
Type |
Values |
---|---|---|
J2 Yield criterion |
1.0 |
|
Hardening coefficient (negative value disables rate hardening) |
-1.0 |
|
Rate coefficient (negative value disables rate hardening) |
-1.0 |
API definitions in src/Model/Solid/Affine/J2.H
Classes
Model::Solid::Affine::J2
Methods
J2()
Advance(Set::Scalar dt, Set::Matrix eps, Set::Matrix, Set::Scalar) override
Variables
Set::Scalar Model::Solid::Affine::J2::sigma0
Set::Scalar Model::Solid::Affine::J2::hardening
Set::Scalar Model::Solid::Affine::J2::ratecoeff
Set::Scalar Model::Solid::Affine::J2::alpha
Model::Solid::Finite
Model::Solid::Finite::CrystalPlastic
src/Model/Solid/Finite/CrystalPlastic.H
A basic and relatively untested implementation of finite-deformation FCC crystal plasticity. Use with caution.
Inherits from Model::Solid::Finite::PseudoLinear::Cubic to provide elastic response.
Plastic flow modeled as:
where \(\mathbf{F}=\mathbf{F}^e\mathbf{F}^p\) and \(\gamma_n\) are slips on system \(n\).
Power law rate hardening is used in the integration of slips:
Parameter |
Type |
Values |
---|---|---|
Critical resolved shear stress \(\tau_{crss}\) |
||
Rate hardening coefficient \(\dot{\gamma}_0\) |
1.0 |
|
Inverse of the hardening exponent \(\frac{1}{m}\) |
0.5 |
|
Time to activate plastic slip |
0.0 |
API definitions in src/Model/Solid/Finite/CrystalPlastic.H
Classes
Model::Solid::Finite::CrystalPlastic
Methods
CrystalPlastic()
~CrystalPlastic()
W(const Set::Matrix &F) const override
DW(const Set::Matrix &F) const override
DDW(const Set::Matrix &F) const override
Advance(Set::Scalar dt, Set::Matrix, Set::Matrix P, Set::Scalar time) override
Variables
Set::Matrix3d Model::Solid::Finite::CrystalPlastic::Fp
Eigen::Matrix<Set::Scalar,12,1> Model::Solid::Finite::CrystalPlastic::gamma
Set::Scalar Model::Solid::Finite::CrystalPlastic::m_rate_inv
Eigen::Matrix<Set::Scalar,12,1> Model::Solid::Finite::CrystalPlastic::tau_crss
Set::Scalar Model::Solid::Finite::CrystalPlastic::gammadot0
Set::Scalar Model::Solid::Finite::CrystalPlastic::tstart
Model::Solid::Finite::NeoHookeanPredeformed
src/Model/Solid/Finite/NeoHookeanPredeformed.H
Parameter |
Type |
Values |
---|---|---|
Large-deformation eigendeformation (Identity = no deformation) |
||
Small-deformation eigendeformation (Zero = no deformation) |
API definitions in src/Model/Solid/Finite/NeoHookeanPredeformed.H
Classes
Model::Solid::Finite::NeoHookeanPredeformed
Methods
NeoHookeanPredeformed()
NeoHookeanPredeformed(NeoHookean base)
~NeoHookeanPredeformed()
W(const Set::Matrix &F) const override
DW(const Set::Matrix &F) const override
DDW(const Set::Matrix &F) const override
Print(std::ostream &out) const override
Variables
Set::Matrix Model::Solid::Finite::NeoHookeanPredeformed::F0
Model::Solid::Finite::NeoHookean
src/Model/Solid/Finite/NeoHookean.H
Parameter |
Type |
Values |
---|
API definitions in src/Model/Solid/Finite/NeoHookean.H
Classes
Model::Solid::Finite::NeoHookean
Methods
NeoHookean()
NeoHookean(Solid< Set::Sym::Major > base)
~NeoHookean()
W(const Set::Matrix &a_F) const override
DW(const Set::Matrix &a_F) const override
DDW(const Set::Matrix &a_F) const override
Print(std::ostream &out) const override
Variables
Set::Scalar Model::Solid::Finite::NeoHookean::mu
Set::Scalar Model::Solid::Finite::NeoHookean::kappa
Model::Solid::Finite::PseudoAffine
Model::Solid::Finite::PseudoAffine::Cubic
src/Model/Solid/Finite/PseudoAffine/Cubic.H
Parameter |
Type |
Values |
---|---|---|
Large-strain eigendeformation (Identity = no deformation) |
||
Small-strain eigendeformation (Zero = no deformation) |
API definitions in src/Model/Solid/Finite/PseudoAffine/Cubic.H
Classes
Model::Solid::Finite::PseudoAffine::Cubic
Methods
Cubic()
Cubic(PseudoLinear::Cubic base)
~Cubic()
W(const Set::Matrix &F) const override
DW(const Set::Matrix &F) const override
DDW(const Set::Matrix &F) const override
Variables
Set::Matrix Model::Solid::Finite::PseudoAffine::Cubic::F0
Model::Solid::Finite::PseudoLinear
Model::Solid::Finite::PseudoLinear::Cubic
src/Model/Solid/Finite/PseudoLinear/Cubic.H
Parameter |
Type |
Values |
---|---|---|
Elastic constant |
1.68 |
|
Elastic constant |
1.21 |
|
Elastic constant |
0.75 |
|
Bunge Euler angle \(\phi_1\) |
0.0 |
|
Bunge Euler angle \(\Phi\) |
0.0 |
|
Bunge Euler angle \(\phi_2\) |
0.0 |
API definitions in src/Model/Solid/Finite/PseudoLinear/Cubic.H
Classes
Model::Solid::Finite::PseudoLinear::Cubic
Methods
Cubic()
~Cubic()
W(const Set::Matrix &F) const override
DW(const Set::Matrix &F) const override
DDW(const Set::Matrix &F) const override
Print(std::ostream &out) const override
Variables
Set::Scalar Model::Solid::Finite::PseudoLinear::Cubic::C11
Set::Scalar Model::Solid::Finite::PseudoLinear::Cubic::C12
Set::Scalar Model::Solid::Finite::PseudoLinear::Cubic::C44
Set::Quaternion Model::Solid::Finite::PseudoLinear::Cubic::q
Model::Solid::Linear
Model::Solid::Linear::Cubic
src/Model/Solid/Linear/Cubic.H
This class implements basic cubic elasticity. For a discussion on cubic elasticity, please see this link.
Parameter |
Type |
Values |
---|---|---|
Elastic constant |
1.68 |
|
Elastic constant |
1.21 |
|
Elastic constant |
0.75 |
|
specify whether using radians or degrees |
radians degrees |
|
Bunge Euler angle \(\phi_1\) about x axis |
0.0 |
|
Bunge Euler angle \(\Phi\) about z axis |
0.0 |
|
Bunge Euler angle \(\phi_2\) about x axis |
0.0 |
API definitions in src/Model/Solid/Linear/Cubic.H
Classes
Model::Solid::Linear::Cubic
Methods
Cubic()
Cubic(Solid< Set::Sym::MajorMinor > base)
~Cubic()
Define(Set::Scalar C11, Set::Scalar C12, Set::Scalar C44, Set::Scalar phi1, Set::Scalar Phi, Set::Scalar phi2)
Define(Set::Scalar C11, Set::Scalar C12, Set::Scalar C44, Eigen::Matrix3d R)
W(const Set::Matrix &gradu) const override
DW(const Set::Matrix &gradu) const override
DDW(const Set::Matrix &) const override
Print(std::ostream &out) const override
Variables
Set::Matrix4<AMREX_SPACEDIM,Set::Sym::MajorMinor> Model::Solid::Linear::Cubic::ddw
Model::Solid::Linear::Hexagonal
src/Model/Solid/Linear/Hexagonal.H
This class implements elasticity for a linear material with hexagonal symmetry. The elastic modulus tensor \(\mathbb{C}\) has major and minor symmetry but not cubic symmetry, so the symmetry class for this material is MajorMinor The five elastic constants in the unrotated system are \(C_{11},C_{12},C_{13},C_{33},C_{44}\), and the resulting elastic modulus tensor is
Rotations can be specified using Bunge euler angles to generate a rotation matrix \(\mathbf{R}\). The rotated modulus tensor \(\mathbb{C}^{rot}\) is then
Parameter |
Type |
Values |
---|---|---|
Elastic constant |
required |
|
Elastic constant |
required |
|
Elastic constant |
required |
|
Elastic constant |
required |
|
Elastic constant |
required |
|
Bunge Euler angle \(\phi_1\) |
0.0 |
|
Bunge Euler angle \(\Phi\) |
0.0 |
|
Bunge Euler angle \(\phi_2\) |
0.0 |
API definitions in src/Model/Solid/Linear/Hexagonal.H
Classes
Model::Solid::Linear::Hexagonal
Methods
Hexagonal()
Hexagonal(Solid< Set::Sym::MajorMinor > base)
~Hexagonal()
Define(Set::Scalar C11, Set::Scalar C12, Set::Scalar C13, Set::Scalar C33, Set::Scalar C44, Set::Scalar phi1, Set::Scalar Phi, Set::Scalar phi2)
Define(Set::Scalar C11, Set::Scalar C12, Set::Scalar C13, Set::Scalar C33, Set::Scalar C44, Eigen::Matrix3d R)
W(const Set::Matrix &gradu) const override
DW(const Set::Matrix &gradu) const override
DDW(const Set::Matrix &) const override
Print(std::ostream &out) const override
Variables
Set::Matrix4<AMREX_SPACEDIM,Set::Sym::MajorMinor> Model::Solid::Linear::Hexagonal::ddw
Model::Solid::Linear::Isotropic
src/Model/Solid/Linear/Isotropic.H
This model implements an isotropic linear elastic material. See this link for more information about the theory.
Free energy for a linear material is defined as
For an isotropic material, stress and strain are related through
where \(\lambda\) and \(\mu\) are the Lame constant and shear modulus, respectively.
Users can specify these either through (lame
and shear
)
OR (lambda
and mu
) OR (E
and nu
).
Class methods:
Isotropic()
: Basic constructor. Does nothing, and leaves all values initiated as NAN.Isotropic(Solid<Set::Sym::Isotropic> base)
Basic constructor. Does nothing gut allows for inheritance.Isotropic(Set::Scalar a_mu, Set::Scalar a_lambda)
BAD old-fashioned constructor. Do not use!~Isotropic()
Simple destructor. Don’t need to change it.void Define(Set::Scalar a_mu, Set::Scalar a_lambda)
BAD old-fashioned way of doing things. UseParse
instead.Set::Scalar W(const Set::Matrix & gradu) const override
Returns elastic free energy densitySet::Matrix DW(const Set::Matrix & gradu) const override
Returns first derivative of free energy, the stress tensorSet::Matrix4<...> DDW(const Set::Matrix & ) const override
Returns second derivative of free energy, the modulus tensorvirtual void Print(std::ostream &out) const override
Prints the modulus tensor object to output stream (usually the terminal)static Isotropic Random()
Static method that generates a random yet acceptable model.static Isotropic Zero()
Static method that generates a “zero” element (so that there is no effect under addition)static void Parse(Isotropic & value, IO::ParmParse & pp)
Parser where all the IO occurs
Parameter |
Type |
Values |
---|---|---|
Whether or not to use the `plane stress |
false |
API definitions in src/Model/Solid/Linear/Isotropic.H
Classes
Model::Solid::Linear::Isotropic
Methods
Isotropic()
Isotropic(Solid< Set::Sym::Isotropic > base)
Isotropic(Set::Scalar a_mu, Set::Scalar a_lambda)
~Isotropic()
Define(Set::Scalar a_mu, Set::Scalar a_lambda)
W(const Set::Matrix &gradu) const override
DW(const Set::Matrix &gradu) const override
DDW(const Set::Matrix &) const override
Print(std::ostream &out) const override
Variables
Set::Matrix4<AMREX_SPACEDIM,Set::Sym::Isotropic> Model::Solid::Linear::Isotropic::ddw
Model::Solid::Linear::Laplacian
src/Model/Solid/Linear/Laplacian.H
Parameter |
Type |
Values |
---|---|---|
Coefficient for the Laplacian |
1.0 |
API definitions in src/Model/Solid/Linear/Laplacian.H
Classes
Model::Solid::Linear::Laplacian
- implements the following elastic model.Methods
Laplacian()
Laplacian(Set::Scalar alpha)
Laplacian(Solid< Set::Sym::Diagonal > base)
~Laplacian()
Define(Set::Scalar alpha=1.0)
W(const Set::Matrix &gradu) const override
DW(const Set::Matrix &gradu) const override
DDW(const Set::Matrix &) const override
Variables
Set::Matrix4<AMREX_SPACEDIM,Set::Sym::Diagonal> Model::Solid::Linear::Laplacian::ddw
Numeric
Numeric::Function
API definitions in src/Numeric/Function.H
Classes
Numeric::Function::Polynomial
Numeric::Function::Polynomial< 3 >
Methods
Polynomial(Set::Scalar a0, Set::Scalar a1, Set::Scalar a2, Set::Scalar a3)
operator()(const Set::Scalar x) const
Variables
std::array<Set::Scalar, 4> Numeric::Function::Polynomial< 3 >::a
Numeric::Function::Polynomial< 4 >
Methods
Polynomial(Set::Scalar a0, Set::Scalar a1, Set::Scalar a2, Set::Scalar a3, Set::Scalar a4)
operator()(const Set::Scalar x) const
D() const
Variables
std::array<Set::Scalar, 5> Numeric::Function::Polynomial< 4 >::a
Numeric::Stencil
API definitions in src/Numeric/Stencil.H
Classes
Numeric::Interpolate
Numeric::Stencil
Numeric::Stencil< T, 0, 0, 1 >
Numeric::Stencil< T, 0, 0, 2 >
Numeric::Stencil< T, 0, 0, 4 >
Numeric::Stencil< T, 0, 1, 0 >
Numeric::Stencil< T, 0, 1, 1 >
Numeric::Stencil< T, 0, 1, 3 >
- Compute.Numeric::Stencil< T, 0, 2, 0 >
Numeric::Stencil< T, 0, 2, 2 >
- Compute.Numeric::Stencil< T, 0, 3, 1 >
- Compute.Numeric::Stencil< T, 0, 4, 0 >
Numeric::Stencil< T, 1, 0, 0 >
Numeric::Stencil< T, 1, 0, 1 >
Numeric::Stencil< T, 1, 0, 3 >
- Compute.Numeric::Stencil< T, 1, 1, 0 >
Numeric::Stencil< T, 1, 1, 2 >
- Compute.Numeric::Stencil< T, 1, 2, 1 >
- Compute.Numeric::Stencil< T, 1, 3, 0 >
- Compute.Numeric::Stencil< T, 2, 0, 0 >
Numeric::Stencil< T, 2, 0, 2 >
- Compute.Numeric::Stencil< T, 2, 1, 1 >
- Compute.Numeric::Stencil< T, 2, 2, 0 >
- Compute.Numeric::Stencil< T, 3, 0, 1 >
- Compute.Numeric::Stencil< T, 3, 1, 0 >
- Compute.Numeric::Stencil< T, 4, 0, 0 >
Numeric::Interpolator
Numeric::Interpolator::Interpolator
src/Numeric/Interpolator/Interpolator.H
This namespace has evolved to contain some general Interpolator routines that are actually unrelated. The Numeric::Interpolator::Linear is an I/O utility. The Numeric::Interpolator::NodeBilinear is a low-level AMReX override that the average user (or even coder) will probably not need to touch.
API definitions in src/Numeric/Interpolator/Interpolator.H
Classes
Numeric::Interpolator::Interpolator
Methods
Interpolator()
Numeric::Interpolator::Linear
src/Numeric/Interpolator/Linear.H
This is a general-purpose routine for specifying time-interpolated quantities in an input file. Interpolators obey the following syntax:
(t1,t2,..,tn;v1,v2,...,vn)
where tn
are times and vn
are values at those times.
Note: do not include whitespace in an interpolator, this will mess with the parser.
Interpolators can usually be used in place of regular numbers, but only when supported by the calling parse function.
For instance, the BC::Operator::Elastic::TensionTest allows the user to specify fixed displacement; for instance, to specify a value of 0.1:
bc.tenstion_test.disp = 0.1
However, it may be desirable to change the value over time. In this case, one may specify an interpolator string instead:
bc.tenstion_test.disp = (1.0,1.5,2.0;0.0,0.1,0.0)
This will cause the displacement value to be zero for t<1.0
;
ramp to 0.1
as 1.0<t<2.0
;
ramp back to 0.0
as 2.0<t<3.0
;
and then remain at the constant value of 3.0
for t>3.0
.
Parameter |
Type |
Values |
---|---|---|
Interpolator string used when Parsed from queryclass. |
API definitions in src/Numeric/Interpolator/Linear.H
Classes
Numeric::Interpolator::Linear
Methods
Linear()
~Linear()
Linear(const Set::Scalar &a_val)
Linear(const std::string a_str)
Linear(const std::vector< T > _data_points, const std::vector< Set::Scalar > _interval_points)
define(const std::string a_str)
define(const std::vector< T > _data_points, const std::vector< Set::Scalar > _interval_points)
operator()(const Set::Scalar point) const
Read(std::string filename, int derivative)
Variables
std::vector<T> Numeric::Interpolator::Linear< T >::data_points
std::vector<Set::Scalar> Numeric::Interpolator::Linear< T >::interval_points
bool Numeric::Interpolator::Linear< T >::uniform
Numeric::Interpolator::NodeBilinear
src/Numeric/Interpolator/NodeBilinear.H
Provide an interpolator function that can work with templated fields.
Warning: This is a low-level class used to add templating functionality to unerlying AMReX classes. Edit at your own risk!
API definitions in src/Numeric/Interpolator/NodeBilinear.H
Classes
Numeric::Interpolator::NodeBilinear
Methods
interp(const amrex::BaseFab< T > &crse, int crse_comp, amrex::BaseFab< T > &fine, int fine_comp, int ncomp, const amrex::Box &fine_region, const amrex::IntVect &ratio, const amrex::Geometry &, const amrex::Geometry &, amrex::Vector< amrex::BCRec > const &, int, int, amrex::RunOn runon)
interp_face(const amrex::BaseFab< T > &, const int, amrex::BaseFab< T > &, const int, const int, const amrex::Box &, const amrex::IntVect &, const amrex::IArrayBox &, const amrex::Geometry &, const amrex::Geometry &, amrex::Vector< amrex::BCRec > const &, const int, amrex::RunOn)
Numeric::Interpolator::Test
src/Numeric/Interpolator/Test.cpp src/Numeric/Interpolator/Test.H
API definitions in src/Numeric/Interpolator/Test.H
Classes
Numeric::Interpolator::Test
Methods
Match(int)
Match(int verbose)
Operator
Operator::Operator
src/Operator/Operator.cpp src/Operator/Operator.H
API definitions in src/Operator/Operator.H
Classes
Operator::Operator
Operator::Operator< Grid::Cell >
Methods
Operator()
~Operator()
Operator(const Operator &)=delete
Operator(Operator &&)=delete
operator=(const Operator &)=delete
operator=(Operator &&)=delete
define(amrex::Vector< amrex::Geometry > a_geom, const amrex::Vector< amrex::BoxArray > &a_grids, const amrex::Vector< amrex::DistributionMapping > &a_dmap, BC::BC< Set::Scalar > &a_bc, const amrex::LPInfo &a_info=amrex::LPInfo(), const amrex::Vector< amrex::FabFactory< amrex::FArrayBox > const * > &a_factory={})
updateSolBC(int amrlev, const amrex::MultiFab &crse_bcdata) const
updateCorBC(int amrlev, const amrex::MultiFab &crse_bcdata) const
prepareForSolve() override
Fapply(int amrlev, int mglev, amrex::MultiFab &out, const amrex::MultiFab &in) const override=0
Fsmooth(int amrlev, int mglev, amrex::MultiFab &sol, const amrex::MultiFab &rsh, int redblack) const override=0
FFlux(int amrlev, const MFIter &mfi, const Array< FArrayBox *, AMREX_SPACEDIM > &flux, const FArrayBox &sol, Location loc, const int face_only=0) const override=0
RegisterNewFab(amrex::Vector< amrex::MultiFab > &input)
RegisterNewFab(amrex::Vector< std::unique_ptr< amrex::MultiFab > > &input)
GetFab(const int num, const int amrlev, const int mglev, const amrex::MFIter &mfi)
isSingular(int) const final
isBottomSingular() const final
getAScalar() const final
getBScalar() const final
getACoeffs(int, int) const final
getBCoeffs(int, int) const final
makeNLinOp(int) const final
averageDownCoeffs()
averageDownCoeffsSameAmrLevel(amrex::Vector< amrex::MultiFab > &)
GetFab(const int num, const int amrlev, const int mglev, const amrex::MFIter &mfi) const
Variables
BC::BC<Set::Scalar>* Operator::Operator< Grid::Cell >::m_bc
amrex::Vector<std::unique_ptr<amrex::MLMGBndry> > Operator::Operator< Grid::Cell >::m_bndry_sol
amrex::Vector<std::unique_ptr<amrex::BndryRegister> > Operator::Operator< Grid::Cell >::m_crse_sol_br
amrex::Vector<std::unique_ptr<amrex::MLMGBndry> > Operator::Operator< Grid::Cell >::m_bndry_cor
amrex::Vector<std::unique_ptr<amrex::BndryRegister> > Operator::Operator< Grid::Cell >::m_crse_cor_br
amrex::Vector<amrex::Vector<std::unique_ptr<BndryCondLoc> > > Operator::Operator< Grid::Cell >::m_bcondloc
amrex::Vector<amrex::Vector<amrex::BndryRegister> > Operator::Operator< Grid::Cell >::m_undrrelxr
amrex::Vector<amrex::Vector<std::array<amrex::MultiMask,2*AMREX_SPACEDIM> > > Operator::Operator< Grid::Cell >::m_maskvals
int Operator::Operator< Grid::Cell >::m_num_a_fabs
amrex::Vector<amrex::Vector<amrex::Vector<amrex::MultiFab> > > Operator::Operator< Grid::Cell >::m_a_coeffs
Operator::Operator< Grid::Cell >::BndryCondLoc
Methods
BndryCondLoc(const amrex::BoxArray &ba, const amrex::DistributionMapping &dm)
setLOBndryConds(const amrex::Geometry &geom, const amrex::Real *dx, const amrex::Array< BCType, AMREX_SPACEDIM > &lobc, const amrex::Array< BCType, AMREX_SPACEDIM > &hibc, int ratio, const amrex::RealVect &a_loc)
bndryConds(const amrex::MFIter &mfi) const
bndryLocs(const amrex::MFIter &mfi) const
Variables
amrex::LayoutData<BCTuple> Operator::Operator< Grid::Cell >::BndryCondLoc::bcond
amrex::LayoutData<RealTuple> Operator::Operator< Grid::Cell >::BndryCondLoc::bcloc
Operator::Operator< Grid::Node >
Methods
Operator()
Operator(const amrex::Vector< amrex::Geometry > &a_geom, const amrex::Vector< amrex::BoxArray > &a_grids, const Vector< DistributionMapping > &a_dmap, const LPInfo &a_info=LPInfo(), const Vector< FabFactory< FArrayBox > const * > &a_factory={})
~Operator()
Operator(const Operator &)=delete
Operator(Operator &&)=delete
operator=(const Operator &)=delete
operator=(Operator &&)=delete
define(const Vector< Geometry > &a_geom, const Vector< BoxArray > &a_grids, const Vector< DistributionMapping > &a_dmap, const LPInfo &a_info=LPInfo(), const Vector< FabFactory< FArrayBox > const * > &a_factory={})
Geom(int amr_lev, int mglev=0) const noexcept
Reflux(int crse_amrlev, MultiFab &res, const MultiFab &crse_sol, const MultiFab &crse_rhs, MultiFab &fine_res, MultiFab &fine_sol, const MultiFab &fine_rhs)
Apply(int amrlev, int mglev, MultiFab &out, const MultiFab &in) const
SetOmega(Set::Scalar a_omega)
SetAverageDownCoeffs(bool)
SetNormalizeDDW(bool a_normalize_ddw)
RegisterNewFab(amrex::Vector< amrex::MultiFab > &input)
RegisterNewFab(amrex::Vector< std::unique_ptr< amrex::MultiFab > > &input)
GetFab(const int num, const int amrlev, const int mglev, const amrex::MFIter &mfi) const
SetHomogeneous(bool)
getNGrow(int=0, int=0) const override final
solutionResidual(int amrlev, MultiFab &resid, MultiFab &x, const MultiFab &b, const MultiFab *crse_bcdata=nullptr) override final
correctionResidual(int amrlev, int mglev, MultiFab &resid, MultiFab &x, const MultiFab &b, BCMode bc_mode, const MultiFab *crse_bcdata=nullptr) override final
Fapply(int amrlev, int mglev, MultiFab &out, const MultiFab &in) const override=0
averageDownCoeffs()=0
Diagonal(bool recompute=false)
Diagonal(int amrlev, int mglev, amrex::MultiFab &diag)
Fsmooth(int amrlev, int mglev, MultiFab &x, const MultiFab &b) const override
normalize(int amrlev, int mglev, MultiFab &mf) const override
reflux(int crse_amrlev, MultiFab &res, const MultiFab &crse_sol, const MultiFab &crse_rhs, MultiFab &fine_res, MultiFab &fine_sol, const MultiFab &fine_rhs) const override
restriction(int amrlev, int cmglev, MultiFab &crse, MultiFab &fine) const final
interpolation(int amrlev, int fmglev, MultiFab &fine, const MultiFab &crse) const override final
averageDownSolutionRHS(int camrlev, MultiFab &crse_sol, MultiFab &crse_rhs, const MultiFab &fine_sol, const MultiFab &fine_rhs) final
prepareForSolve() override
isSingular(int amrlev) const final
isBottomSingular() const final
applyBC(int amrlev, int mglev, MultiFab &phi, BCMode bc_mode, amrex::MLLinOp::StateMode, bool skip_fillboundary=false) const final
fixUpResidualMask(int amrlev, iMultiFab &resmsk) final
Variables
bool Operator::Operator< Grid::Node >::m_is_bottom_singular
bool Operator::Operator< Grid::Node >::m_masks_built
int Operator::Operator< Grid::Node >::m_num_a_fabs
bool Operator::Operator< Grid::Node >::m_diagonal_computed
amrex::Vector<amrex::Vector<amrex::Vector<amrex::MultiFab> > > Operator::Operator< Grid::Node >::m_a_coeffs
amrex::Vector<amrex::Vector<std::unique_ptr<amrex::MultiFab> > > Operator::Operator< Grid::Node >::m_diag
Set::Scalar Operator::Operator< Grid::Node >::m_omega
bool Operator::Operator< Grid::Node >::m_normalize_ddw
Operator::Diagonal
src/Operator/Diagonal.cpp src/Operator/Diagonal.H
API definitions in src/Operator/Diagonal.H
Classes
Operator::Diagonal
Methods
Diagonal()
Diagonal(const Vector< Geometry > &a_geom, const Vector< BoxArray > &a_grids, const Vector< DistributionMapping > &a_dmap, const LPInfo &a_info)
~Diagonal()
Diagonal(const Diagonal &)=delete
Diagonal(Diagonal &&)=delete
operator=(const Diagonal &)=delete
operator=(Diagonal &&)=delete
Fapply(int amrlev, int mglev, MultiFab &out, const MultiFab &in) const override final
Fsmooth(int amrlev, int mglev, MultiFab &sol, const MultiFab &rsh) const override final
getNComp() const override
normalize(int, int, MultiFab &) const override final
reflux(int, MultiFab &, const MultiFab &, const MultiFab &, MultiFab &, MultiFab &, const MultiFab &) const override
Operator::Elastic
src/Operator/Elastic.cpp src/Operator/Elastic.H
Parameter |
Type |
Values |
---|---|---|
Regularization offset value used in near-singular elastic solves. It should be small - if it is too large, you will get better convergence but less correct values! |
API definitions in src/Operator/Elastic.H
Classes
Operator::Elastic
Methods
Elastic()
Elastic(const Vector< Geometry > &a_geom, const Vector< BoxArray > &a_grids, const Vector< DistributionMapping > &a_dmap, const LPInfo &a_info)
~Elastic()
Elastic(const Elastic &)=delete
Elastic(Elastic &&)=delete
operator=(const Elastic &)=delete
operator=(Elastic &&)=delete
define(const Vector< Geometry > &a_geom, const Vector< BoxArray > &a_grids, const Vector< DistributionMapping > &a_dmap, const LPInfo &a_info=LPInfo(), const Vector< FabFactory< FArrayBox > const * > &a_factory={})
SetHomogeneous(bool a_homogeneous) override
SetModel(Set::Matrix4< AMREX_SPACEDIM, SYM > &a_model)
SetModel(int amrlev, const MultiTab &a_model)
SetModel(const amrex::Vector< MultiTab > &a_model)
SetModel(const Set::Field< Set::Matrix4< AMREX_SPACEDIM, SYM > > &a_model)
SetPsi(int amrlev, const amrex::MultiFab &a_psi)
SetPsi(int amrlev, const amrex::MultiFab &a_psi, const Set::Scalar &a_psi_small)
SetBC(::BC::Operator::Elastic::Elastic *a_bc)
- The different types of Boundary Condtiions are listed in the documentation.GetBC()
Strain(int amrlev, amrex::MultiFab &epsfab, const amrex::MultiFab &ufab, bool voigt=false) const
- Compute strain given the displacement field by.Stress(int amrlev, amrex::MultiFab &sigmafab, const amrex::MultiFab &ufab, bool voigt=false, bool a_homogeneous=false)
- Compute stress given the displacement field by.Energy(int amrlev, amrex::MultiFab &energy, const amrex::MultiFab &u, bool a_homogeneous=false)
- Compute energy density given the displacement field by.SetBC(const std::array< std::array< BC, AMREX_SPACEDIM >, AMREX_SPACEDIM > &a_bc_lo, const std::array< std::array< BC, AMREX_SPACEDIM >, AMREX_SPACEDIM > &a_bc_hi)
- This function is depricated and should not be used.Error0x(int amrlev, int mglev, MultiFab &R0x, const MultiFab &x) const
SetTesting(bool a_testing)
SetUniform(bool a_uniform)
SetAverageDownCoeffs(bool a_average_down_coeffs) override
Diagonal(int amrlev, int mglev, amrex::MultiFab &diag) override
Fapply(int amrlev, int mglev, MultiFab &out, const MultiFab &in) const override final
FFlux(int amrlev, const MFIter &mfi, const std::array< FArrayBox *, AMREX_SPACEDIM > &flux, const FArrayBox &sol, const int face_only=0) const final
getNComp() const override
isCrossStencil() const
prepareForSolve() override
averageDownCoeffs() override
averageDownCoeffsDifferentAmrLevels(int fine_amrlev)
averageDownCoeffsSameAmrLevel(int amrlev)
- Update coarse-level AMR coefficients with data from fine level.FillBoundaryCoeff(MultiTab &sigma, const Geometry &geom)
FillBoundaryCoeff(MultiFab &psi, const Geometry &geom)
Variables
std::array<std::array<BC,AMREX_SPACEDIM>, AMREX_SPACEDIM> Operator::Elastic< SYM >::m_bc_lo
- Simple arrays storing boundary conditions for each component and each face.std::array<std::array<BC,AMREX_SPACEDIM>, AMREX_SPACEDIM> Operator::Elastic< SYM >::m_bc_hi
amrex::Vector<Set::Field<Set::Matrix4<AMREX_SPACEDIM,SYM> > > Operator::Elastic< SYM >::m_ddw_mf
- This is a multifab-type object containing objects of type Model::Solid::Elastic::Isotropic::Isotropic (or some other model type).amrex::Vector<Set::Field<Set::Scalar> > Operator::Elastic< SYM >::m_psi_mf
Set::Scalar Operator::Elastic< SYM >::m_psi_small
bool Operator::Elastic< SYM >::m_psi_set
bool Operator::Elastic< SYM >::m_testing
bool Operator::Elastic< SYM >::m_uniform
bool Operator::Elastic< SYM >::m_homogeneous
bool Operator::Elastic< SYM >::m_average_down_coeffs
::BC::Operator::Elastic::Elastic* Operator::Elastic< SYM >::m_bc
bool Operator::Elastic< SYM >::m_model_set
bool Operator::Elastic< SYM >::m_bc_set
Operator::Implicit
Operator::Implicit::Implicit
src/Operator/Implicit/Implicit.cpp src/Operator/Implicit/Implicit.H
API definitions in src/Operator/Implicit/Implicit.H
Classes
Operator::Implicit::Implicit
Methods
Implicit()
Implicit(const Vector< Geometry > &a_geom, const Vector< BoxArray > &a_grids, const Vector< DistributionMapping > &a_dmap, BC::BC< Set::Scalar > &a_bc, const LPInfo &a_info)
~Implicit()
Implicit(const Implicit &)=delete
Implicit(Implicit &&)=delete
operator=(const Implicit &)=delete
operator=(Implicit &&)=delete
Fapply(int amrlev, int mglev, MultiFab &out, const MultiFab &in) const final
Fsmooth(int amrlev, int mglev, MultiFab &sol, const MultiFab &rsh, int redblack) const final
FFlux(int amrlev, const MFIter &mfi, const Array< FArrayBox *, AMREX_SPACEDIM > &flux, const FArrayBox &sol, Location loc, const int face_only=0) const
getNComp() const
isCrossStencil() const
Set
Set::Set
The Set namespace defines the Alamo datatypes.
This includes scalars (Set::Scalar
), vectors (Set::Vector
), and nD tensors (Set::Tensor
).
Scalars are an alias for AMReX Real
.
Vectors and tensors are an alias for the Tuxfamily Eigen vectors and matrices, and so you can use
Eigen operations on them (like A.determinant()
, etc.)
See the Eigen documentation for more.
The Set namespace defines the Matrix4
datatype for fourth order tensors.
These can have isotropic, major, minor, majorminor, etc., symmetries.
The Set namespace also defines the Field
datatype, which is where most data is stored.
It is templated so that Set::Field<Set::Scalar>
is a field of scalars, Set::Field<Set::Vector>
is a vector field, etc.
One can also have, for instance, a field of models, like Set::Field<Model::Solid::Linear::Iostropic>
.
API definitions in src/Set/Set.H
Classes
Set::Field
Methods
Field()
Field(int a_levs, const amrex::Vector< amrex::BoxArray > &a_grids, const amrex::Vector< amrex::DistributionMapping > &a_dmap, int a_ncomp, int a_nghost)
Field(int size)
Define(int a_levs, const amrex::Vector< amrex::BoxArray > &a_grids, const amrex::Vector< amrex::DistributionMapping > &a_dmap, int a_ncomp, int a_nghost)
Define(int a_lev, const amrex::BoxArray &a_grid, const amrex::DistributionMapping &a_dmap, int a_ncomp, int a_nghost)
Copy(int, amrex::MultiFab &, int, int) const
CopyFrom(int, amrex::MultiFab &, int, int) const
Add(int, amrex::MultiFab &, int, int) const
AddFrom(int, amrex::MultiFab &, int, int) const
NComp() const
Name(int) const
Patch(int lev, amrex::MFIter &mfi) const &
NComp() const
Name(int i) const
Copy(int a_lev, amrex::MultiFab &a_dst, int a_dstcomp, int a_nghost) const
NComp() const
Name(int i) const
Copy(int a_lev, amrex::MultiFab &a_dst, int a_dstcomp, int a_nghost) const
NComp() const
Name(int i) const
Copy(int a_lev, amrex::MultiFab &a_dst, int a_dstcomp, int a_nghost) const
NComp() const
Name(int i) const
Copy(int a_lev, amrex::MultiFab &a_dst, int a_dstcomp, int a_nghost) const
NComp() const
Name(int i) const
Copy(int a_lev, amrex::MultiFab &a_dst, int a_dstcomp, int a_nghost) const
NComp() const
Name(int i) const
Copy(int a_lev, amrex::MultiFab &a_dst, int a_dstcomp, int a_nghost) const
NComp() const
Name(int i) const
Copy(int a_lev, amrex::MultiFab &a_dst, int a_dstcomp, int a_nghost) const
Copy(int a_lev, amrex::MultiFab &a_dst, int a_dstcomp, int a_nghost) const
CopyFrom(int a_lev, amrex::MultiFab &a_src, int a_dstcomp, int a_nghost) const
Add(int a_lev, amrex::MultiFab &a_dst, int a_dstcomp, int a_nghost) const
AddFrom(int a_lev, amrex::MultiFab &a_src, int a_srccomp, int a_nghost) const
NComp() const
Name(int i) const
Copy(int a_lev, amrex::MultiFab &a_dst, int a_dstcomp, int a_nghost) const
NComp() const
Name(int i) const
Variables
int Set::Field< T >::finest_level
std::string Set::Field< T >::name
amrex::Array4<T> Set::Field< T >::empty
Set::Field< Set::Scalar >
Methods
Field()
Field(int size)
Define(int a_levs, const amrex::Vector< amrex::BoxArray > &a_grids, const amrex::Vector< amrex::DistributionMapping > &a_dmap, int a_ncomp, int a_nghost)
Define(int a_lev, const amrex::BoxArray &a_grid, const amrex::DistributionMapping &a_dmap, int a_ncomp, int a_nghost)
Copy(int, amrex::MultiFab &, int, int) const
NComp() const
Patch(int lev, amrex::MFIter &mfi) const &
Variables
int Set::Field< Set::Scalar >::finest_level
amrex::Array4<Set::Scalar> Set::Field< Set::Scalar >::empty
Set::Base
API definitions in src/Set/Base.H
Classes
Set::Matrix4
Set::Quaternion
Methods
Quaternion()
Quaternion(Set::Scalar w, Set::Scalar x, Set::Scalar y, Set::Scalar z)
Quaternion(const Eigen::Matrix3d &R)
Quaternion(Eigen::Quaterniond &q)
operator=(const Eigen::Quaterniond &rhs)
operator+=(const Quaternion &rhs)
Set::Eigen_Amrex
API definitions in src/Set/Eigen_Amrex.H
Classes
Set::Matrix4
API definitions in src/Set/Matrix4.H
Classes
Set::Matrix4_MajorMinor
API definitions in src/Set/Matrix4_MajorMinor.H
Classes
Set::Matrix4< 2, Sym::MajorMinor >
- Data structure for a 4th order 3D tensor with major and minor symmetry.Methods
Matrix4()
operator()(const int i, const int j, const int k, const int l) const
operator()(const int i, const int j, const int k, const int l)
Print(std::ostream &os)
Norm()
contains_nan() const
operator+=(Matrix4< 2, Sym::MajorMinor > a)
operator-=(Matrix4< 2, Sym::MajorMinor > a)
operator*=(Matrix4< 2, Sym::MajorMinor > a)
operator/=(Matrix4< 2, Sym::MajorMinor > a)
operator*=(Set::Scalar alpha)
operator/=(Set::Scalar alpha)
Variables
Scalar Set::Matrix4< 2, Sym::MajorMinor >::data[6]
Set::Matrix4< 3, Sym::MajorMinor >
- Data structure for a 4th order 3D tensor with major and minor symmetry.Methods
Matrix4()
operator()(const int i, const int j, const int k, const int l) const
operator()(const int i, const int j, const int k, const int l)
Print(std::ostream &os)
Norm()
contains_nan() const
operator+=(Matrix4< 3, Sym::MajorMinor > a)
operator-=(Matrix4< 3, Sym::MajorMinor > a)
operator*=(Matrix4< 3, Sym::MajorMinor > a)
operator/=(Matrix4< 3, Sym::MajorMinor > a)
operator*=(Set::Scalar alpha)
operator/=(Set::Scalar alpha)
Variables
Scalar Set::Matrix4< 3, Sym::MajorMinor >::data[21]
Set::Matrix4_Diagonal
API definitions in src/Set/Matrix4_Diagonal.H
Classes
Set::Matrix4< AMREX_SPACEDIM, Sym::Diagonal >
Methods
Matrix4()
Matrix4(Set::Matrix a_A)
operator()(const int i, const int j, const int k, const int l) const
Randomize()
Print(std::ostream &os)
operator+=(const Matrix4< AMREX_SPACEDIM, Sym::Diagonal > &a)
operator-=(const Matrix4< AMREX_SPACEDIM, Sym::Diagonal > &a)
operator*=(const Set::Scalar &alpha)
operator/=(const Set::Scalar &alpha)
Norm()
contains_nan() const
Variables
Set::Matrix Set::Matrix4< AMREX_SPACEDIM, Sym::Diagonal >::A
Set::Matrix4_Full
API definitions in src/Set/Matrix4_Full.H
Classes
Set::Matrix4< 2, Sym::Full >
- Data structure for a symmetrix 4th order 3D tensor.Methods
Matrix4()
operator()(const int i, const int j, const int k, const int l)
operator()(const int i, const int j, const int k, const int l) const
Print(std::ostream &)
contains_nan() const
Variables
Scalar Set::Matrix4< 2, Sym::Full >::data[5]
Set::Matrix4< 3, Sym::Full >
Methods
Matrix4()
operator()(const int i, const int j, const int k, const int l)
operator()(const int i, const int j, const int k, const int l) const
Print(std::ostream &os)
contains_nan() const
Variables
Scalar Set::Matrix4< 3, Sym::Full >::data[15]
Set::Matrix3
API definitions in src/Set/Matrix3.H
Classes
Set::Matrix3
Methods
operator()(const int i, const int j, const int k)
operator()(const int i, const int j, const int k) const
operator[](const int i)
norm()
operator+=(Matrix3 a)
operator-=(Matrix3 a)
operator*=(Set::Scalar alpha)
operator/=(Set::Scalar alpha)
Variables
Set::Matrix Set::Matrix3::data[AMREX_SPACEDIM]
Set::Matrix4_Isotropic
The isotropic tensor is defined to be
The inverse (“compliance”) tensor is
Replacing E, nu with Lame constants gives:
- For reference: http://solidmechanics.org/text/Chapter3_2/Chapter3_2.htm
API definitions in src/Set/Matrix4_Isotropic.H
Classes
Set::Matrix4< AMREX_SPACEDIM, Sym::Isotropic >
Methods
Matrix4()
Matrix4(Set::Scalar a_lambda, Set::Scalar a_mu)
operator()(const int i, const int j, const int k, const int l) const
- Note: for the Isotropic this routine works for ! If you try to assign a value using this with, say.Randomize()
Print(std::ostream &os)
Lambda() const
Mu() const
Inverse() const
operator+=(const Matrix4< AMREX_SPACEDIM, Sym::Isotropic > &a)
operator-=(const Matrix4< AMREX_SPACEDIM, Sym::Isotropic > &a)
operator*=(const Matrix4< AMREX_SPACEDIM, Sym::Isotropic > &a)
operator/=(const Matrix4< AMREX_SPACEDIM, Sym::Isotropic > &a)
operator*=(const Set::Scalar &alpha)
operator/=(const Set::Scalar &alpha)
Norm()
contains_nan() const
Variables
Set::Scalar Set::Matrix4< AMREX_SPACEDIM, Sym::Isotropic >::lambda
Set::Scalar Set::Matrix4< AMREX_SPACEDIM, Sym::Isotropic >::mu
Set::Matrix4_Major
API definitions in src/Set/Matrix4_Major.H
Classes
Set::Matrix4< 2, Sym::Major >
Methods
Matrix4()
operator()(const int i, const int j, const int k, const int l) const
operator()(const int i, const int j, const int k, const int l)
Print(std::ostream &os)
operator+=(const Matrix4< 2, Sym::Major > &a)
operator-=(const Matrix4< 2, Sym::Major > &a)
operator*=(const Matrix4< 2, Sym::Major > &a)
operator/=(const Matrix4< 2, Sym::Major > &a)
operator*=(const Set::Scalar &alpha)
operator/=(const Set::Scalar &alpha)
Norm()
contains_nan() const
Variables
Scalar Set::Matrix4< 2, Sym::Major >::data[10]
Set::Matrix4< 3, Sym::Major >
Methods
Matrix4()
operator()(const int i, const int j, const int k, const int l)
operator()(const int i, const int j, const int k, const int l) const
Norm()
Print(std::ostream &os)
operator+=(const Matrix4< 3, Sym::Major > &a)
operator-=(const Matrix4< 3, Sym::Major > &a)
operator*=(const Matrix4< 3, Sym::Major > &a)
operator/=(const Matrix4< 3, Sym::Major > &a)
operator*=(const Set::Scalar &alpha)
operator/=(const Set::Scalar &alpha)
norm()
contains_nan() const
Variables
Scalar Set::Matrix4< 3, Sym::Major >::data[45]
Solver
Solver::Local
Solver::Local::CG
API definitions in src/Solver/Local/CG.H
Classes
Solver::Local::Riemann
Solver::Local::Riemann::Riemann
src/Solver/Local/Riemann/Riemann.H
API definitions in src/Solver/Local/Riemann/Riemann.H
Classes
Solver::Local::Riemann::Flux
Methods
Flux()
Flux(Set::Scalar a_mass, Set::Scalar a_momentum_normal, Set::Scalar a_momentum_tangent, Set::Scalar a_energy)
operator+=(const Flux &a)
operator-=(const Flux &a)
operator*=(const Set::Scalar alpha)
operator/=(const Set::Scalar alpha)
Variables
Set::Scalar Solver::Local::Riemann::Flux::mass
Set::Scalar Solver::Local::Riemann::Flux::momentum_normal
Set::Scalar Solver::Local::Riemann::Flux::momentum_tangent
Set::Scalar Solver::Local::Riemann::Flux::energy
Solver::Local::Riemann::State
Methods
State()
State(Set::Scalar a_rho, Set::Scalar a_M_normal, Set::Scalar a_M_tangent, Set::Scalar a_E)
State(Set::Patch< const Set::Scalar > density_mf, Set::Patch< const Set::Scalar > momentum_mf, Set::Patch< const Set::Scalar > energy_mf, int i, int j, int k, int direction)
operator+=(const State &a)
operator-=(const State &a)
operator*=(const Set::Scalar alpha)
operator/=(const Set::Scalar alpha)
Variables
Set::Scalar Solver::Local::Riemann::State::rho
Set::Scalar Solver::Local::Riemann::State::M_normal
Set::Scalar Solver::Local::Riemann::State::M_tangent
Set::Scalar Solver::Local::Riemann::State::E
Solver::Local::Riemann::Roe
src/Solver/Local/Riemann/Roe.H
This implements the Riemann Roe solver.
Notation and algorithm follow the presentation in Section 5.3.3 of Computational Gasdynamics by Culbert B. Laney (page 88)
- This solver uses an optional entropy fix
Option 1: chimeracfd method https://chimeracfd.com/programming/gryphon/fluxroe.html Option 2: Eq. 4.3.67 in Computational Fluid Dynamics for Engineers and Scientists by Sreenivas Jayanti
Parameter |
Type |
Values |
---|---|---|
enable to dump diagnostic data if the roe solver fails |
1 |
|
apply entropy fix if tru |
false |
API definitions in src/Solver/Local/Riemann/Roe.H
Classes
Solver::Local::Riemann::Roe
- based on Gas Dynamics - Culbert B. Laney.Methods
Roe(IO::ParmParse &pp, std::string name)
Roe(IO::ParmParse &pp)
Roe()
Solve(State lo, State hi, Set::Scalar gamma, Set::Scalar p_ref, Set::Scalar small)
Variables
int Solver::Local::Riemann::Roe::verbose
int Solver::Local::Riemann::Roe::entropy_fix
Solver::Nonlocal
Solver::Nonlocal::Linear
Parameter |
Type |
Values |
---|---|---|
Max number of iterations to perform before erroring out |
||
Max number of iterations on the bottom solver |
||
Max number of F-cycle iterations to perform |
||
Number of fixed iterations to perform before exiting gracefully |
||
Verbosity of the solver (1-5) |
||
Number of smoothing operations before bottom solve (2) |
||
Number of smoothing operations after bottom solve (2) |
||
Number of final smoothing operations when smoother is used as bottom solver (8) |
||
Additional smoothing after bottom CG solver (0) |
||
The method that is used for the multigrid bottom solve (cg, bicgstab, smoother) |
||
Relative tolerance on bottom solver |
||
Absolute tolerance on bottom solver |
||
Relative tolerance |
||
Absolute tolerance |
||
Omega (used in gauss-seidel solver) |
||
Whether to average down coefficients or use the ones given. (Setting this to true is important for fracture.) |
||
Whether to normalize DDW when calculating the diagonal. This is primarily used when DDW is near-singular - like when there is a "void" region or when doing phase field fracture. |
||
If set to true, output diagnostic multifab information whenever the MLMG solver fails to converge. (Note: you must also set |
||
If set to false, MLMG will not die if convergence criterion is not reached. (Note: you must also set |
API definitions in src/Solver/Nonlocal/Linear.H
Classes
Solver::Nonlocal::Linear
- Multigrid solver for multicomponent, multi-level operators.Methods
Linear()
Linear(Operator::Operator< Grid::Node > &a_lp)
~Linear()
Define(Operator::Operator< Grid::Node > &a_lp)
Clear()
solveaffine(amrex::Vector< std::unique_ptr< amrex::MultiFab > > &a_sol, amrex::Vector< std::unique_ptr< amrex::MultiFab > > &a_rhs, Real a_tol_rel, Real a_tol_abs, bool copyrhs=false, const char *checkpoint_file=nullptr)
solve(amrex::Vector< std::unique_ptr< amrex::MultiFab > > &a_sol, amrex::Vector< std::unique_ptr< amrex::MultiFab > > &a_rhs, Real a_tol_rel, Real a_tol_abs, const char *checkpoint_file=nullptr)
solve(amrex::Vector< std::unique_ptr< amrex::MultiFab > > &a_sol, amrex::Vector< std::unique_ptr< amrex::MultiFab > > &a_rhs)
apply(amrex::Vector< std::unique_ptr< amrex::MultiFab > > &a_rhs, amrex::Vector< std::unique_ptr< amrex::MultiFab > > &a_sol)
setMaxIter(const int a_max_iter)
setBottomMaxIter(const int a_bottom_max_iter)
setMaxFmgIter(const int a_max_fmg_iter)
setFixedIter(const int a_fixed_iter)
setVerbose(const int a_verbose)
setPreSmooth(const int a_pre_smooth)
setPostSmooth(const int a_post_smooth)
dumpOnConvergenceFail(const amrex::Vector< amrex::MultiFab * > &a_sol_mf, const amrex::Vector< amrex::MultiFab const * > &a_rhs_mf)
PrepareMLMG(amrex::MLMG &mlmg)
Variables
int Solver::Nonlocal::Linear::max_iter
int Solver::Nonlocal::Linear::bottom_max_iter
int Solver::Nonlocal::Linear::max_fmg_iter
int Solver::Nonlocal::Linear::fixed_iter
int Solver::Nonlocal::Linear::verbose
int Solver::Nonlocal::Linear::pre_smooth
int Solver::Nonlocal::Linear::post_smooth
int Solver::Nonlocal::Linear::final_smooth
int Solver::Nonlocal::Linear::bottom_smooth
std::string Solver::Nonlocal::Linear::bottom_solver
Set::Scalar Solver::Nonlocal::Linear::cg_tol_rel
Set::Scalar Solver::Nonlocal::Linear::cg_tol_abs
Set::Scalar Solver::Nonlocal::Linear::bottom_tol_rel
Set::Scalar Solver::Nonlocal::Linear::bottom_tol_abs
Set::Scalar Solver::Nonlocal::Linear::tol_rel
Set::Scalar Solver::Nonlocal::Linear::tol_abs
Set::Scalar Solver::Nonlocal::Linear::omega
bool Solver::Nonlocal::Linear::average_down_coeffs
bool Solver::Nonlocal::Linear::normalize_ddw
Operator::Operator<Grid::Node>* Solver::Nonlocal::Linear::linop
amrex::MLMG* Solver::Nonlocal::Linear::mlmg
bool Solver::Nonlocal::Linear::m_defined
bool Solver::Nonlocal::Linear::m_dump_on_fail
bool Solver::Nonlocal::Linear::m_abort_on_fail
Solver::Nonlocal::Newton
Parameter |
Type |
Values |
---|---|---|
Number of newton-raphson iterations. |
||
Tolerance to use for newton-raphson convergence |
API definitions in src/Solver/Nonlocal/Newton.H
Classes
Solver::Nonlocal::Newton
Methods
Newton()
Newton(Operator::Elastic< T::sym > &a_op)
~Newton()
Define(Operator::Elastic< T::sym > &a_op)
Clear()
setNRIters(int a_nriters)
setPsi(Set::Field< Set::Scalar > &a_psi)
solve(const Set::Field< Set::Vector > &a_u_mf, const Set::Field< Set::Vector > &a_b_mf, Set::Field< T > &a_model_mf, Real a_tol_rel, Real a_tol_abs, const char *checkpoint_file=nullptr)
solve(const Set::Field< Set::Scalar > &a_u_mf, const Set::Field< Set::Scalar > &a_b_mf, Set::Field< T > &a_model_mf, Real a_tol_rel, Real a_tol_abs, const char *checkpoint_file=nullptr)
solve(const Set::Field< Set::Scalar > &a_u_mf, const Set::Field< Set::Scalar > &a_b_mf, Set::Field< T > &a_model_mf)
compResidual(Set::Field< Set::Scalar > &a_res_mf, Set::Field< Set::Scalar > &a_u_mf, Set::Field< Set::Scalar > &a_b_mf, Set::Field< T > &a_model_mf)
compResidual(Set::Field< Set::Vector > &a_res_mf, Set::Field< Set::Vector > &a_u_mf, Set::Field< Set::Vector > &a_b_mf, Set::Field< T > &a_model_mf)
compLinearSolverResidual(Set::Field< Set::Vector > &a_res_mf, Set::Field< Set::Vector > &a_u_mf, Set::Field< Set::Vector > &a_b_mf)
W(Set::Field< Set::Scalar > &a_w_mf, Set::Field< Set::Scalar > &a_u_mf, Set::Field< T > &a_model_mf)
DW(Set::Field< Set::Scalar > &a_dw_mf, Set::Field< Set::Scalar > &a_u_mf, Set::Field< T > &a_model_mf)
prepareForSolve(const Set::Field< Set::Scalar > &a_u_mf, const Set::Field< Set::Scalar > &a_b_mf, Set::Field< Set::Scalar > &a_rhs_mf, Set::Field< Set::Matrix > &a_dw_mf, Set::Field< Set::Matrix4< AMREX_SPACEDIM, T::sym > > &a_ddw_mf, Set::Field< T > &a_model_mf)
prepareForSolve(const Set::Field< Set::Vector > &a_u_mf, const Set::Field< Set::Vector > &a_b_mf, Set::Field< Set::Scalar > &a_rhs_mf, Set::Field< Set::Matrix > &a_dw_mf, Set::Field< Set::Matrix4< AMREX_SPACEDIM, T::sym > > &a_ddw_mf, Set::Field< T > &a_model_mf)
Variables
int Solver::Nonlocal::Newton< T >::m_nriters
Set::Scalar Solver::Nonlocal::Newton< T >::m_nrtolerance
Operator::Elastic<T::sym>* Solver::Nonlocal::Newton< T >::m_elastic
Set::Field<Set::Scalar>* Solver::Nonlocal::Newton< T >::m_psi
Test
Test::Model
Test::Model::Interface
Test::Model::Interface::GB
Test::Model::Interface::GB::GB
src/Test/Model/Interface/GB/GB.H
API definitions in src/Test/Model/Interface/GB/GB.H
Classes
Test::Model::Interface::GB::GB
Methods
GB()
DerivativeTest1(int verbose)
DerivativeTest2(int verbose)
Test::Numeric
Test::Numeric::Stencil
API definitions in src/Test/Numeric/Stencil.H
Classes
Test::Numeric::Stencil
Methods
Stencil()
~Stencil()
Define(amrex::IntVect _ncells)
Define(int _ncells)
Derivative(int verbose, std::string plotfile="")
WritePlotFile(std::string plotfile)
Variables
amrex::IntVect Test::Numeric::Stencil::ncells
const Set::Scalar Test::Numeric::Stencil::L
const int Test::Numeric::Stencil::ncomp
const int Test::Numeric::Stencil::nghost
amrex::Vector<amrex::Geometry> Test::Numeric::Stencil::geom
amrex::Vector<amrex::BoxArray> Test::Numeric::Stencil::grids
amrex::Vector<amrex::DistributionMapping> Test::Numeric::Stencil::dmap
Set::Field<Set::Scalar> Test::Numeric::Stencil::phi
Set::Field<Set::Scalar> Test::Numeric::Stencil::DphiExact
Set::Field<Set::Scalar> Test::Numeric::Stencil::DphiNumeric
amrex::Vector<std::string> Test::Numeric::Stencil::varnames
Test::Set
Test::Set::Matrix4
API definitions in src/Test/Set/Matrix4.H
Classes
Test::Set::Matrix4
Methods
SymmetryTest(int)
Util
Util::Util
src/Util/Util.cpp src/Util/Util.H
Parameter |
Type |
Values |
---|---|---|
Name of directory containing all output data |
API definitions in src/Util/Util.H
Classes
Util::BMP
API definitions in src/Util/BMP.H
Classes
Util::BMP
Methods
BMP()
Define(std::string filename)
operator()(int i, int j)
min()
max()
Variables
int Util::BMP::nx
int Util::BMP::ny
std::vector<std::array<int,3> > Util::BMP::data
Util::Color
API definitions in src/Util/Color.H
Classes
Util::MPI
API definitions in src/Util/MPI.H
Classes
Util::PNG
Parameter |
Type |
Values |
---|---|---|
BMP filename. |
file path |
|
how to position the image |
stretch fitheight fitwidth coord |
|
Lower-left coordinates of image in domain |
||
Upper-right coordinates of image in domain |
||
Desired minimum value to scale pixels by |
0.0 |
|
Desired maximum value to scale pixels by |
255.0 |
API definitions in src/Util/PNG.H
Classes
Util::PNG
Methods
PNG()
PNG(IO::ParmParse &pp, std::string name)
~PNG()
setDomain(Set::Vector &_lo, Set::Vector &_hi)
operator()(int I, int J)
operator()(Set::Vector &x)
Variables
int Util::PNG::png_width
int Util::PNG::png_height
png_byte Util::PNG::color_type
png_byte Util::PNG::bit_depth
png_bytep* Util::PNG::row_pointers
Set::Vector Util::PNG::coord_lo
Set::Vector Util::PNG::coord_hi
Fit Util::PNG::fit
Set::Scalar Util::PNG::min
Set::Scalar Util::PNG::max
bool Util::PNG::domain_defined
Set::Vector Util::PNG::domain_lo
Set::Vector Util::PNG::domain_hi
Util::Hash
Util::Hash::Hash
API definitions in src/Util/Hash/Hash.H
Classes
Util::Hash::SHA256
Methods
SHA256()
update(const uint8_t *data, size_t length)
update(const std::string &data)
final()
reset()
transform()
pad()
Variables
std::array<uint32_t, 8> Util::Hash::SHA256::state_
uint8_t Util::Hash::SHA256::data_[64]
uint32_t Util::Hash::SHA256::datalen_
uint64_t Util::Hash::SHA256::bitlen_
const std::array<uint32_t, 64> Util::Hash::SHA256::k_