89 const auto nVertices = (coordinates.
size() / meshDim);
90 Eigen::Map<const Eigen::MatrixXd> C(coordinates.
data(), meshDim, nVertices);
91 Eigen::VectorXd minCoeffs = C.rowwise().minCoeff();
92 Eigen::VectorXd maxCoeffs = C.rowwise().maxCoeff();
95 PRECICE_CHECK(minCheck && maxCheck,
"The provided coordinates in \"{}\" are not within the access region defined with \"setMeshAccessRegion()\". "
96 "Minimum corner of the provided values is (x,y,z) = ({}), the minimum corner of the access region box is (x,y,z) = ({}). "
97 "Maximum corner of the provided values is (x,y,z) = ({}), the maximum corner of the access region box is (x,y,z) = ({}). ",
99 C.colwise().maxCoeff();
106 for (
const auto &v :
mesh->vertices()) {
113 }
else if (!requiresBB) {
118 return filteredVertices;
#define PRECICE_CHECK(check,...)
This class provides a lightweight logger.
MeshRequirement
Specifies requirements for the input and output meshes of a mapping.
GeometricFilter
Defines the type of geometric filter used.
A C++ 11 implementation of the non-owning C++20 std::span type.
constexpr pointer data() const noexcept
constexpr size_type size() const noexcept
std::shared_ptr< Mesh > PtrMesh
std::shared_ptr< Partition > PtrPartition
Stores a mesh and related objects and data.
mesh::PtrMesh mesh
Mesh holding the geometry data structure.
mapping::Mapping::MeshRequirement meshRequirement
Determines which mesh type has to be provided by the accessor.
void checkVerticesInsideAccessRegion(precice::span< const double > coordinates, const int meshDim, std::string_view functionName) const
partition::PtrPartition partition
Partition creating the parallel decomposition of the mesh.
partition::ReceivedPartition::GeometricFilter geoFilter
type of geometric filter
std::vector< MappingContext > toMappingContexts
Mappings used when mapping data to the mesh. Can be empty.
std::string receiveMeshFrom
Name of participant that creates the mesh.
bool provideMesh
True, if accessor does create the mesh.
std::vector< MappingContext > fromMappingContexts
Mappings used when mapping data from the mesh. Can be empty.
void require(mapping::Mapping::MeshRequirement requirement)
std::shared_ptr< mesh::BoundingBox > userDefinedAccessRegion
std::vector< std::reference_wrapper< const mesh::Vertex > > filterVerticesToLocalAccessRegion(bool requiresBB) const
double safetyFactor
bounding box to speed up decomposition of received mesh is increased by this safety factor