1#ifndef MESH_ELEM_TEST_H
2#define MESH_ELEM_TEST_H
4#include "../geom/elem_test.h"
6#include "libmesh/mesh_serializer.h"
10template <ElemType elem_type>
33 CPPUNIT_ASSERT_EQUAL(max_elem_id, other_mesh.
max_elem_id());
34 CPPUNIT_ASSERT_EQUAL(max_node_id, other_mesh.
max_node_id());
38 for (
Elem * e1 : this->
_mesh->element_ptr_range())
40 const Elem * e2c = (*locator)(e1->vertex_average());
56#ifdef LIBMESH_ENABLE_UNIQUE_ID
61 for (
Node * n1 : this->
_mesh->node_ptr_range())
63 const Elem * e1c = (*locator)(*n1);
67#if defined(LIBMESH_DEFAULT_QUADRUPLE_PRECISION) || defined(LIBMESH_DEFAULT_TRIPLE_PRECISION)
82 if (diff.
norm() < 1e-15)
84 (*n1)(d) =
double(n(d));
93 n1->processor_id() = 0;
106#ifdef LIBMESH_ENABLE_UNIQUE_ID
111#ifdef LIBMESH_ENABLE_UNIQUE_ID
113 this->
_mesh->set_next_unique_id(this->
_mesh->parallel_max_unique_id());
116 return *this->
_mesh == other_mesh;
bool meshes_equal_enough(Mesh &other_mesh, bool double_precision)
std::unique_ptr< Mesh > _mesh
virtual void renumber_elem(dof_id_type old_id, dof_id_type new_id) override final
Changes the id of element old_id, both by changing elem(old_id)->id() and by moving elem(old_id) in t...
virtual dof_id_type max_node_id() const override final
virtual void set_next_unique_id(unique_id_type id) override
Sets the next available unique id to be used.
virtual dof_id_type max_elem_id() const override final
virtual void renumber_node(dof_id_type old_id, dof_id_type new_id) override final
Changes the id of node old_id, both by changing node(old_id)->id() and by moving node(old_id) in the ...
virtual const Node * node_ptr(const dof_id_type i) const override final
processor_id_type processor_id() const
void set_unique_id(unique_id_type new_id)
Sets the unique_id for this DofObject.
This is the base class from which all geometric element types are derived.
SimpleRange< NodeRefIter > node_ref_range()
Returns a range with all nodes of an element, usable in range-based for loops.
virtual const Elem & elem_ref(const dof_id_type i) const
std::unique_ptr< PointLocatorBase > sub_point_locator() const
Temporarily serialize a DistributedMesh for non-distributed-mesh capable code paths.
The Mesh class is a thin wrapper, around the ReplicatedMesh class by default.
A Node is like a Point, but with more information.
A Point defines a location in LIBMESH_DIM dimensional Real space.
The libMesh namespace provides an interface to certain functionality in the library.
void libmesh_ignore(const Args &...)
IntRange< T > make_range(T beg, T end)
The 2-parameter make_range() helper function returns an IntRange<T> when both input parameters are of...