12 #ifndef MFEM_BILININTEG
13 #define MFEM_BILININTEG
15 #include "../config/config.hpp"
95 const bool add =
true);
128 const bool add =
true);
132 const bool add =
true);
221 Vector &flux,
bool with_coef =
true) { }
262 { bfi = bfi_; own_bfi = own_bfi_; }
331 { bfi = bfi_; own_bfi = own_bfi_; }
351 { integrator = integ; own_integrator = own_integ; }
376 { integrators.Append(integ); }
470 return "MixedScalarIntegrator: "
471 "Trial and test spaces must both be scalar fields.";
494 #ifndef MFEM_THREAD_SAFE
544 return "MixedVectorIntegrator: "
545 "Trial and test spaces must both be vector fields";
571 #ifndef MFEM_THREAD_SAFE
607 bool cross_2d_ =
false)
627 return "MixedScalarVectorIntegrator: "
628 "Trial space must be a vector field "
629 "and the test space must be a scalar field";
633 return "MixedScalarVectorIntegrator: "
634 "Trial space must be a scalar field "
635 "and the test space must be a vector field";
661 #ifndef MFEM_THREAD_SAFE
705 return (trial_fe.
GetDim() == 1 && test_fe.
GetDim() == 1 &&
712 return "MixedScalarDerivativeIntegrator: "
713 "Trial and test spaces must both be scalar fields in 1D "
714 "and the trial space must implement CalcDShape.";
740 return (trial_fe.
GetDim() == 1 && test_fe.
GetDim() == 1 &&
747 return "MixedScalarWeakDerivativeIntegrator: "
748 "Trial and test spaces must both be scalar fields in 1D "
749 "and the test space must implement CalcDShape with "
750 "map type \"VALUE\".";
784 return "MixedScalarDivergenceIntegrator: "
785 "Trial must be H(Div) and the test space must be a "
820 return "MixedVectorDivergenceIntegrator: "
821 "Trial must be H(Div) and the test space must be a "
859 return "MixedScalarWeakGradientIntegrator: "
860 "Trial space must be a scalar field "
861 "and the test space must be H(Div)";
893 return (trial_fe.
GetDim() == 2 && test_fe.
GetDim() == 2 &&
900 return "MixedScalarCurlIntegrator: "
901 "Trial must be H(Curl) and the test space must be a "
934 return (trial_fe.
GetDim() == 2 && test_fe.
GetDim() == 2 &&
941 return "MixedScalarWeakCurlIntegrator: "
942 "Trial space must be a scalar field "
943 "and the test space must be H(Curl)";
998 return "MixedDotProductIntegrator: "
999 "Trial space must be a vector field "
1000 "and the test space must be a scalar field";
1024 return "MixedWeakGradDotIntegrator: "
1025 "Trial space must be a vector field "
1026 "and the test space must be a vector field with a divergence";
1054 return (trial_fe.
GetDim() == 3 && test_fe.
GetDim() == 3 &&
1062 return "MixedWeakDivCrossIntegrator: "
1063 "Trial space must be a vector field in 3D "
1064 "and the test space must be a scalar field with a gradient";
1099 return "MixedGradGradIntegrator: "
1100 "Trial and test spaces must both be scalar fields "
1101 "with a gradient operator.";
1145 return "MixedCrossGradGradIntegrator: "
1146 "Trial and test spaces must both be scalar fields "
1147 "with a gradient operator.";
1179 return (trial_fe.
GetDim() == 3 && test_fe.
GetDim() == 3 &&
1188 return "MixedCurlCurlIntegrator"
1189 "Trial and test spaces must both be vector fields in 3D "
1216 return (trial_fe.
GetDim() == 3 && test_fe.
GetDim() == 3 &&
1225 return "MixedCrossCurlCurlIntegrator: "
1226 "Trial and test spaces must both be vector fields in 3D "
1253 return (trial_fe.
GetDim() == 3 && test_fe.
GetDim() == 3 &&
1262 return "MixedCrossCurlGradIntegrator"
1263 "Trial space must be a vector field in 3D with a curl"
1264 "and the test space must be a scalar field with a gradient";
1290 return (trial_fe.
GetDim() == 3 && test_fe.
GetDim() == 3 &&
1299 return "MixedCrossGradCurlIntegrator"
1300 "Trial space must be a scalar field in 3D with a gradient"
1301 "and the test space must be a vector field with a curl";
1328 return (trial_fe.
GetDim() == 3 && test_fe.
GetDim() == 3 &&
1336 return "MixedWeakCurlCrossIntegrator: "
1337 "Trial space must be a vector field in 3D "
1338 "and the test space must be a vector field with a curl";
1360 return (trial_fe.
GetDim() == 2 && test_fe.
GetDim() == 2 &&
1368 return "MixedScalarWeakCurlCrossIntegrator: "
1369 "Trial space must be a vector field in 2D "
1370 "and the test space must be a vector field with a curl";
1395 return (trial_fe.
GetDim() == 3 && test_fe.
GetDim() == 3 &&
1403 return "MixedCrossGradIntegrator: "
1404 "Trial space must be a scalar field with a gradient operator"
1405 " and the test space must be a vector field both in 3D.";
1432 return (trial_fe.
GetDim() == 3 && test_fe.
GetDim() == 3 &&
1440 return "MixedCrossCurlIntegrator: "
1441 "Trial space must be a vector field in 3D with a curl "
1442 "and the test space must be a vector field";
1464 return (trial_fe.
GetDim() == 2 && test_fe.
GetDim() == 2 &&
1472 return "MixedCrossCurlIntegrator: "
1473 "Trial space must be a vector field in 2D with a curl "
1474 "and the test space must be a vector field";
1498 return (trial_fe.
GetDim() == 2 && test_fe.
GetDim() == 2 &&
1506 return "MixedScalarCrossGradIntegrator: "
1507 "Trial space must be a scalar field in 2D with a gradient "
1508 "and the test space must be a scalar field";
1529 return (trial_fe.
GetDim() == 2 && test_fe.
GetDim() == 2 &&
1536 return "MixedScalarCrossProductIntegrator: "
1537 "Trial space must be a vector field in 2D "
1538 "and the test space must be a scalar field";
1554 return (trial_fe.
GetDim() == 2 && test_fe.
GetDim() == 2 &&
1561 return "MixedScalarWeakCrossProductIntegrator: "
1562 "Trial space must be a scalar field in 2D "
1563 "and the test space must be a vector field";
1591 return "MixedDirectionalDerivativeIntegrator: "
1592 "Trial space must be a scalar field with a gradient "
1593 "and the test space must be a scalar field";
1622 return "MixedGradDivIntegrator: "
1623 "Trial space must be a scalar field with a gradient"
1624 "and the test space must be a vector field with a divergence";
1659 return "MixedDivGradIntegrator: "
1660 "Trial space must be a vector field with a divergence"
1661 "and the test space must be a scalar field with a gradient";
1694 return "MixedScalarWeakDivergenceIntegrator: "
1695 "Trial space must be a scalar field "
1696 "and the test space must be a scalar field with a gradient";
1730 return "MixedVectorGradientIntegrator: "
1731 "Trial spaces must be H1 and the test space must be a "
1732 "vector field in 2D or 3D";
1756 int dim, ne, dofs1D, quad1D;
1778 return (trial_fe.
GetDim() == 3 && test_fe.
GetDim() == 3 &&
1785 return "MixedVectorCurlIntegrator: "
1786 "Trial space must be H(Curl) and the test space must be a "
1787 "vector field in 3D";
1811 int dim, ne, dofs1D, dofs1Dtest,quad1D, testType, trialType, coeffDim;
1833 return (trial_fe.
GetDim() == 3 && test_fe.
GetDim() == 3 &&
1840 return "MixedVectorWeakCurlIntegrator: "
1841 "Trial space must be vector field in 3D and the "
1842 "test space must be H(Curl)";
1864 int dim, ne, dofs1D, quad1D, testType, trialType, coeffDim;
1892 return "MixedVectorWeakDivergenceIntegrator: "
1893 "Trial space must be vector field and the "
1894 "test space must be H1";
1924 const DofToQuad *trial_maps, *test_maps;
1927 int trial_dofs1D, test_dofs1D, quad1D;
1931 Q{NULL}, trial_maps{NULL}, test_maps{NULL}, geom{NULL}
1934 Q{q_}, trial_maps{NULL}, test_maps{NULL}, geom{NULL}
1937 Q{&q}, trial_maps{NULL}, test_maps{NULL}, geom{NULL}
1941 const FiniteElement &test_fe,
1942 ElementTransformation &
Trans,
1943 DenseMatrix &elmat);
1946 virtual void AssemblePA(
const FiniteElementSpace &trial_fes,
1947 const FiniteElementSpace &test_fes);
1949 virtual void AddMultPA(
const Vector &x, Vector &y)
const;
1952 static const IntegrationRule &
GetRule(
const FiniteElement &trial_fe,
1953 const FiniteElement &test_fe,
1954 ElementTransformation &
Trans);
1968 Vector vec, vecdxt, pointflux, shape;
1969 #ifndef MFEM_THREAD_SAFE
1970 DenseMatrix dshape, dshapedxt, invdfdx, M, dshapedxt_m;
1979 int dim, ne, dofs1D, quad1D;
1981 bool symmetric =
true;
1986 :
Q(NULL),
VQ(NULL),
MQ(NULL),
SMQ(NULL), maps(NULL), geom(NULL) { }
1990 :
Q(&q),
VQ(NULL),
MQ(NULL),
SMQ(NULL), maps(NULL), geom(NULL) { }
1994 :
Q(NULL),
VQ(&q),
MQ(NULL),
SMQ(NULL), maps(NULL), geom(NULL) { }
1998 :
Q(NULL),
VQ(NULL),
MQ(&q),
SMQ(NULL), maps(NULL), geom(NULL) { }
2002 :
Q(NULL),
VQ(NULL),
MQ(NULL),
SMQ(&q), maps(NULL), geom(NULL) { }
2024 Vector &flux,
bool with_coef =
true);
2059 #ifndef MFEM_THREAD_SAFE
2141 #ifndef MFEM_THREAD_SAFE
2143 Vector shape, vec2, BdFidxT;
2218 Vector shape, te_shape, vec;
2236 : vdim(-1), Q_order(0),
Q(NULL),
VQ(NULL),
MQ(NULL) { }
2241 : vdim(-1), Q_order(qo),
Q(&q),
VQ(NULL),
MQ(NULL) { }
2247 : vdim(q.
GetVDim()), Q_order(qo),
Q(NULL),
VQ(&q),
MQ(NULL) { }
2250 : vdim(q.
GetVDim()), Q_order(qo),
Q(NULL),
VQ(NULL),
MQ(&q) { }
2293 #ifndef MFEM_THREAD_SAFE
2302 int dim, ne, dofs1D, L2dofs1D, quad1D;
2327 #ifndef MFEM_THREAD_SAFE
2354 #ifndef MFEM_THREAD_SAFE
2400 #ifndef MFEM_THREAD_SAFE
2443 Vector &flux,
bool with_coef);
2460 #ifndef MFEM_THREAD_SAFE
2461 DenseMatrix dshape_hat, dshape, curlshape, Jadj, grad_hat, grad;
2491 {
Q = q;
DQ = dq;
MQ = mq;
SMQ = smq; }
2493 #ifndef MFEM_THREAD_SAFE
2560 const DofToQuad *trial_maps, *test_maps;
2563 int trial_dofs1D, test_dofs1D, quad1D;
2567 Q(NULL), trial_maps(NULL), test_maps(NULL), geom(NULL)
2570 Q(q_), trial_maps(NULL), test_maps(NULL), geom(NULL)
2573 Q(&q), trial_maps(NULL), test_maps(NULL), geom(NULL)
2605 #ifndef MFEM_THREAD_SAFE
2614 int dim, ne, dofs1D, quad1D;
2666 : vdim(vector_dimension) { }
2680 :
Q(&q), vdim(vector_dimension) { }
2692 :
VQ(&vq), vdim(vq.GetVDim()) { }
2704 :
MQ(&mq), vdim(mq.GetVDim()) { }
2734 #ifndef MFEM_THREAD_SAFE
2764 Vector &flux,
bool with_coef =
true);
3038 double alpha_,
double kappa_)
3051 #ifndef MFEM_THREAD_SAFE
3073 const int dim,
const int row_ndofs,
const int col_ndofs,
3074 const int row_offset,
const int col_offset,
3075 const double jmatcoef,
const Vector &col_nL,
const Vector &col_nM,
3087 Vector face_shape, shape1, shape2;
3105 Vector face_shape, normal, shape1_n, shape2_n;
3158 int dim, ne, o_dofs1D, c_dofs1D;
3172 { ran_fe.
Project(dom_fe, Trans, elmat); }
3188 int dim, ne, o_dofs1D, c_dofs1D;
3342 template<const
int T_SDIM>
Abstract class for all finite elements.
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
virtual void CalcVShape(const FiniteElement &vector_fe, ElementTransformation &Trans, DenseMatrix &shape)
VectorCurlCurlIntegrator()
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
virtual void AssembleElementMatrix(const FiniteElement &fe, ElementTransformation &Trans, DenseMatrix &elmat)
Support for use in BilinearForm. Can be used only when appropriate.
DiagonalMatrixCoefficient * DQ
virtual void AddMultMF(const Vector &x, Vector &y) const
virtual const char * FiniteElementTypeFailureMessage() const
virtual void AssembleElementMatrix(const FiniteElement &fe, ElementTransformation &Trans, DenseMatrix &elmat)
Support for use in BilinearForm. Can be used only when appropriate.
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
VectorFEMassIntegrator(Coefficient &q)
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
virtual void AssemblePA(const FiniteElementSpace &fes)
Method defining partial assembly.
int GetDim() const
Returns the reference space dimension for the finite element.
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
virtual const char * FiniteElementTypeFailureMessage() const
Class for an integration rule - an Array of IntegrationPoint.
const DofToQuad * mapsO
Not owned. DOF-to-quad map, open.
virtual void CalcTestShape(const FiniteElement &test_fe, ElementTransformation &Trans, Vector &shape)
MixedCrossCurlGradIntegrator(VectorCoefficient &vq)
bool symmetric
False if using a nonsymmetric matrix coefficient.
virtual void AssemblePAInteriorFaces(const FiniteElementSpace &fes)
virtual void SetIntRule(const IntegrationRule *ir)
Prescribe a fixed IntegrationRule to use (when ir != NULL) or let the integrator choose (when ir == N...
MixedGradDivIntegrator(VectorCoefficient &vq)
virtual void CalcTrialShape(const FiniteElement &trial_fe, ElementTransformation &Trans, DenseMatrix &shape)
DGDiffusionIntegrator(Coefficient &q, const double s, const double k)
Integrator defining a sum of multiple Integrators.
SumIntegrator(int own_integs=1)
virtual void AssembleFaceMatrix(const FiniteElement &el1, const FiniteElement &el2, FaceElementTransformations &Trans, DenseMatrix &elmat)
static const IntegrationRule & GetRule(Geometry::Type geom, int order, FaceElementTransformations &T)
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
virtual void CalcVShape(const IntegrationPoint &ip, DenseMatrix &shape) const
Evaluate the values of all shape functions of a vector finite element in reference space at the given...
virtual const char * FiniteElementTypeFailureMessage() const
NonconservativeDGTraceIntegrator(VectorCoefficient &u, double a)
virtual const char * FiniteElementTypeFailureMessage() const
DiffusionIntegrator(Coefficient &q)
Construct a diffusion integrator with a scalar coefficient q.
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
MixedScalarCrossProductIntegrator(VectorCoefficient &vq)
virtual void AssembleDiagonalMF(Vector &diag)
Assemble diagonal and add it to Vector diag.
virtual void CalcTrialShape(const FiniteElement &trial_fe, ElementTransformation &Trans, DenseMatrix &shape)
virtual void ProjectDiv(const FiniteElement &fe, ElementTransformation &Trans, DenseMatrix &div) const
Compute the discrete divergence matrix from the given FiniteElement onto 'this' FiniteElement. The ElementTransformation is included to support cases when the matrix depends on it.
Base class for vector Coefficients that optionally depend on time and space.
virtual const char * FiniteElementTypeFailureMessage() const
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
virtual void CalcTrialShape(const FiniteElement &trial_fe, ElementTransformation &Trans, DenseMatrix &shape)
virtual int GetIntegrationOrder(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans)
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
virtual void Project(Coefficient &coeff, ElementTransformation &Trans, Vector &dofs) const
Given a coefficient and a transformation, compute its projection (approximation) in the local finite ...
virtual double ComputeFluxEnergy(const FiniteElement &fluxelem, ElementTransformation &Trans, Vector &flux, Vector *d_energy=NULL)
Virtual method required for Zienkiewicz-Zhu type error estimators.
MixedVectorCurlIntegrator()
void CalcPhysDivShape(ElementTransformation &Trans, Vector &divshape) const
Evaluate the divergence of all shape functions of a vector finite element in physical space at the po...
virtual void AssemblePAInteriorFaces(const FiniteElementSpace &fes)
virtual void CalcShape(const FiniteElement &scalar_fe, ElementTransformation &Trans, Vector &shape)
ElasticityIntegrator(Coefficient &l, Coefficient &m)
bool SupportsCeed() const
Indicates whether this integrator can use a Ceed backend.
NormalTraceJumpIntegrator()
VectorDiffusionIntegrator(Coefficient &q)
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
virtual void AddMultTransposePA(const Vector &, Vector &) const
Method for partially assembled transposed action.
constexpr int HDIV_MAX_D1D
virtual void CalcTestShape(const FiniteElement &test_fe, ElementTransformation &Trans, Vector &shape)
const GeometricFactors * geom
Not owned.
virtual void AssembleEABoundaryFaces(const FiniteElementSpace &fes, Vector &ea_data_bdr, const bool add)
SymmetricMatrixCoefficient * SMQ
virtual void CalcTrialShape(const FiniteElement &trial_fe, ElementTransformation &Trans, Vector &shape)
Integrator for (curl u, curl v) for Nedelec elements.
MixedVectorMassIntegrator()
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
DGTraceIntegrator(VectorCoefficient &u_, double a, double b)
Construct integrator with rho = 1.
VectorCurlCurlIntegrator(Coefficient &q)
virtual void CalcTestShape(const FiniteElement &test_fe, ElementTransformation &Trans, Vector &shape)
virtual const char * FiniteElementTypeFailureMessage() const
virtual void AssembleFaceMatrix(const FiniteElement &el1, const FiniteElement &el2, FaceElementTransformations &Trans, DenseMatrix &elmat)
virtual void AddMultTransposePA(const Vector &x, Vector &y) const
Method for partially assembled transposed action.
void PADiffusionSetup2D(const int Q1D, const int coeffDim, const int NE, const Array< double > &w, const Vector &j, const Vector &c, Vector &d)
MixedScalarVectorIntegrator(VectorCoefficient &vq, bool transpose_=false, bool cross_2d_=false)
virtual void AssemblePA(const FiniteElementSpace &trial_fes, const FiniteElementSpace &test_fes)
MixedScalarMassIntegrator(Coefficient &q)
VectorMassIntegrator(Coefficient &q, const IntegrationRule *ir)
virtual void CalcTestShape(const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &shape)
alpha (q . grad u, v) using the "group" FE discretization
virtual void AssemblePA(const FiniteElementSpace &fes)
Method defining partial assembly.
const GeometricFactors * geom
Not owned.
virtual void SetIntRule(const IntegrationRule *ir)
Prescribe a fixed IntegrationRule to use (when ir != NULL) or let the integrator choose (when ir == N...
virtual void AddMultPA(const Vector &x, Vector &y) const
Method for partially assembled action.
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
virtual void AssembleFaceMatrix(const FiniteElement &el1, const FiniteElement &el2, FaceElementTransformations &Trans, DenseMatrix &elmat)
ScalarCrossProductInterpolator(VectorCoefficient &vc)
VectorDiffusionIntegrator()
int GetOrder() const
Returns the order of the finite element. In the case of anisotropic orders, returns the maximum order...
bool SupportsCeed() const
Indicates whether this integrator can use a Ceed backend.
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
MixedGradGradIntegrator(DiagonalMatrixCoefficient &dq)
virtual void AddMultPA(const Vector &x, Vector &y) const
Method for partially assembled action.
virtual void AssembleEA(const FiniteElementSpace &fes, Vector &emat, const bool add)
Method defining element assembly.
Data type dense matrix using column-major storage.
virtual void AssemblePAInteriorFaces(const FiniteElementSpace &fes)
DivDivIntegrator(Coefficient &q)
int Size() const
Returns the size of the vector.
virtual int GetIntegrationOrder(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans)
virtual void CalcTrialShape(const FiniteElement &trial_fe, ElementTransformation &Trans, DenseMatrix &shape)
MixedVectorWeakCurlIntegrator(MatrixCoefficient &mq)
virtual void CalcShape(const FiniteElement &scalar_fe, ElementTransformation &Trans, Vector &shape)
virtual void AddMultPA(const Vector &x, Vector &y) const
Method for partially assembled action.
virtual const char * FiniteElementTypeFailureMessage() const
virtual void AddMultTransposePA(const Vector &x, Vector &y) const
Method for partially assembled transposed action.
virtual void CalcTestShape(const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &shape)
virtual void AssembleFaceMatrix(const FiniteElement &el1, const FiniteElement &el2, FaceElementTransformations &Trans, DenseMatrix &elmat)
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
const DofToQuad * maps
Not owned.
virtual void AssembleDiagonalMF(Vector &diag)
Assemble diagonal and add it to Vector diag.
virtual ~TransposeIntegrator()
DGTraceIntegrator(Coefficient &rho_, VectorCoefficient &u_, double a, double b)
virtual void AssemblePA(const FiniteElementSpace &fes)
Method defining partial assembly.
VectorFEDivergenceIntegrator()
int Space() const
Returns the type of FunctionSpace on the element.
virtual void AssemblePA(const FiniteElementSpace &fes)
Method defining partial assembly.
static const IntegrationRule & GetRule(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans)
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
void AddIntegrator(BilinearFormIntegrator *integ)
const DofToQuad * mapsC
Not owned. DOF-to-quad map, closed.
virtual const char * FiniteElementTypeFailureMessage() const
VectorFEMassIntegrator(SymmetricMatrixCoefficient *smq)
Structure for storing mesh geometric factors: coordinates, Jacobians, and determinants of the Jacobia...
Array< int > ipiv_offsets
virtual void CalcTrialShape(const FiniteElement &trial_fe, ElementTransformation &Trans, Vector &shape)
virtual void ComputeElementFlux(const FiniteElement &el, ElementTransformation &Trans, Vector &u, const FiniteElement &fluxelem, Vector &flux, bool with_coef)
Virtual method required for Zienkiewicz-Zhu type error estimators.
virtual void AddMultPA(const Vector &x, Vector &y) const
Method for partially assembled action.
MixedCrossProductIntegrator(VectorCoefficient &vq)
VectorDiffusionIntegrator(int vector_dimension)
Integrator with unit coefficient for caller-specified vector dimension.
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
virtual void ProjectGrad(const FiniteElement &fe, ElementTransformation &Trans, DenseMatrix &grad) const
Compute the discrete gradient matrix from the given FiniteElement onto 'this' FiniteElement. The ElementTransformation is included to support cases when the matrix depends on it.
double * GetData() const
Return a pointer to the beginning of the Vector data.
virtual void CalcTrialShape(const FiniteElement &trial_fe, ElementTransformation &Trans, DenseMatrix &shape)
MixedVectorWeakDivergenceIntegrator(DiagonalMatrixCoefficient &dq)
MixedVectorGradientIntegrator(Coefficient &q)
(Q div u, div v) for RT elements
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
virtual void ComputeElementFlux(const FiniteElement &el, ElementTransformation &Trans, Vector &u, const FiniteElement &fluxelem, Vector &flux, bool with_coef=true)
virtual const char * FiniteElementTypeFailureMessage() const
virtual void AssembleMF(const FiniteElementSpace &fes)
Method defining matrix-free assembly.
virtual void AddMultPA(const Vector &, Vector &) const
Method for partially assembled action.
MixedScalarCrossGradIntegrator(VectorCoefficient &vq)
virtual void CalcTrialShape(const FiniteElement &trial_fe, ElementTransformation &Trans, DenseMatrix &shape)
void add(const Vector &v1, const Vector &v2, Vector &v)
const DofToQuad * maps
Not owned.
virtual void AssembleFaceMatrix(const FiniteElement &el1, const FiniteElement &el2, FaceElementTransformations &Trans, DenseMatrix &elmat)
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
virtual void AssembleDiagonalPA(Vector &diag)
Assemble diagonal and add it to Vector diag.
virtual void AssembleDiagonalPA(Vector &diag)
Assemble diagonal and add it to Vector diag.
void CalcPhysCurlShape(ElementTransformation &Trans, DenseMatrix &curl_shape) const
Evaluate the curl of all shape functions of a vector finite element in physical space at the point de...
virtual ~LumpedIntegrator()
virtual void CalcVShape(const FiniteElement &vector_fe, ElementTransformation &Trans, DenseMatrix &shape)
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
virtual void CalcTestShape(const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &shape)
const GeometricFactors * geom
Not owned.
MixedCurlCurlIntegrator(MatrixCoefficient &mq)
virtual void AssemblePA(const FiniteElementSpace &fes)
Method defining partial assembly.
VectorDiffusionIntegrator(Coefficient &q, int vector_dimension)
Integrator with scalar coefficient for caller-specified vector dimension.
VectorMassIntegrator()
Construct an integrator with coefficient 1.0.
virtual void CalcShape(const FiniteElement &scalar_fe, ElementTransformation &Trans, Vector &shape)
VectorMassIntegrator(VectorCoefficient &q, int qo=0)
Construct an integrator with diagonal coefficient q.
Structure for storing face geometric factors: coordinates, Jacobians, determinants of the Jacobians...
VectorCrossProductInterpolator(VectorCoefficient &vc)
virtual void AddMultTransposeMF(const Vector &x, Vector &y) const
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
NonconservativeDGTraceIntegrator(VectorCoefficient &u, double a, double b)
virtual void CalcShape(const FiniteElement &scalar_fe, ElementTransformation &Trans, Vector &shape)
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
virtual void AssembleElementMatrix2(const FiniteElement &dom_fe, const FiniteElement &ran_fe, ElementTransformation &Trans, DenseMatrix &elmat)
virtual void AssemblePA(const FiniteElementSpace &fes)
Method defining partial assembly.
virtual void AddMultPA(const Vector &, Vector &) const
Method for partially assembled action.
virtual void AssembleElementMatrix2(const FiniteElement &dom_fe, const FiniteElement &ran_fe, ElementTransformation &Trans, DenseMatrix &elmat)
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
Integrator that inverts the matrix assembled by another integrator.
virtual void ProjectCurl(const FiniteElement &fe, ElementTransformation &Trans, DenseMatrix &curl) const
Compute the discrete curl matrix from the given FiniteElement onto 'this' FiniteElement. The ElementTransformation is included to support cases when the matrix depends on it.
virtual void CalcTestShape(const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &shape)
NonconservativeDGTraceIntegrator(Coefficient &rho, VectorCoefficient &u, double a, double b)
ElasticityIntegrator(Coefficient &m, double q_l, double q_m)
virtual const char * FiniteElementTypeFailureMessage() const
virtual void AssembleDiagonalMF(Vector &diag)
Assemble diagonal and add it to Vector diag.
-alpha (u, q . grad v), negative transpose of ConvectionIntegrator
virtual void AssembleFaceMatrix(const FiniteElement &trial_face_fe, const FiniteElement &test_fe1, const FiniteElement &test_fe2, FaceElementTransformations &Trans, DenseMatrix &elmat)
virtual const char * FiniteElementTypeFailureMessage() const
virtual void CalcVShape(const FiniteElement &vector_fe, ElementTransformation &Trans, DenseMatrix &shape)
virtual void AddMultPA(const Vector &x, Vector &y) const
Method for partially assembled action.
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
VectorInnerProductInterpolator(VectorCoefficient &vc)
MixedWeakDivCrossIntegrator(VectorCoefficient &vq)
virtual const char * FiniteElementTypeFailureMessage() const
virtual void AddMultMF(const Vector &, Vector &) const
virtual const char * FiniteElementTypeFailureMessage() const
VectorDiffusionIntegrator(MatrixCoefficient &mq)
Integrator with MatrixCoefficient. The vector dimension of the FiniteElementSpace is assumed to be th...
MixedScalarWeakGradientIntegrator()
MixedVectorGradientIntegrator()
virtual void AssembleEA(const FiniteElementSpace &fes, Vector &emat, const bool add)
Method defining element assembly.
VectorDivergenceIntegrator(Coefficient &q)
MixedCrossCurlCurlIntegrator(VectorCoefficient &vq)
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
virtual void AssemblePA(const FiniteElementSpace &trial_fes, const FiniteElementSpace &test_fes)
VectorFEMassIntegrator(SymmetricMatrixCoefficient &smq)
virtual void CalcTestShape(const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &shape)
virtual void AddMultTransposePA(const Vector &x, Vector &y) const
Method for partially assembled transposed action.
virtual void AssemblePA(const FiniteElementSpace &trial_fes, const FiniteElementSpace &test_fes)
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
DGDiffusionBR2Integrator(class FiniteElementSpace *fes, double e=1.0)
virtual void SetIntRule(const IntegrationRule *ir)
Prescribe a fixed IntegrationRule to use (when ir != NULL) or let the integrator choose (when ir == N...
virtual void AddMultPA(const Vector &, Vector &) const
Method for partially assembled action.
MixedScalarWeakCurlIntegrator(Coefficient &q)
MixedCurlCurlIntegrator(Coefficient &q)
DiffusionIntegrator(VectorCoefficient &q)
Construct a diffusion integrator with a vector coefficient q.
GradientIntegrator(Coefficient &q)
virtual double ComputeFluxEnergy(const FiniteElement &fluxelem, ElementTransformation &Trans, Vector &flux, Vector *d_energy=NULL)
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
virtual void AssemblePA(const FiniteElementSpace &fes)
Method defining partial assembly.
DGTraceIntegrator(VectorCoefficient &u_, double a)
Construct integrator with rho = 1, b = 0.5*a.
virtual const char * FiniteElementTypeFailureMessage() const
const DofToQuad * mapsC
Not owned. DOF-to-quad map, closed.
virtual void AssembleMF(const FiniteElementSpace &fes)
Method defining matrix-free assembly.
virtual void AddMultPA(const Vector &x, Vector &y) const
Method for partially assembled action.
TransposeIntegrator(BilinearFormIntegrator *bfi_, int own_bfi_=1)
static const IntegrationRule & GetRule(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans)
MixedVectorWeakCurlIntegrator(DiagonalMatrixCoefficient &dq)
VectorFEDivergenceIntegrator(Coefficient &q)
constexpr int HCURL_MAX_D1D
virtual void AssemblePA(const FiniteElementSpace &trial_fes, const FiniteElementSpace &test_fes)
virtual void CalcTrialShape(const FiniteElement &trial_fe, ElementTransformation &Trans, DenseMatrix &shape)
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
virtual void AddMultMF(const Vector &, Vector &) const
virtual void AddMultMF(const Vector &x, Vector &y) const
virtual void AddMultTransposePA(const Vector &x, Vector &y) const
Method for partially assembled transposed action.
VectorFEMassIntegrator(MatrixCoefficient *mq_)
virtual void AssembleMF(const FiniteElementSpace &fes)
Method defining matrix-free assembly.
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
VectorFECurlIntegrator(Coefficient &q)
virtual void AssembleElementMatrix2(const FiniteElement &h1_fe, const FiniteElement &nd_fe, ElementTransformation &Trans, DenseMatrix &elmat)
MixedVectorWeakCurlIntegrator()
virtual void CalcTestShape(const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &shape)
virtual const char * FiniteElementTypeFailureMessage() const
DiffusionIntegrator()
Construct a diffusion integrator with coefficient Q = 1.
MixedVectorMassIntegrator(MatrixCoefficient &mq)
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
MixedScalarDivergenceIntegrator(Coefficient &q)
Array< int > Minv_offsets
MixedVectorIntegrator(MatrixCoefficient &mq)
virtual void AssembleDiagonalMF(Vector &diag)
Assemble diagonal and add it to Vector diag.
virtual void AssembleEABoundaryFaces(const FiniteElementSpace &fes, Vector &ea_data_bdr, const bool add)
virtual void AssembleEA(const FiniteElementSpace &fes, Vector &emat, const bool add)
Method defining element assembly.
virtual void CalcTestShape(const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &shape)
MixedVectorMassIntegrator(Coefficient &q)
virtual void AssemblePABoundaryFaces(const FiniteElementSpace &fes)
void CalcPhysDShape(ElementTransformation &Trans, DenseMatrix &dshape) const
Evaluate the gradients of all shape functions of a scalar finite element in physical space at the poi...
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
MixedDirectionalDerivativeIntegrator(VectorCoefficient &vq)
MixedScalarMassIntegrator()
MixedScalarDerivativeIntegrator()
virtual void AssemblePA(const FiniteElementSpace &trial_fes, const FiniteElementSpace &test_fes)
virtual ~GradientInterpolator()
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
DiagonalMatrixCoefficient * DQ
virtual void AssembleEA(const FiniteElementSpace &fes, Vector &emat, const bool add)
Method defining element assembly.
virtual void AddMultTransposePA(const Vector &, Vector &) const
Method for partially assembled transposed action.
MixedCrossGradIntegrator(VectorCoefficient &vq)
virtual int GetIntegrationOrder(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans)
GradientIntegrator(Coefficient *q_)
virtual void AddMultPA(const Vector &, Vector &) const
Method for partially assembled action.
ScalarProductInterpolator(Coefficient &sc)
virtual void AddMultPA(const Vector &x, Vector &y) const
Method for partially assembled action.
virtual void AssembleMF(const FiniteElementSpace &fes)
Method defining matrix-free assembly.
MixedGradGradIntegrator()
virtual const char * FiniteElementTypeFailureMessage() const
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
ConservativeConvectionIntegrator(VectorCoefficient &q, double a=1.0)
virtual void AddMultTransposePA(const Vector &x, Vector &y) const
Method for partially assembled transposed action.
virtual void CalcTrialShape(const FiniteElement &trial_fe, ElementTransformation &Trans, DenseMatrix &shape)
bool SupportsCeed() const
Indicates whether this integrator can use a Ceed backend.
MixedVectorCurlIntegrator(MatrixCoefficient &mq)
virtual void CalcTestShape(const FiniteElement &test_fe, ElementTransformation &Trans, Vector &shape)
virtual const char * FiniteElementTypeFailureMessage() const
BoundaryMassIntegrator(Coefficient &q)
virtual void AddMultPA(const Vector &x, Vector &y) const
Method for partially assembled action.
virtual void AssembleElementMatrix(const FiniteElement &, ElementTransformation &, DenseMatrix &)
Given a particular Finite Element computes the element matrix elmat.
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
virtual void AddMultTransposePA(const Vector &x, Vector &y) const
Method for partially assembled transposed action.
virtual void CalcShape(const FiniteElement &scalar_fe, ElementTransformation &Trans, Vector &shape)
MixedScalarWeakDerivativeIntegrator()
virtual void AssemblePA(const FiniteElementSpace &)
Method defining partial assembly.
virtual void AssembleElementVector(const FiniteElement &el, ElementTransformation &Tr, const Vector &elfun, Vector &elvect)
Perform the local action of the BilinearFormIntegrator.
MixedWeakGradDotIntegrator(VectorCoefficient &vq)
ScalarVectorProductInterpolator(Coefficient &sc)
virtual const char * FiniteElementTypeFailureMessage() const
virtual void CalcShape(const FiniteElement &scalar_fe, ElementTransformation &Trans, Vector &shape)
virtual void AddMultPA(const Vector &x, Vector &y) const
Method for partially assembled action.
virtual void CalcShape(const FiniteElement &scalar_fe, ElementTransformation &Trans, Vector &shape)
virtual void CalcTrialShape(const FiniteElement &trial_fe, ElementTransformation &Trans, DenseMatrix &shape)
const GeometricFactors * geom
Not owned.
virtual void AssembleElementMatrix2(const FiniteElement &dom_fe, const FiniteElement &ran_fe, ElementTransformation &Trans, DenseMatrix &elmat)
MixedScalarWeakGradientIntegrator(Coefficient &q)
virtual void AssembleDiagonalMF(Vector &diag)
Assemble diagonal and add it to Vector diag.
MixedVectorIntegrator(Coefficient &q)
DiffusionIntegrator(MatrixCoefficient &q)
Construct a diffusion integrator with a matrix coefficient q.
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
virtual void AssembleMF(const FiniteElementSpace &fes)
Method defining matrix-free assembly.
virtual const char * FiniteElementTypeFailureMessage() const
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
MixedGradGradIntegrator(MatrixCoefficient &mq)
virtual void AssembleElementMatrix(const FiniteElement &, ElementTransformation &, DenseMatrix &)
Given a particular Finite Element computes the element matrix elmat.
VectorFEMassIntegrator(MatrixCoefficient &mq)
Class FiniteElementSpace - responsible for providing FEM view of the mesh, mainly managing the set of...
MixedScalarWeakCurlCrossIntegrator(VectorCoefficient &vq)
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
virtual void CalcTestShape(const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &shape)
Base class Coefficients that optionally depend on space and time. These are used by the BilinearFormI...
virtual void AddMultPA(const Vector &, Vector &) const
Method for partially assembled action.
MixedScalarWeakCurlIntegrator()
virtual void AssembleDiagonalPA(Vector &diag)
Assemble diagonal and add it to Vector diag.
virtual bool VerifyFiniteElementTypes(const FiniteElement &trial_fe, const FiniteElement &test_fe) const
virtual void CalcTrialShape(const FiniteElement &trial_fe, ElementTransformation &Trans, DenseMatrix &shape)
virtual void AssembleEAInteriorFaces(const FiniteElementSpace &fes, Vector &ea_data_int, Vector &ea_data_ext, const bool add)
virtual void AssembleElementMatrix(const FiniteElement &fe, ElementTransformation &Trans, DenseMatrix &elmat)
Support for use in BilinearForm. Can be used only when appropriate.
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
MixedScalarCurlIntegrator()
static const IntegrationRule & GetRule(const FiniteElement &el, ElementTransformation &Trans)
virtual const char * FiniteElementTypeFailureMessage() const
virtual void AssemblePABoundaryFaces(const FiniteElementSpace &fes)
void CalcPhysShape(ElementTransformation &Trans, Vector &shape) const
Evaluate the values of all shape functions of a scalar finite element in physical space at the point ...
virtual const char * FiniteElementTypeFailureMessage() const
MixedCurlCurlIntegrator()
virtual void AddMultPA(const Vector &, Vector &) const
Method for partially assembled action.
MixedVectorWeakDivergenceIntegrator(Coefficient &q)
Base class for Matrix Coefficients that optionally depend on time and space.
virtual void AssembleElementMatrix2(const FiniteElement &dom_fe, const FiniteElement &ran_fe, ElementTransformation &Trans, DenseMatrix &elmat)
MixedScalarWeakDivergenceIntegrator(VectorCoefficient &vq)
const FaceGeometricFactors * geom
Not owned.
virtual void AssembleEAInteriorFaces(const FiniteElementSpace &fes, Vector &ea_data_int, Vector &ea_data_ext, const bool add)
virtual void AddMultPA(const Vector &, Vector &) const
Method for partially assembled action.
virtual void AddMultPA(const Vector &x, Vector &y) const
Method for partially assembled action.
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
DGDiffusionIntegrator(const double s, const double k)
virtual void CalcTestShape(const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &shape)
static const IntegrationRule & GetRule(const FiniteElement &trial_fe, const FiniteElement &test_fe)
MixedCrossGradCurlIntegrator(VectorCoefficient &vq)
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
MixedVectorDivergenceIntegrator(VectorCoefficient &vq)
Structure representing the matrices/tensors needed to evaluate (in reference space) the values...
A class to initialize the size of a Tensor.
MassIntegrator(Coefficient &q, const IntegrationRule *ir=NULL)
Construct a mass integrator with coefficient q.
virtual void AssembleEABoundaryFaces(const FiniteElementSpace &fes, Vector &ea_data_bdr, const bool add)
const FiniteElementSpace * fespace
virtual void AssembleFaceMatrix(const FiniteElement &el1, const FiniteElement &el2, FaceElementTransformations &Trans, DenseMatrix &elmat)
VectorFEMassIntegrator(DiagonalMatrixCoefficient &dq)
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)