24   int dof_u0 = el[0]->GetDof();
 
   25   int dof_r0 = pel[0]->GetDof();
 
   27   int dim = el[0]->GetDim();
 
   32                       " is not defined on manifold meshes");
 
   44   Vector param(1); param=0.0;
 
   51      int order= 2 * el[0]->GetOrder() + Tr.
OrderGrad(el[0])
 
   63      el[0]->CalcPhysDShape(Tr,dsu0);
 
   64      el[0]->CalcPhysShape(Tr,shu0);
 
   65      pel[0]->CalcPhysShape(Tr,shr0);
 
   67      param[0]=shr0*(*pelfun[0]);
 
   70      for (
int jj=0; jj<
dim; jj++)
 
   76      energy=energy+w * qfun.
QEnergy(Tr,ip,param,uu);
 
 
   90   int dof_u0 = el[0]->GetDof();
 
   91   int dof_r0 = pel[0]->GetDof();
 
   93   int dim = el[0]->GetDim();
 
  101                       " is not defined on manifold meshes");
 
  113   Vector param(1); param=0.0;
 
  119   int order= 2 * el[0]->GetOrder() + Tr.
OrderGrad(el[0])
 
  131      el[0]->CalcPhysDShape(Tr,dsu0);
 
  132      el[0]->CalcPhysShape(Tr,shu0);
 
  133      pel[0]->CalcPhysShape(Tr,shr0);
 
  135      param[0]=shr0*(*pelfun[0]);
 
  138      for (
int jj=0; jj<
dim; jj++)
 
  147      elvec[0]->Add(w,lvec);
 
 
  159   int dof_u0 = el[0]->GetDof();
 
  160   int dof_r0 = pel[0]->GetDof();
 
  162   int dim = el[0]->GetDim();
 
  172                       " is not defined on manifold meshes");
 
  184   Vector param(1); param=0.0;
 
  190   int order= 2 * el[0]->GetOrder() + Tr.
OrderGrad(el[0])
 
  201      el[0]->CalcPhysDShape(Tr,dsu0);
 
  202      el[0]->CalcPhysShape(Tr,shu0);
 
  203      pel[0]->CalcPhysShape(Tr,shr0);
 
  205      param[0]=shr0*(*pelfun[0]);
 
  208      for (
int jj=0; jj<
dim; jj++)
 
 
  229   int dof_u0 = el[0]->GetDof();
 
  230   int dof_r0 = pel[0]->GetDof();
 
  232   int dim = el[0]->GetDim();
 
  242                       " is not defined on manifold meshes");
 
  254   Vector param(1); param=0.0;
 
  262      int order= 2 * el[0]->GetOrder() + Tr.
OrderGrad(el[0])
 
  274      el[0]->CalcPhysDShape(Tr,dsu0);
 
  275      el[0]->CalcPhysShape(Tr,shu0);
 
  276      pel[0]->CalcPhysShape(Tr,shr0);
 
  278      param[0]=shr0*(*pelfun[0]);
 
  281      for (
int jj=0; jj<
dim; jj++)
 
 
  303   int dof_u0 = el[0]->GetDof();
 
  304   int dim = el[0]->GetDim();
 
  309                       " is not defined on manifold meshes");
 
  322      int order= 2 * el[0]->GetOrder() + Tr.
OrderGrad(el[0]);
 
  334      el[0]->CalcPhysShape(Tr,shu0);
 
  336      val=shu0*(*elfun[0]);
 
  337      energy=energy + w * val * val;
 
 
  348   int dof_u0 = el[0]->GetDof();
 
  349   int dim = el[0]->GetDim();
 
  358                       " is not defined on manifold meshes");
 
  369      int order= 2 * el[0]->GetOrder() + Tr.
OrderGrad(el[0]);
 
  381      el[0]->CalcPhysShape(Tr,shu0);
 
  383      val=shu0*(*elfun[0]);
 
  385      elvec[0]->Add(w*val,shu0);
 
 
Dynamic 2D array using row-major layout.
void SetSize(int nsize)
Change the logical size of the array, keep existing entries.
virtual void QResidual(ElementTransformation &T, const IntegrationPoint &ip, mfem::Vector &dd, mfem::Vector &uu, mfem::Vector &rr)=0
virtual void AQResidual(ElementTransformation &T, const IntegrationPoint &ip, mfem::Vector &dd, mfem::Vector &uu, mfem::Vector &aa, mfem::Vector &rr)=0
virtual real_t QEnergy(ElementTransformation &T, const IntegrationPoint &ip, mfem::Vector &dd, mfem::Vector &uu)
virtual void QGradResidual(ElementTransformation &T, const IntegrationPoint &ip, mfem::Vector &dd, mfem::Vector &uu, mfem::DenseMatrix &hh)=0
Returns the gradient of the residual at a integration point.
Data type dense matrix using column-major storage.
void Mult(const real_t *x, real_t *y) const
Matrix vector multiplication.
void MultTranspose(const real_t *x, real_t *y) const
Multiply a vector with the transpose matrix.
void SetSize(int s)
Change the size of the DenseMatrix to s x s.
void SetCol(int c, const real_t *col)
void GetColumn(int c, Vector &col) const
void AssembleElementVector(const Array< const FiniteElement * > &el, ElementTransformation &Tr, const Array< const Vector * > &elfun, const Array< Vector * > &elvec) override
Returns the gradient of the objective contribution at element level.
real_t GetElementEnergy(const Array< const FiniteElement * > &el, ElementTransformation &Tr, const Array< const Vector * > &elfun) override
Returns the objective contribution at element level.
Class for integration point with weight.
Class for an integration rule - an Array of IntegrationPoint.
int GetNPoints() const
Returns the number of the points in the integration rule.
IntegrationPoint & IntPoint(int i)
Returns a reference to the i-th integration point.
const IntegrationRule & Get(int GeomType, int Order)
Returns an integration rule for given GeomType and Order.
void AssembleElementVector(const Array< const FiniteElement * > &el, const Array< const FiniteElement * > &pel, ElementTransformation &Tr, const Array< const Vector * > &elfun, const Array< const Vector * > &pelfun, const Array< Vector * > &elvec) override
Computes the element's residual.
real_t GetElementEnergy(const Array< const FiniteElement * > &el, const Array< const FiniteElement * > &pel, ElementTransformation &Tr, const Array< const Vector * > &elfun, const Array< const Vector * > &pelfun) override
Computes the local energy.
void AssemblePrmElementVector(const Array< const FiniteElement * > &el, const Array< const FiniteElement * > &pel, ElementTransformation &Tr, const Array< const Vector * > &elfun, const Array< const Vector * > &alfun, const Array< const Vector * > &pelfun, const Array< Vector * > &elvec) override
void AssembleElementGrad(const Array< const FiniteElement * > &el, const Array< const FiniteElement * > &pel, ElementTransformation &Tr, const Array< const Vector * > &elfun, const Array< const Vector * > &pelfun, const Array2D< DenseMatrix * > &elmats) override
Computes the stiffness/tangent matrix.
void SetSize(int s)
Resize the vector to size s.
Vector & Add(const real_t a, const Vector &Va)
(*this) += a * Va
void AddMult_a_ABt(real_t a, const DenseMatrix &A, const DenseMatrix &B, DenseMatrix &ABt)
ABt += a * A * B^t.
void mfem_error(const char *msg)
void Mult(const Table &A, const Table &B, Table &C)
C = A * B (as boolean matrices)
IntegrationRules IntRules(0, Quadrature1D::GaussLegendre)
A global object with all integration rules (defined in intrules.cpp)