49 if (!maybe_delta || !maybe_delta->
IsDelta())
65 if (!maybe_delta || !maybe_delta->
IsDelta())
113 if (mesh.
NURBSext !=
nullptr) {
return false; }
118 for (
int k = 0; k < integ.Size(); k++)
125 if (!IntegratorsSupportDevice(
domain_integs)) {
return false; }
138 for (
int be = 0; be <
fes->
GetNBE(); ++be)
142 if (!face_info.IsBoundary())
154 if (mesh_dim == 1 || mesh_dim != mesh.
SpaceDimension()) {
return false; }
196 "invalid element marker for domain linear form "
197 "integrator #" << k <<
", counting from zero");
201 for (
int i = 0; i <
fes -> GetNE(); i++)
207 if (markers) { markers->
HostRead(); }
208 if ( markers == NULL || (*markers)[elem_attr-1] == 1 )
210 doftrans =
fes -> GetElementVDofs (i, vdofs);
211 eltrans =
fes -> GetElementTransformation (i);
241 MFEM_ASSERT(bdr_marker.
Size() == bdr_attr_marker.
Size(),
242 "invalid boundary marker for boundary integrator #"
243 << k <<
", counting from zero");
244 for (
int i = 0; i < bdr_attr_marker.
Size(); i++)
246 bdr_attr_marker[i] |= bdr_marker[i];
250 for (
int i = 0; i <
fes -> GetNBE(); i++)
253 if (bdr_attr_marker[bdr_attr-1] == 0) {
continue; }
254 doftrans =
fes -> GetBdrElementVDofs (i, vdofs);
255 eltrans =
fes -> GetBdrElementTransformation (i);
289 MFEM_ASSERT(bdr_marker.
Size() == bdr_attr_marker.
Size(),
290 "invalid boundary marker for boundary face integrator #"
291 << k <<
", counting from zero");
292 for (
int i = 0; i < bdr_attr_marker.
Size(); i++)
294 bdr_attr_marker[i] |= bdr_marker[i];
298 for (
int i = 0; i < mesh->
GetNBE(); i++)
301 if (bdr_attr_marker[bdr_attr-1] == 0) {
continue; }
306 fes -> GetElementVDofs (tr -> Elem1No, vdofs);
314 AssembleRHSElementVect(*
fes->
GetFE(tr->Elem1No),
334 fes -> GetElementVDofs (tr -> Elem1No, vdofs);
336 fes -> GetElementVDofs (tr -> Elem2No, vdofs2);
339 AssembleRHSElementVect(*
fes->
GetFE(tr->Elem1No),
357 MFEM_ASSERT(v.
Size() >= v_offset +
f->GetVSize(),
"");
379 for (
int i = 0; i < centers.
Width(); i++)
383 MFEM_VERIFY(center.
Size() == sdim,
384 "Point dim " << center.
Size() <<
385 " does not match space dim " << sdim);
398 if (elem_id < 0) {
continue; }
T Max() const
Find the maximal element in the array, using the comparison operator < for class T.
const T * HostRead() const
Shortcut for mfem::Read(a.GetMemory(), a.Size(), false).
int Size() const
Return the logical size of the array.
int Append(const T &el)
Append element 'el' to array, resize if necessary.
Abstract class for integrators that support delta coefficients.
bool IsDelta() const
Returns true if the derived class instance uses a delta coefficient.
Data type dense matrix using column-major storage.
void GetColumnReference(int c, Vector &col)
Class FiniteElementSpace - responsible for providing FEM view of the mesh, mainly managing the set of...
bool IsVariableOrder() const
Returns true if the space contains elements of varying polynomial orders.
const FiniteElement * GetBE(int i) const
Returns pointer to the FiniteElement in the FiniteElementCollection associated with i'th boundary fac...
ElementTransformation * GetElementTransformation(int i) const
Returns ElementTransformation for the i-th element.
int GetNBE() const
Returns number of boundary elements in the mesh.
DofTransformation * GetElementVDofs(int i, Array< int > &vdofs) const
Returns indices of degrees of freedom for the i'th element. The returned indices are offsets into an ...
virtual const FiniteElement * GetFE(int i) const
Returns pointer to the FiniteElement in the FiniteElementCollection associated with i'th element in t...
int GetNFbyType(FaceType type) const
Returns the number of faces according to the requested type.
Mesh * GetMesh() const
Returns the mesh.
int GetVSize() const
Return the number of vector dofs, i.e. GetNDofs() x GetVDim().
Class for integration point with weight.
Array< int > bdr_attributes
A list of all unique boundary attributes used by the Mesh.
NURBSExtension * NURBSext
Optional NURBS mesh extension.
int GetNumFaces() const
Return the number of faces (3D), edges (2D) or vertices (1D).
int GetAttribute(int i) const
Return the attribute of element i.
int GetBdrAttribute(int i) const
Return the attribute of boundary element i.
int GetBdrElementFaceIndex(int be_idx) const
Return the local face (codimension-1) index for the given boundary element index.
int Dimension() const
Dimension of the reference space used within the elements.
FaceInformation GetFaceInformation(int f) const
int SpaceDimension() const
Dimension of the physical space containing the mesh.
FaceElementTransformations * GetBdrFaceTransformations(int BdrElemNo)
Builds the transformation defining the given boundary face.
int GetNBE() const
Returns number of boundary elements.
virtual int FindPoints(DenseMatrix &point_mat, Array< int > &elem_ids, Array< IntegrationPoint > &ips, bool warn=true, InverseElementTransformation *inv_trans=NULL)
Find the ids of the elements that contain the given points, and their corresponding reference coordin...
FaceElementTransformations * GetInteriorFaceTransformations(int FaceNo)
See GetFaceElementTransformations().
Array< int > attributes
A list of all unique element attributes used by the Mesh.
int Width() const
Get the width (size of input) of the Operator. Synonym with NumCols().
void AddElementVector(const Array< int > &dofs, const Vector &elemvect)
Add elements of the elemvect Vector to the entries listed in dofs. Negative dof values cause the -dof...
virtual bool UseDevice() const
Return the device flag of the Memory object used by the Vector.
int Size() const
Returns the size of the vector.
virtual void UseDevice(bool use_dev) const
Enable execution of Vector operations using the mfem::Device.
void SetSize(int s)
Resize the vector to size s.
Vector & operator=(const real_t *v)
Copy Size() entries from v.
void MakeRef(Vector &base, int offset, int size)
Reset the Vector to be a reference to a sub-vector of base.
bool UsesTensorBasis(const FiniteElementSpace &fes)
Return true if the mesh contains only one topology and the elements are tensor elements.
std::function< real_t(const Vector &)> f(real_t mass_coeff)