diff --git a/framework/include/utils/MeshBaseDiagnosticsUtils.h b/framework/include/utils/MeshBaseDiagnosticsUtils.h index 17494fe0278e..830f46c36c7f 100644 --- a/framework/include/utils/MeshBaseDiagnosticsUtils.h +++ b/framework/include/utils/MeshBaseDiagnosticsUtils.h @@ -25,8 +25,8 @@ void checkNonConformalMesh(const std::unique_ptr & mesh, const Real conformality_tol, unsigned int & num_nonconformal_nodes); -bool checkFirstOrderEdgeOverlap(const std::unique_ptr & edge1, - const std::unique_ptr & edge2, +bool checkFirstOrderEdgeOverlap(const Elem & edge1, + const Elem & edge2, Point & intersection_point, const Real intersection_tol); } diff --git a/framework/src/meshgenerators/MeshDiagnosticsGenerator.C b/framework/src/meshgenerators/MeshDiagnosticsGenerator.C index a8196f8eed52..3d626c150fe5 100644 --- a/framework/src/meshgenerators/MeshDiagnosticsGenerator.C +++ b/framework/src/meshgenerators/MeshDiagnosticsGenerator.C @@ -1431,8 +1431,7 @@ MeshDiagnosticsGenerator::checkNonMatchingEdges(const std::unique_ptr bounding_box_map.insert({elem, boundingBox}); } - std::unique_ptr point_locator = - mesh->sub_point_locator(); // PointLocatorBase::build(TREE_ELEMENTS, *mesh); + std::unique_ptr point_locator = mesh->sub_point_locator(); std::set> overlapping_edges_nodes; for (const auto elem : mesh->active_element_ptr_range()) { @@ -1494,7 +1493,7 @@ MeshDiagnosticsGenerator::checkNonMatchingEdges(const std::unique_ptr // Now compare edge with other_edge Point intersection_coords; bool overlap = MeshBaseDiagnosticsUtils::checkFirstOrderEdgeOverlap( - edge, other_edge, intersection_coords, _non_matching_edge_tol); + *edge, *other_edge, intersection_coords, _non_matching_edge_tol); if (overlap) { // Add the nodes that make up the 2 edges to the vector overlapping_edges_nodes diff --git a/framework/src/utils/MeshBaseDiagnosticsUtils.C b/framework/src/utils/MeshBaseDiagnosticsUtils.C index 3960797cdac3..9c7fff5d5cdf 100644 --- a/framework/src/utils/MeshBaseDiagnosticsUtils.C +++ b/framework/src/utils/MeshBaseDiagnosticsUtils.C @@ -69,19 +69,19 @@ checkNonConformalMesh(const std::unique_ptr & mesh, } bool -checkFirstOrderEdgeOverlap(const std::unique_ptr & edge1, - const std::unique_ptr & edge2, +checkFirstOrderEdgeOverlap(const Elem & edge1, + const Elem & edge2, Point & intersection_point, const Real intersection_tol) { // check that the two elements are of type EDGE2 - mooseAssert(edge1->type() == EDGE2, "Elements must be of type EDGE2"); - mooseAssert(edge2->type() == EDGE2, "Elements must be of type EDGE2"); + mooseAssert(edge1.type() == EDGE2, "Elements must be of type EDGE2"); + mooseAssert(edge2.type() == EDGE2, "Elements must be of type EDGE2"); // Get nodes from the two edges - const Point & p1 = edge1->point(0); - const Point & p2 = edge1->point(1); - const Point & p3 = edge2->point(0); - const Point & p4 = edge2->point(1); + const Point & p1 = edge1.point(0); + const Point & p2 = edge1.point(1); + const Point & p3 = edge2.point(0); + const Point & p4 = edge2.point(1); // Check that the two edges are not sharing a node if (p1 == p3 || p1 == p4 || p2 == p3 || p2 == p4)