#pragma once
#include "Moose.h"
#include "ADReal.h"
#include "EigenADReal.h"
#include "ChainedReal.h"
#include "ChainedADReal.h"
#include "ADRankTwoTensorForward.h"
#include "ADRankThreeTensorForward.h"
#include "ADRankFourTensorForward.h"
#include "ADSymmetricRankTwoTensorForward.h"
#include "ADSymmetricRankFourTensorForward.h"
#include "libmesh/libmesh.h"
#include "libmesh/id_types.h"
#include "libmesh/stored_range.h"
#include "libmesh/petsc_macro.h"
#include "libmesh/boundary_info.h"
#include "libmesh/parameters.h"
#include "libmesh/dense_vector.h"
#include "libmesh/int_range.h"
#include "boost/bitmask_operators.h"
#include "libmesh/ignore_warnings.h"
#include "Eigen/Core"
#include "libmesh/restore_warnings.h"
#include "libmesh/tensor_tools.h"
#include "metaphysicl/ct_types.h"
#include <string>
#include <vector>
#include <memory>
#include <type_traits>
#include <functional>
#include "nlohmann/json_fwd.h"
#define MooseSharedPointer std::shared_ptr
#define MooseSharedNamespace std
#ifdef __clang__
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wgnu-zero-variadic-macro-arguments"
#endif
#define beginIndex_0() ERROR-- > "beginIndex() requires one or two arguments"
#define beginIndex_1(A) decltype(A.size())(0)
#define beginIndex_2(A, B) decltype(A.size())(B)
#define beginIndex_3(A, B, C) ERROR-- > "beginIndex() requires one or two arguments"
#define beginIndex_4(A, B, C, D) ERROR-- > "beginIndex() requires one or two arguments"
#define beginIndex_X(x, A, B, C, D, FUNC, ...) FUNC
#define beginIndex(...) \
beginIndex_X(, \
##__VA_ARGS__, \
beginIndex_4(__VA_ARGS__), \
beginIndex_3(__VA_ARGS__), \
beginIndex_2(__VA_ARGS__), \
beginIndex_1(__VA_ARGS__), \
beginIndex_0(__VA_ARGS__))
#define MooseIndex(type) decltype(_MooseIndex(type, 0))
template <typename T, typename std::enable_if<std::is_integral<T>::value>::type * = nullptr>
typename std::remove_const<T>::type
_MooseIndex(T, int)
{
}
template <typename T>
decltype(std::declval<T>().size())
_MooseIndex(T &&, int)
{
}
template <typename T>
decltype("NOTE: MooseIndex only works with integers and objects with size()!")
_MooseIndex(T, double) = delete;
#ifdef __clang__
#pragma clang diagnostic pop
#endif
template <typename>
class MooseArray;
template <typename>
class MaterialProperty;
template <typename>
class ADMaterialProperty;
class InputParameters;
namespace libMesh
{
template <typename>
class VectorValue;
typedef VectorValue<Real> RealVectorValue;
typedef Eigen::Matrix<Real, Moose::dim, 1> RealDIMValue;
typedef Eigen::Matrix<Real, Eigen::Dynamic, 1> RealEigenVector;
typedef Eigen::Matrix<Real, Eigen::Dynamic, Moose::dim> RealVectorArrayValue;
typedef Eigen::Matrix<Real, Eigen::Dynamic, Moose::dim * Moose::dim> RealTensorArrayValue;
typedef Eigen::Matrix<Real, Eigen::Dynamic, Eigen::Dynamic> RealEigenMatrix;
template <typename>
class TypeVector;
template <typename>
class TensorValue;
typedef TensorValue<Real> RealTensorValue;
template <typename>
class TypeTensor;
template <unsigned int, typename>
class TypeNTensor;
class Point;
template <typename>
class DenseMatrix;
template <typename>
class DenseVector;
namespace TensorTools
{
template <>
struct IncrementRank<Eigen::Matrix<Real, Eigen::Dynamic, 1>>
{
typedef Eigen::Matrix<Real, Eigen::Dynamic, Moose::dim> type;
};
template <>
struct IncrementRank<Eigen::Matrix<Real, Eigen::Dynamic, Moose::dim>>
{
typedef Eigen::Matrix<Real, Eigen::Dynamic, Moose::dim * Moose::dim> type;
};
template <>
struct DecrementRank<Eigen::Matrix<Real, Eigen::Dynamic, Moose::dim>>
{
typedef Eigen::Matrix<Real, Eigen::Dynamic, 1> type;
};
}
}
namespace MetaPhysicL
{
template <typename U>
struct ReplaceAlgebraicType<libMesh::RealEigenVector, U>
{
typedef U type;
};
}
typedef Real PostprocessorValue;
typedef std::vector<Real> VectorPostprocessorValue;
typedef Real ScatterVectorPostprocessorValue;
typedef boundary_id_type BoundaryID;
typedef unsigned int InterfaceID;
typedef subdomain_id_type SubdomainID;
typedef unsigned int MooseObjectID;
typedef unsigned int THREAD_ID;
typedef unsigned int TagID;
typedef unsigned int TagTypeID;
typedef unsigned int PerfID;
typedef unsigned int InvalidSolutionID;
using RestartableDataMapName = std::string;
typedef StoredRange<std::vector<dof_id_type>::iterator, dof_id_type> NodeIdRange;
typedef StoredRange<std::vector<const Elem *>::iterator, const Elem *> ConstElemPointerRange;
namespace Moose
{
constexpr std::size_t constMaxQpsPerElem = 216;
enum SolutionState : int
{
Current = 0,
Old = 1,
Older = 2,
PreviousNL = -1
};
enum class SolutionIterationType : unsigned short
{
Time = 0,
Nonlinear
};
enum GeometryType
{
Volume,
Face
};
template <typename OutputType>
struct ShapeType
{
typedef OutputType type;
};
template <>
struct ShapeType<Eigen::Matrix<Real, Eigen::Dynamic, 1>>
{
typedef Real type;
};
template <typename OutputType>
struct DOFType
{
typedef OutputType type;
};
template <>
struct DOFType<RealVectorValue>
{
typedef Real type;
};
}
template <typename OutputType>
struct OutputTools
{
typedef typename TensorTools::IncrementRank<OutputType>::type OutputGradient;
typedef typename TensorTools::IncrementRank<OutputGradient>::type OutputSecond;
typedef typename TensorTools::DecrementRank<OutputType>::type OutputDivergence;
typedef MooseArray<OutputType> VariableValue;
typedef MooseArray<OutputGradient> VariableGradient;
typedef MooseArray<OutputSecond> VariableSecond;
typedef MooseArray<OutputType> VariableCurl;
typedef MooseArray<OutputDivergence> VariableDivergence;
typedef typename Moose::ShapeType<OutputType>::type OutputShape;
typedef typename TensorTools::IncrementRank<OutputShape>::type OutputShapeGradient;
typedef typename TensorTools::IncrementRank<OutputShapeGradient>::type OutputShapeSecond;
typedef typename TensorTools::DecrementRank<OutputShape>::type OutputShapeDivergence;
typedef MooseArray<std::vector<OutputShape>> VariablePhiValue;
typedef MooseArray<std::vector<OutputShapeGradient>> VariablePhiGradient;
typedef MooseArray<std::vector<OutputShapeSecond>> VariablePhiSecond;
typedef MooseArray<std::vector<OutputShape>> VariablePhiCurl;
typedef MooseArray<std::vector<OutputShapeDivergence>> VariablePhiDivergence;
typedef MooseArray<std::vector<OutputShape>> VariableTestValue;
typedef MooseArray<std::vector<OutputShapeGradient>> VariableTestGradient;
typedef MooseArray<std::vector<OutputShapeSecond>> VariableTestSecond;
typedef MooseArray<std::vector<OutputShape>> VariableTestCurl;
typedef MooseArray<std::vector<OutputShapeDivergence>> VariableTestDivergence;
typedef typename Moose::DOFType<OutputType>::type OutputData;
typedef MooseArray<OutputData> DoFValue;
typedef OutputType OutputValue;
};
typedef typename OutputTools<Real>::VariableValue VariableValue;
typedef typename OutputTools<Real>::VariableGradient VariableGradient;
typedef typename OutputTools<Real>::VariableSecond VariableSecond;
typedef typename OutputTools<Real>::VariableCurl VariableCurl;
typedef typename OutputTools<Real>::VariableDivergence VariableDivergence;
typedef typename OutputTools<Real>::VariablePhiValue VariablePhiValue;
typedef typename OutputTools<Real>::VariablePhiGradient VariablePhiGradient;
typedef typename OutputTools<Real>::VariablePhiSecond VariablePhiSecond;
typedef typename OutputTools<Real>::VariablePhiCurl VariablePhiCurl;
typedef typename OutputTools<Real>::VariablePhiDivergence VariablePhiDivergence;
typedef typename OutputTools<Real>::VariableTestValue VariableTestValue;
typedef typename OutputTools<Real>::VariableTestGradient VariableTestGradient;
typedef typename OutputTools<Real>::VariableTestSecond VariableTestSecond;
typedef typename OutputTools<Real>::VariableTestCurl VariableTestCurl;
typedef typename OutputTools<Real>::VariableTestDivergence VariableTestDivergence;
typedef typename OutputTools<RealVectorValue>::VariableValue VectorVariableValue;
typedef typename OutputTools<RealVectorValue>::VariableGradient VectorVariableGradient;
typedef typename OutputTools<RealVectorValue>::VariableSecond VectorVariableSecond;
typedef typename OutputTools<RealVectorValue>::VariableCurl VectorVariableCurl;
typedef typename OutputTools<RealVectorValue>::VariableDivergence VectorVariableDivergence;
typedef typename OutputTools<RealVectorValue>::VariablePhiValue VectorVariablePhiValue;
typedef typename OutputTools<RealVectorValue>::VariablePhiGradient VectorVariablePhiGradient;
typedef typename OutputTools<RealVectorValue>::VariablePhiSecond VectorVariablePhiSecond;
typedef typename OutputTools<RealVectorValue>::VariablePhiCurl VectorVariablePhiCurl;
typedef typename OutputTools<RealVectorValue>::VariablePhiDivergence VectorVariablePhiDivergence;
typedef typename OutputTools<RealVectorValue>::VariableTestValue VectorVariableTestValue;
typedef typename OutputTools<RealVectorValue>::VariableTestGradient VectorVariableTestGradient;
typedef typename OutputTools<RealVectorValue>::VariableTestSecond VectorVariableTestSecond;
typedef typename OutputTools<RealVectorValue>::VariableTestCurl VectorVariableTestCurl;
typedef typename OutputTools<RealVectorValue>::VariableTestDivergence VectorVariableTestDivergence;
typedef typename OutputTools<RealEigenVector>::VariableValue ArrayVariableValue;
typedef typename OutputTools<RealEigenVector>::VariableGradient ArrayVariableGradient;
typedef typename OutputTools<RealEigenVector>::VariableSecond ArrayVariableSecond;
typedef typename OutputTools<RealEigenVector>::VariableCurl ArrayVariableCurl;
typedef typename OutputTools<RealEigenVector>::VariableDivergence ArrayVariableDivergence;
typedef typename OutputTools<RealEigenVector>::VariablePhiValue ArrayVariablePhiValue;
typedef typename OutputTools<RealEigenVector>::VariablePhiGradient ArrayVariablePhiGradient;
typedef std::vector<std::vector<Eigen::Map<RealDIMValue>>> MappedArrayVariablePhiGradient;
typedef typename OutputTools<RealEigenVector>::VariablePhiSecond ArrayVariablePhiSecond;
typedef typename OutputTools<RealEigenVector>::VariablePhiCurl ArrayVariablePhiCurl;
typedef typename OutputTools<RealEigenVector>::VariablePhiDivergence ArrayVariablePhiDivergence;
typedef typename OutputTools<RealEigenVector>::VariableTestValue ArrayVariableTestValue;
typedef typename OutputTools<RealEigenVector>::VariableTestGradient ArrayVariableTestGradient;
typedef typename OutputTools<RealEigenVector>::VariableTestSecond ArrayVariableTestSecond;
typedef typename OutputTools<RealEigenVector>::VariableTestCurl ArrayVariableTestCurl;
typedef typename OutputTools<RealEigenVector>::VariableTestDivergence ArrayVariableTestDivergence;
typedef libMesh::VectorValue<ADReal> ADRealVectorValue;
typedef ADRealVectorValue ADRealGradient;
typedef libMesh::VectorValue<ADReal> ADPoint;
typedef libMesh::TensorValue<ADReal> ADRealTensorValue;
typedef libMesh::DenseMatrix<ADReal> ADDenseMatrix;
typedef libMesh::DenseVector<ADReal> ADDenseVector;
typedef MooseArray<ADReal> ADVariableValue;
typedef MooseArray<ADRealVectorValue> ADVariableGradient;
typedef MooseArray<ADRealTensorValue> ADVariableSecond;
typedef MooseArray<ADRealVectorValue> ADVectorVariableValue;
typedef MooseArray<ADRealTensorValue> ADVectorVariableGradient;
typedef MooseArray<libMesh::TypeNTensor<3, ADReal>> ADVectorVariableSecond;
namespace Moose
{
template <typename T>
struct ADType
{
typedef T type;
};
template <>
struct ADType<Real>
{
typedef ADReal type;
};
template <>
struct ADType<ChainedReal>
{
typedef ChainedADReal type;
};
template <>
struct ADType<Point>
{
typedef ADPoint type;
};
template <>
struct ADType<RealVectorValue>
{
typedef ADRealVectorValue type;
};
template <>
struct ADType<RankTwoTensor>
{
typedef ADRankTwoTensor type;
};
template <>
struct ADType<RankThreeTensor>
{
typedef ADRankThreeTensor type;
};
template <>
struct ADType<RankFourTensor>
{
typedef ADRankFourTensor type;
};
template <>
struct ADType<SymmetricRankTwoTensor>
{
typedef ADSymmetricRankTwoTensor type;
};
template <>
struct ADType<SymmetricRankFourTensor>
{
typedef ADSymmetricRankFourTensor type;
};
template <template <typename T> class W, typename T>
struct ADType<W<T>>
{
typedef W<typename ADType<T>::type> type;
};
template <typename T>
struct ADType<std::vector<T, std::allocator<T>>>
{
typedef typename ADType<T>::type adT;
typedef std::vector<adT, std::allocator<adT>> type;
};
template <typename T>
struct ADType<std::list<T, std::allocator<T>>>
{
typedef typename ADType<T>::type adT;
typedef std::list<adT, std::allocator<adT>> type;
};
template <typename T>
struct ADType<std::set<T, std::less<T>, std::allocator<T>>>
{
typedef typename ADType<T>::type adT;
typedef std::set<adT, std::less<adT>, std::allocator<adT>> type;
};
template <typename T>
struct ADType<DenseVector<T>>
{
typedef DenseVector<typename ADType<T>::type> type;
};
template <typename T>
struct ADType<DenseMatrix<T>>
{
typedef DenseMatrix<typename ADType<T>::type> type;
};
template <>
struct ADType<RealEigenVector>
{
typedef RealEigenVector type;
};
template <>
struct ADType<VariableValue>
{
typedef ADVariableValue type;
};
template <>
struct ADType<VariableGradient>
{
typedef ADVariableGradient type;
};
template <>
struct ADType<VariableSecond>
{
typedef ADVariableSecond type;
};
template <>
struct ADType<ADReal>
{
typedef ADReal type;
};
template <>
struct ADType<ChainedADReal>
{
typedef ChainedADReal type;
};
template <>
struct ADType<ADRankTwoTensor>
{
typedef ADRankTwoTensor type;
};
template <>
struct ADType<ADRankThreeTensor>
{
typedef ADRankThreeTensor type;
};
template <>
struct ADType<ADRankFourTensor>
{
typedef ADRankFourTensor type;
};
template <>
struct ADType<ADSymmetricRankTwoTensor>
{
typedef ADSymmetricRankTwoTensor type;
};
template <>
struct ADType<ADSymmetricRankFourTensor>
{
typedef ADSymmetricRankFourTensor type;
};
template <>
struct ADType<ADVariableValue>
{
typedef ADVariableValue type;
};
template <>
struct ADType<ADVariableGradient>
{
typedef ADVariableGradient type;
};
template <>
struct ADType<ADVariableSecond>
{
typedef ADVariableSecond type;
};
template <typename T>
struct IsADType
{
static constexpr bool value = false;
};
template <>
struct IsADType<ADReal>
{
static constexpr bool value = true;
};
template <>
struct IsADType<ADPoint>
{
static constexpr bool value = true;
};
template <template <typename T, typename... Args> class W, typename T, typename... Args>
struct IsADType<W<T, Args...>>
{
static constexpr bool value = IsADType<T>::value;
};
template <typename T, typename... Args>
struct IsADType<MetaPhysicL::DualNumber<T, Args...>>
{
static constexpr bool value = true;
};
template <class T>
constexpr std::false_type always_false{};
}
typedef ADRealVectorValue ADRealVectorValue;
typedef ADRealTensorValue ADRealTensorValue;
typedef ADRealGradient ADRealGradient;
template <typename T>
using ADTemplateVariableValue =
typename OutputTools<typename Moose::ADType<T>::type>::VariableValue;
template <typename T>
using ADTemplateVariableGradient =
typename OutputTools<typename Moose::ADType<T>::type>::VariableGradient;
template <typename T>
using ADTemplateVariableSecond =
typename OutputTools<typename Moose::ADType<T>::type>::VariableSecond;
typedef VariableTestValue ADVariableTestValue;
typedef VariableTestGradient ADVariableTestGradient;
typedef VariableTestSecond ADVariableTestSecond;
typedef VectorVariableTestValue ADVectorVariableTestValue;
typedef VectorVariableTestGradient ADVectorVariableTestGradient;
typedef VectorVariableTestSecond ADVectorVariableTestSecond;
template <typename T>
using ADTemplateVariableTestValue = typename OutputTools<T>::VariableTestValue;
template <typename T>
using ADTemplateVariablePhiValue = typename OutputTools<T>::VariablePhiValue;
template <typename T>
using ADTemplateVariableTestGradient =
typename OutputTools<typename Moose::ADType<T>::type>::VariableTestGradient;
template <typename T>
using ADTemplateVariableTestSecond =
typename OutputTools<typename Moose::ADType<T>::type>::VariableTestSecond;
template <typename T>
using ADTemplateVariablePhiGradient =
typename OutputTools<typename Moose::ADType<T>::type>::VariablePhiGradient;
using ADVariablePhiGradient = ADTemplateVariablePhiGradient<Real>;
namespace Moose
{
template <typename T, bool is_ad>
using GenericType = typename std::conditional<is_ad, typename ADType<T>::type, T>::type;
}
template <bool is_ad>
using GenericReal = Moose::GenericType<Real, is_ad>;
template <bool is_ad>
using GenericChainedReal = Moose::GenericType<ChainedReal, is_ad>;
template <bool is_ad>
using GenericRealVectorValue = Moose::GenericType<RealVectorValue, is_ad>;
template <bool is_ad>
using GenericRealTensorValue = Moose::GenericType<RealTensorValue, is_ad>;
template <bool is_ad>
using GenericRankTwoTensor = Moose::GenericType<RankTwoTensor, is_ad>;
template <bool is_ad>
using GenericRankThreeTensor = Moose::GenericType<RankThreeTensor, is_ad>;
template <bool is_ad>
using GenericRankFourTensor = Moose::GenericType<RankFourTensor, is_ad>;
template <bool is_ad>
using GenericVariableValue = Moose::GenericType<VariableValue, is_ad>;
template <bool is_ad>
using GenericVariableGradient = Moose::GenericType<VariableGradient, is_ad>;
template <bool is_ad>
using GenericVariableSecond = Moose::GenericType<VariableSecond, is_ad>;
template <bool is_ad>
using GenericDenseVector = Moose::GenericType<DenseVector<Real>, is_ad>;
template <bool is_ad>
using GenericDenseMatrix = Moose::GenericType<DenseMatrix<Real>, is_ad>;
namespace Moose
{
extern const processor_id_type INVALID_PROCESSOR_ID;
extern const SubdomainID ANY_BLOCK_ID;
extern const SubdomainID INTERNAL_SIDE_LOWERD_ID;
extern const SubdomainID BOUNDARY_SIDE_LOWERD_ID;
extern const SubdomainID INVALID_BLOCK_ID;
extern const BoundaryID ANY_BOUNDARY_ID;
extern const BoundaryID INVALID_BOUNDARY_ID;
extern const TagID INVALID_TAG_ID;
extern const TagTypeID INVALID_TAG_TYPE_ID;
const std::set<SubdomainID> EMPTY_BLOCK_IDS = {};
const std::set<BoundaryID> EMPTY_BOUNDARY_IDS = {};
enum MaterialDataType
{
BLOCK_MATERIAL_DATA,
BOUNDARY_MATERIAL_DATA,
FACE_MATERIAL_DATA,
NEIGHBOR_MATERIAL_DATA,
INTERFACE_MATERIAL_DATA
};
enum AuxGroup
{
PRE_IC = 0,
PRE_AUX = 1,
POST_AUX = 2,
ALL = 3
};
enum VarKindType
{
VAR_SOLVER,
VAR_AUXILIARY,
VAR_ANY
};
enum VarFieldType
{
VAR_FIELD_STANDARD,
VAR_FIELD_SCALAR,
VAR_FIELD_VECTOR,
VAR_FIELD_ARRAY,
VAR_FIELD_ANY
};
enum CouplingType
{
COUPLING_DIAG,
COUPLING_FULL,
COUPLING_CUSTOM
};
enum ConstraintSideType
{
SIDE_PRIMARY,
SIDE_SECONDARY
};
enum DGResidualType
{
Element,
Neighbor
};
enum DGJacobianType
{
ElementElement,
ElementNeighbor,
NeighborElement,
NeighborNeighbor
};
enum ConstraintType
{
Secondary = Element,
Primary = Neighbor
};
enum class ElementType : unsigned int
{
Element = DGResidualType::Element,
Neighbor = DGResidualType::Neighbor,
Lower = DGResidualType::Neighbor + 1
};
enum class MortarType : unsigned int
{
Secondary = static_cast<unsigned int>(Moose::ElementType::Element),
Primary = static_cast<unsigned int>(Moose::ElementType::Neighbor),
Lower = static_cast<unsigned int>(Moose::ElementType::Lower)
};
enum class ComputeType
{
Residual,
Jacobian,
ResidualAndJacobian
};
enum class RESTARTABLE_FILTER : unsigned char
{
RECOVERABLE
};
enum ConstraintJacobianType
{
SecondarySecondary = ElementElement,
SecondaryPrimary = ElementNeighbor,
PrimarySecondary = NeighborElement,
PrimaryPrimary = NeighborNeighbor,
LowerLower,
LowerSecondary,
LowerPrimary,
SecondaryLower,
PrimaryLower
};
enum CoordinateSystemType : int
{
COORD_XYZ = 0,
COORD_RZ,
COORD_RSPHERICAL
};
enum PCSideType
{
PCS_LEFT,
PCS_RIGHT,
PCS_SYMMETRIC,
PCS_DEFAULT
};
enum MooseKSPNormType
{
KSPN_NONE,
KSPN_PRECONDITIONED,
KSPN_UNPRECONDITIONED,
KSPN_NATURAL,
KSPN_DEFAULT
};
enum SolveType
{
ST_PJFNK,
ST_JFNK,
ST_NEWTON,
ST_FD,
ST_LINEAR
};
enum EigenSolveType
{
EST_POWER,
EST_ARNOLDI,
EST_KRYLOVSCHUR,
EST_JACOBI_DAVIDSON,
EST_NONLINEAR_POWER,
EST_NEWTON,
EST_PJFNK,
EST_PJFNKMO,
EST_JFNK
};
enum EigenProblemType
{
EPT_HERMITIAN,
EPT_NON_HERMITIAN,
EPT_GEN_HERMITIAN,
EPT_GEN_INDEFINITE,
EPT_GEN_NON_HERMITIAN,
EPT_POS_GEN_NON_HERMITIAN,
EPT_SLEPC_DEFAULT
};
enum WhichEigenPairs
{
WEP_LARGEST_MAGNITUDE,
WEP_SMALLEST_MAGNITUDE,
WEP_LARGEST_REAL,
WEP_SMALLEST_REAL,
WEP_LARGEST_IMAGINARY,
WEP_SMALLEST_IMAGINARY,
WEP_TARGET_MAGNITUDE,
WEP_TARGET_REAL,
WEP_TARGET_IMAGINARY,
WEP_ALL_EIGENVALUES,
WEP_SLEPC_DEFAULT
};
enum TimeIntegratorType
{
TI_IMPLICIT_EULER,
TI_EXPLICIT_EULER,
TI_CRANK_NICOLSON,
TI_BDF2,
TI_EXPLICIT_MIDPOINT,
TI_LSTABLE_DIRK2,
TI_EXPLICIT_TVD_RK_2,
TI_NEWMARK_BETA
};
enum ConstraintFormulationType
{
Penalty,
Kinematic
};
enum LineSearchType
{
LS_INVALID,
LS_DEFAULT,
LS_NONE,
LS_BASIC,
LS_SHELL,
LS_CONTACT,
LS_PROJECT,
LS_L2,
LS_BT,
LS_CP
};
enum MffdType
{
MFFD_INVALID,
MFFD_WP,
MFFD_DS
};
enum PatchUpdateType
{
Never,
Always,
Auto,
Iteration
};
enum class RelationshipManagerType : unsigned char
{
DEFAULT = 0,
GEOMETRIC = 1 << 0,
ALGEBRAIC = 1 << 1,
COUPLING = 1 << 2
};
enum RMSystemType
{
NONLINEAR,
AUXILIARY,
NONE
};
enum VectorTagType
{
VECTOR_TAG_RESIDUAL = 0,
VECTOR_TAG_SOLUTION = 1,
VECTOR_TAG_ANY = 2
};
typedef std::function<void(const InputParameters &, InputParameters &)>
RelationshipManagerInputParameterCallback;
std::string stringify(const Moose::RelationshipManagerType & t);
std::string stringify(const Moose::TimeIntegratorType & t);
}
namespace libMesh
{
template <>
inline void
print_helper(std::ostream & os, const Moose::RelationshipManagerType * param)
{
os << Moose::stringify(*param);
}
}
template <>
struct enable_bitmask_operators<Moose::RelationshipManagerType>
{
static const bool enable = true;
};
#define DerivativeStringClass(TheName) \
class TheName : public std::string \
{ \
public: \
TheName() : std::string() {} \
TheName(const std::string & str) : std::string(str) {} \
TheName(const std::string & str, size_t pos, size_t n = npos) : std::string(str, pos, n) {} \
TheName(const char * s, size_t n) : std::string(s, n) {} \
TheName(const char * s) : std::string(s) {} \
TheName(size_t n, char c) : std::string(n, c) {} \
}; \
namespace nlohmann \
{ \
template <> \
struct adl_serializer<TheName> \
{ \
static void to_json(json & j, const TheName & v); \
}; \
} \
static_assert(true, "")
DerivativeStringClass(FileName);
DerivativeStringClass(FileNameNoExtension);
DerivativeStringClass(RelativeFileName);
DerivativeStringClass(DataFileName);
DerivativeStringClass(MeshFileName);
DerivativeStringClass(MatrixFileName);
DerivativeStringClass(OutFileBase);
DerivativeStringClass(NonlinearVariableName);
DerivativeStringClass(LinearVariableName);
DerivativeStringClass(SolverVariableName);
DerivativeStringClass(AuxVariableName);
DerivativeStringClass(VariableName);
DerivativeStringClass(BoundaryName);
DerivativeStringClass(SubdomainName);
DerivativeStringClass(PostprocessorName);
DerivativeStringClass(VectorPostprocessorName);
DerivativeStringClass(MeshDivisionName);
DerivativeStringClass(FunctionName);
DerivativeStringClass(DistributionName);
DerivativeStringClass(SamplerName);
DerivativeStringClass(UserObjectName);
DerivativeStringClass(IndicatorName);
DerivativeStringClass(MarkerName);
DerivativeStringClass(MultiAppName);
DerivativeStringClass(OutputName);
DerivativeStringClass(MaterialPropertyName);
DerivativeStringClass(MooseFunctorName);
DerivativeStringClass(MaterialName);
DerivativeStringClass(TagName);
DerivativeStringClass(MeshGeneratorName);
DerivativeStringClass(ExtraElementIDName);
DerivativeStringClass(ReporterValueName);
DerivativeStringClass(ComponentName);
DerivativeStringClass(PhysicsName);
DerivativeStringClass(PositionsName);
DerivativeStringClass(TimesName);
DerivativeStringClass(ExecutorName);
DerivativeStringClass(ParsedFunctionExpression);
DerivativeStringClass(NonlinearSystemName);
DerivativeStringClass(LinearSystemName);
DerivativeStringClass(SolverSystemName);
DerivativeStringClass(CLIArgString);
typedef std::vector<VariableName> CoupledName;
namespace Moose
{
extern const TagName SOLUTION_TAG;
extern const TagName OLD_SOLUTION_TAG;
extern const TagName OLDER_SOLUTION_TAG;
extern const TagName PREVIOUS_NL_SOLUTION_TAG;
}
#define usingTensorIndices(...) \
enum \
{ \
__VA_ARGS__ \
}