19#include <range/v3/view/iota.hpp> 
   20#include <range/v3/view/transform.hpp> 
   33    class NodeWiseMeshPartitioner;
 
   48                                const std::vector<std::size_t>& nodes);
 
   60    Mesh(std::string name,
 
   65         bool const compute_element_neighbors = 
false,
 
  132        std::size_t node_id) 
const;
 
  134        Node const& node) 
const;
 
 
  191PropertyVector<int> 
const* 
materialIDs(Mesh 
const& mesh);
 
  193PropertyVector<std::size_t> 
const* 
bulkNodeIDs(Mesh 
const& mesh);
 
  194PropertyVector<std::size_t> 
const* 
bulkElementIDs(Mesh 
const& mesh);
 
  199                std::vector<Element const*> 
const& elements_connected_to_node);
 
  203    std::vector<Element*> 
const& elements);
 
  210    if constexpr (std::is_pointer_v<T>)
 
  212        return a->getID() < b->getID();
 
  216        return a.getID() < b.getID();
 
 
  220Mesh& 
findMeshByName(std::vector<std::unique_ptr<Mesh>> 
const& meshes,
 
  221                     std::string_view 
const name);
 
  227inline constexpr ranges::views::view_closure 
ids =
 
  228    ranges::views::transform([](
auto const& a) { 
return a->getID(); });
 
  231inline constexpr ranges::views::view_closure 
names =
 
  232    ranges::views::transform([](
auto const& a) { 
return a->getName(); });
 
  234inline constexpr ranges::views::view_closure 
coords =
 
  236                             { 
return std::span(n->
data(), n->
data() + 3); });
 
  241           ranges::views::transform(
 
  242               [mesh_id = mesh.
getID(), item_type](std::size_t 
const n)
 
  243               { return Location{mesh_id, item_type, n}; });
 
 
 
Definition of mesh-related Enumerations.
 
Definition of the class Properties that implements a container of properties.
 
Definition of the Point3d class.
 
const double * data() const
 
bool isAxiallySymmetric() const
 
std::vector< Node * > const & getNodes() const
Get the nodes-vector for the mesh.
 
void calcEdgeLengthRange()
Set the minimum and maximum length over the edges of the mesh.
 
bool const _compute_element_neighbors
 
std::vector< std::vector< Element const  * > > _elements_connected_to_nodes
 
void setName(const std::string &name)
Changes the name of the mesh.
 
void addElement(Element *elem)
Add an element to the mesh.
 
std::vector< Element * > const & getElements() const
Get the element-vector for the mesh.
 
std::size_t computeNumberOfBaseNodes() const
Get the number of base nodes.
 
friend void removeMeshNodes(Mesh &mesh, const std::vector< std::size_t > &nodes)
 
Mesh & operator=(Mesh &&mesh)=delete
 
unsigned getDimension() const
Returns the dimension of the mesh (determined by the maximum dimension over all elements).
 
std::size_t getID() const
Get id of the mesh.
 
void resetNodeIDs()
Resets the IDs of all mesh-nodes to their position in the node vector.
 
const Node * getNode(std::size_t idx) const
Get the node with the given index.
 
Properties & getProperties()
 
const Element * getElement(std::size_t idx) const
Get the element with the given index.
 
std::vector< Element * > _elements
 
void setDimension()
Sets the dimension of the mesh.
 
const std::string getName() const
Get name of the mesh.
 
void resetElementIDs()
Resets the IDs of all mesh-elements to their position in the element vector.
 
void setElementNeighbors()
 
virtual ~Mesh()
Destructor.
 
Mesh(std::string name, std::vector< Node * > nodes, std::vector< Element * > elements, bool const compute_element_neighbors=false, Properties const &properties=Properties())
 
std::size_t getNumberOfNodes() const
Get the number of nodes.
 
std::vector< Element const * > const & getElementsConnectedToNode(std::size_t node_id) const
 
void setAxiallySymmetric(bool is_axial_symmetric)
 
std::pair< double, double > _node_distance
The minimal and maximal distance of nodes within an element over all elements in the mesh.
 
Mesh & operator=(const Mesh &mesh)=delete
 
Properties const & getProperties() const
 
bool hasNonlinearElement() const
Check if the mesh contains any nonlinear element.
 
std::size_t getNumberOfElements() const
Get the number of elements.
 
std::vector< Node * > _nodes
 
bool _is_axially_symmetric
 
Property manager on mesh items. Class Properties manages scalar, vector or matrix properties....
 
constexpr ranges::views::view_closure ids
For an element of a range view return its id.
 
auto meshLocations(Mesh const &mesh, MeshItemType const item_type)
 
constexpr ranges::views::view_closure coords
 
constexpr ranges::views::view_closure names
For an element of a range view return its name.
 
std::vector< std::vector< Node * > > calculateNodesConnectedByElements(Mesh const &mesh)
 
Mesh & findMeshByName(std::vector< std::unique_ptr< Mesh > > const &meshes, std::string_view const name)
 
bool idsComparator(T const a, T const b)
 
PropertyVector< int > const * materialIDs(Mesh const &mesh)
 
PropertyVector< std::size_t > const * bulkElementIDs(Mesh const &mesh)
 
std::pair< double, double > minMaxEdgeLength(std::vector< Element * > const &elements)
Returns the minimum and maximum edge length for given elements.
 
bool operator==(Mesh const &a, Mesh const &b)
Meshes are equal if their id's are equal.
 
bool operator!=(Mesh const &a, Mesh const &b)
 
bool isBaseNode(Node const &node, std::vector< Element const * > const &elements_connected_to_node)
 
PropertyVector< std::size_t > const * bulkNodeIDs(Mesh const &mesh)