From 00e305b365cc9fa6f47bd05ac8f50bc6398b591f Mon Sep 17 00:00:00 2001 From: Roy Stogner Date: Thu, 10 Nov 2022 17:30:08 -0600 Subject: [PATCH 01/30] Accept string_view for Xdr::data comments This should give us a bit more efficiency+flexibility. --- include/utils/xdr_cxx.h | 3 +- src/utils/xdr_cxx.C | 84 ++++++++++++++++++++--------------------- 2 files changed, 44 insertions(+), 43 deletions(-) diff --git a/include/utils/xdr_cxx.h b/include/utils/xdr_cxx.h index 1a932784e19..15671ab501c 100644 --- a/include/utils/xdr_cxx.h +++ b/include/utils/xdr_cxx.h @@ -40,6 +40,7 @@ #include #include #include +#include const unsigned int xdr_MAX_STRING_LENGTH=256; @@ -128,7 +129,7 @@ class Xdr * Inputs or outputs a single value. */ template - void data(T & a, const char * comment=""); + void data(T & a, std::string_view comment=""); /** * Same, but provides an \p ostream like interface. diff --git a/src/utils/xdr_cxx.C b/src/utils/xdr_cxx.C index 49a4c2107c8..71cc010166d 100644 --- a/src/utils/xdr_cxx.C +++ b/src/utils/xdr_cxx.C @@ -741,7 +741,7 @@ void Xdr::do_write(std::vector> & a) template -void Xdr::data (T & a, const char * comment_in) +void Xdr::data (T & a, std::string_view comment_in) { switch (mode) { @@ -790,7 +790,7 @@ void Xdr::data (T & a, const char * comment_in) // If there's a comment provided, write a tab character and // then the comment. - if (std::string(comment_in) != "") + if (comment_in != "") *out << "\t " << comment_in; // Go to the next line. @@ -1297,42 +1297,42 @@ void Xdr::comment (std::string & comment_in) // -template LIBMESH_EXPORT void Xdr::data (int &, const char *); -template LIBMESH_EXPORT void Xdr::data (unsigned int &, const char *); -template LIBMESH_EXPORT void Xdr::data (unsigned short int &, const char *); -template LIBMESH_EXPORT void Xdr::data (short int &, const char *); -template LIBMESH_EXPORT void Xdr::data (unsigned long int &, const char *); -template LIBMESH_EXPORT void Xdr::data (unsigned long long &, const char *); -template LIBMESH_EXPORT void Xdr::data (long int &, const char *); -template LIBMESH_EXPORT void Xdr::data (long long &, const char *); -template LIBMESH_EXPORT void Xdr::data (char &, const char *); -template LIBMESH_EXPORT void Xdr::data (signed char &, const char *); -template LIBMESH_EXPORT void Xdr::data (unsigned char &, const char *); -template LIBMESH_EXPORT void Xdr::data (float &, const char *); -template LIBMESH_EXPORT void Xdr::data (double &, const char *); -template LIBMESH_EXPORT void Xdr::data (long double &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::complex &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::complex &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::complex &, const char *); -template LIBMESH_EXPORT void Xdr::data (std::string &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::vector &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::vector &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::vector &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::vector &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::vector &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::vector &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::vector &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::vector &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::vector &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::vector &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::vector &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::vector &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::vector &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::vector &, const char *); -template LIBMESH_EXPORT void Xdr::data>> (std::vector> &, const char *); -template LIBMESH_EXPORT void Xdr::data>> (std::vector> &, const char *); -template LIBMESH_EXPORT void Xdr::data>> (std::vector> &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::vector &, const char *); +template LIBMESH_EXPORT void Xdr::data (int &, std::string_view); +template LIBMESH_EXPORT void Xdr::data (unsigned int &, std::string_view); +template LIBMESH_EXPORT void Xdr::data (unsigned short int &, std::string_view); +template LIBMESH_EXPORT void Xdr::data (short int &, std::string_view); +template LIBMESH_EXPORT void Xdr::data (unsigned long int &, std::string_view); +template LIBMESH_EXPORT void Xdr::data (unsigned long long &, std::string_view); +template LIBMESH_EXPORT void Xdr::data (long int &, std::string_view); +template LIBMESH_EXPORT void Xdr::data (long long &, std::string_view); +template LIBMESH_EXPORT void Xdr::data (char &, std::string_view); +template LIBMESH_EXPORT void Xdr::data (signed char &, std::string_view); +template LIBMESH_EXPORT void Xdr::data (unsigned char &, std::string_view); +template LIBMESH_EXPORT void Xdr::data (float &, std::string_view); +template LIBMESH_EXPORT void Xdr::data (double &, std::string_view); +template LIBMESH_EXPORT void Xdr::data (long double &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::complex &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::complex &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::complex &, std::string_view); +template LIBMESH_EXPORT void Xdr::data (std::string &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::vector &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::vector &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::vector &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::vector &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::vector &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::vector &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::vector &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::vector &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::vector &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::vector &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::vector &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::vector &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::vector &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::vector &, std::string_view); +template LIBMESH_EXPORT void Xdr::data>> (std::vector> &, std::string_view); +template LIBMESH_EXPORT void Xdr::data>> (std::vector> &, std::string_view); +template LIBMESH_EXPORT void Xdr::data>> (std::vector> &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::vector &, std::string_view); template LIBMESH_EXPORT void Xdr::data_stream (unsigned char * val, const unsigned int len, const unsigned int line_break); template LIBMESH_EXPORT void Xdr::data_stream (short int * val, const unsigned int len, const unsigned int line_break); template LIBMESH_EXPORT void Xdr::data_stream (int * val, const unsigned int len, const unsigned int line_break); @@ -1343,10 +1343,10 @@ template LIBMESH_EXPORT void Xdr::data_stream (unsigned long template LIBMESH_EXPORT void Xdr::data_stream (unsigned long long * val, const unsigned int len, const unsigned int line_break); #ifdef LIBMESH_DEFAULT_QUADRUPLE_PRECISION -template LIBMESH_EXPORT void Xdr::data (Real &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::complex &, const char *); -template LIBMESH_EXPORT void Xdr::data> (std::vector &, const char *); -template LIBMESH_EXPORT void Xdr::data>> (std::vector> &, const char *); +template LIBMESH_EXPORT void Xdr::data (Real &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::complex &, std::string_view); +template LIBMESH_EXPORT void Xdr::data> (std::vector &, std::string_view); +template LIBMESH_EXPORT void Xdr::data>> (std::vector> &, std::string_view); #endif } // namespace libMesh From 47d25a7e556518bb59c4f278039b723891c0ef59 Mon Sep 17 00:00:00 2001 From: Roy Stogner Date: Thu, 10 Nov 2022 17:38:16 -0600 Subject: [PATCH 02/30] Xdr::data() no longer needs comment.c_str() --- src/mesh/xdr_io.C | 8 ++++---- src/systems/equation_systems_io.C | 4 ++-- src/systems/system_io.C | 28 ++++++++++++++-------------- 3 files changed, 20 insertions(+), 20 deletions(-) diff --git a/src/mesh/xdr_io.C b/src/mesh/xdr_io.C index 4f2e386025f..ccfb2c8b134 100644 --- a/src/mesh/xdr_io.C +++ b/src/mesh/xdr_io.C @@ -222,7 +222,7 @@ void XdrIO::write (const std::string & name) // Write vector of elemset ids to file with comment std::string comment_string = "# elemset ids for elemset code " + std::to_string(elemset_code); - io.data(elemset_id_vec, comment_string.c_str()); + io.data(elemset_id_vec, comment_string); } } @@ -421,7 +421,7 @@ XdrIO::write_serialized_connectivity (Xdr & io, legend += "p_level "; legend += "(n0 ... nN-1) ]"; comment += legend; - io.data (n_global_elem_at_level[0], comment.c_str()); + io.data (n_global_elem_at_level[0], comment); } for (auto pid : make_range(this->n_processors())) @@ -542,7 +542,7 @@ XdrIO::write_serialized_connectivity (Xdr & io, buf << "p_level "; buf << "(n0 ... nN-1) ]"; - io.data (n_global_elem_at_level[level], buf.str().c_str()); + io.data (n_global_elem_at_level[level], buf.str()); } for (auto pid : make_range(this->n_processors())) @@ -1161,7 +1161,7 @@ void XdrIO::write_serialized_bcs_helper (Xdr & io, const new_header_id_type n_bc { std::stringstream comment_string; comment_string << "# number of " << bc_type << " boundary conditions"; - io.data (n_bcs_out, comment_string.str().c_str()); + io.data (n_bcs_out, comment_string.str()); } n_bcs_out = 0; diff --git a/src/systems/equation_systems_io.C b/src/systems/equation_systems_io.C index ac1c82b14dd..1a4e8bac6b5 100644 --- a/src/systems/equation_systems_io.C +++ b/src/systems/equation_systems_io.C @@ -529,7 +529,7 @@ void EquationSystems::write(std::string_view name, // Note: There is no Xdr::data overload taking a "const // std::string &" so we need to make a copy. std::string copy = sys_name; - io.data (copy, comment.c_str()); + io.data (copy, comment); } // 4.) @@ -541,7 +541,7 @@ void EquationSystems::write(std::string_view name, comment = "# Type, System No. "; comment += std::to_string(sys_num); - io.data (sys_type, comment.c_str()); + io.data (sys_type, comment); } // 5.) - 9.) diff --git a/src/systems/system_io.C b/src/systems/system_io.C index 46f1dc4d19a..f78afe28655 100644 --- a/src/systems/system_io.C +++ b/src/systems/system_io.C @@ -1321,7 +1321,7 @@ void System::write_header (Xdr & io, comment += "\""; unsigned int nv = this->n_vars(); - io.data (nv, comment.c_str()); + io.data (nv, comment); } @@ -1338,7 +1338,7 @@ void System::write_header (Xdr & io, comment += "\""; std::string var_name = this->variable_name(var); - io.data (var_name, comment.c_str()); + io.data (var_name, comment); } // 6.1.) Variable subdomains @@ -1353,7 +1353,7 @@ void System::write_header (Xdr & io, const std::set & domains = this->variable(var).active_subdomains(); std::vector domain_array; domain_array.assign(domains.begin(), domains.end()); - io.data (domain_array, comment.c_str()); + io.data (domain_array, comment); } // 7.) @@ -1368,7 +1368,7 @@ void System::write_header (Xdr & io, comment += "\""; int order = static_cast(this->variable_type(var).order); - io.data (order, comment.c_str()); + io.data (order, comment); } @@ -1383,7 +1383,7 @@ void System::write_header (Xdr & io, comment += "\""; int rad_order = static_cast(this->variable_type(var).radial_order); - io.data (rad_order, comment.c_str()); + io.data (rad_order, comment); } #endif @@ -1400,7 +1400,7 @@ void System::write_header (Xdr & io, const FEType & type = this->variable_type(var); int fam = static_cast(type.family); - io.data (fam, comment.c_str()); + io.data (fam, comment); #ifdef LIBMESH_ENABLE_INFINITE_ELEMENTS @@ -1411,7 +1411,7 @@ void System::write_header (Xdr & io, comment += "\""; int radial_fam = static_cast(type.radial_family); - io.data (radial_fam, comment.c_str()); + io.data (radial_fam, comment); comment = "# Infinite Mapping Type, Variable \""; comment += this->variable_name(var); @@ -1420,7 +1420,7 @@ void System::write_header (Xdr & io, comment += "\""; int i_map = static_cast(type.inf_map); - io.data (i_map, comment.c_str()); + io.data (i_map, comment); #endif } } // end of the variable loop @@ -1437,7 +1437,7 @@ void System::write_header (Xdr & io, comment += "\""; unsigned int nvecs = write_additional_data ? this->n_vectors () : 0; - io.data (nvecs, comment.c_str()); + io.data (nvecs, comment); } if (write_additional_data) @@ -1451,13 +1451,13 @@ void System::write_header (Xdr & io, comment = "# Name of " + dth_vector; std::string vec_name = pr.first; - io.data (vec_name, comment.c_str()); + io.data (vec_name, comment); int vec_projection = _vector_projections.at(vec_name); comment = "# Whether to do projections for " + dth_vector; - io.data (vec_projection, comment.c_str()); + io.data (vec_projection, comment); int vec_type = _vector_types.at(vec_name); comment = "# Parallel type of " + dth_vector; - io.data (vec_type, comment.c_str()); + io.data (vec_type, comment); } } } @@ -1580,7 +1580,7 @@ void System::write_parallel_data (Xdr & io, comment += "\" Solution Vector"; } - io.data (io_buffer, comment.c_str()); + io.data (io_buffer, comment); // total_written_size += io_buffer.size(); @@ -1646,7 +1646,7 @@ void System::write_parallel_data (Xdr & io, comment += "\""; } - io.data (io_buffer, comment.c_str()); + io.data (io_buffer, comment); // total_written_size += io_buffer.size(); } From 3f27d808d62a0c6f55b2349d67d9df9d4d5c7643 Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Tue, 8 Nov 2022 13:13:00 -0700 Subject: [PATCH 03/30] Add Elem::n_vertices_per_side() --- include/geom/cell_hex.h | 6 ++++++ include/geom/cell_inf_hex.h | 6 ++++++ include/geom/cell_inf_prism.h | 3 +++ include/geom/cell_prism.h | 3 +++ include/geom/cell_pyramid.h | 3 +++ include/geom/cell_tet.h | 6 ++++++ include/geom/edge.h | 6 ++++++ include/geom/elem.h | 18 ++++++++++++++++++ include/geom/face.h | 6 ++++++ include/geom/face_inf_quad.h | 6 ++++++ include/geom/node_elem.h | 6 ++++++ include/geom/remote_elem.h | 3 +++ tests/geom/elem_test.C | 16 ++++++++++++++++ 13 files changed, 88 insertions(+) diff --git a/include/geom/cell_hex.h b/include/geom/cell_hex.h index 199ba4b1a36..423ea9de2a2 100644 --- a/include/geom/cell_hex.h +++ b/include/geom/cell_hex.h @@ -77,6 +77,12 @@ class Hex : public Cell */ virtual unsigned int n_vertices() const override final { return 8; } + /** + * \returns 4. Every side has four vertices. + */ + virtual unsigned int n_vertices_on_side(const unsigned short libmesh_dbg_var(s)) const override final + { libmesh_assert_less(s, this->n_sides()); return 4; } + /** * \returns 12. All hexahedra have 12 edges. */ diff --git a/include/geom/cell_inf_hex.h b/include/geom/cell_inf_hex.h index ce0dca8df52..b14a5ddbb85 100644 --- a/include/geom/cell_inf_hex.h +++ b/include/geom/cell_inf_hex.h @@ -90,6 +90,12 @@ class InfHex : public InfCell */ virtual unsigned int n_vertices() const override final { return 8; } + /** + * \returns 4. Every side has four vertices. + */ + virtual unsigned int n_vertices_on_side(const unsigned short libmesh_dbg_var(s)) const override final + { libmesh_assert_less(s, this->n_sides()); return 4; } + /** * \returns \p true if the specified (local) node number is a * "mid-edge" node on an infinite element edge. diff --git a/include/geom/cell_inf_prism.h b/include/geom/cell_inf_prism.h index b80014014bc..338e91de3e8 100644 --- a/include/geom/cell_inf_prism.h +++ b/include/geom/cell_inf_prism.h @@ -86,6 +86,9 @@ class InfPrism : public InfCell */ virtual unsigned int n_vertices() const override final { return 6; } + virtual unsigned int n_vertices_on_side(const unsigned short s) const override final + { libmesh_assert_less(s, this->n_sides()); return 4 - (s == 0); } + /** * \returns 6. All infinite prisms have 6 edges, * 3 lying in the base, and 3 perpendicular to the base. diff --git a/include/geom/cell_prism.h b/include/geom/cell_prism.h index 06a23683302..b856cb8854c 100644 --- a/include/geom/cell_prism.h +++ b/include/geom/cell_prism.h @@ -83,6 +83,9 @@ class Prism : public Cell */ virtual unsigned int n_vertices() const override final { return 6; } + virtual unsigned int n_vertices_on_side(const unsigned short s) const override final + { libmesh_assert_less(s, this->n_sides()); return 4 - (s == 0 || s == 4); } + /** * \returns 9. All prisms have 9 edges. */ diff --git a/include/geom/cell_pyramid.h b/include/geom/cell_pyramid.h index 85ad4da710c..f849bc8d2ef 100644 --- a/include/geom/cell_pyramid.h +++ b/include/geom/cell_pyramid.h @@ -87,6 +87,9 @@ class Pyramid : public Cell */ virtual unsigned int n_vertices() const override { return 5; } + virtual unsigned int n_vertices_on_side(const unsigned short s) const override final + { libmesh_assert_less(s, this->n_sides()); return 4 - (s != 4); } + /** * \returns 8. All pyramids have 8 edges. */ diff --git a/include/geom/cell_tet.h b/include/geom/cell_tet.h index d9875003e56..a3f2d0c3156 100644 --- a/include/geom/cell_tet.h +++ b/include/geom/cell_tet.h @@ -78,6 +78,12 @@ class Tet : public Cell */ virtual unsigned int n_vertices() const override final { return 4; } + /** + * \returns 3. Every side has three vertices. + */ + virtual unsigned int n_vertices_on_side(const unsigned short libmesh_dbg_var(s)) const override final + { libmesh_assert_less(s, this->n_sides()); return 3; } + /** * \returns 6. All tetrahedra have 6 edges. */ diff --git a/include/geom/edge.h b/include/geom/edge.h index bed5e8e6796..72d12624c46 100644 --- a/include/geom/edge.h +++ b/include/geom/edge.h @@ -78,6 +78,12 @@ class Edge : public Elem */ virtual unsigned int n_vertices() const override final { return 2; } + /** + * \returns 1. Every side has one vertex. + */ + virtual unsigned int n_vertices_on_side(const unsigned short libmesh_dbg_var(s)) const override final + { libmesh_assert_less(s, this->n_sides()); return 1; } + /** * \returns 0. All 1D elements have no edges. */ diff --git a/include/geom/elem.h b/include/geom/elem.h index 7110fba949e..9a257be6f0f 100644 --- a/include/geom/elem.h +++ b/include/geom/elem.h @@ -642,6 +642,12 @@ class Elem : public ReferenceCountedObject, */ IntRange side_index_range () const; + /** + * \returns An integer range from 0 up to (but not including) + * the number of vertices this element has. + */ + IntRange vertex_index_range () const; + /** * \returns The number of neighbors the element that has been derived * from this class has. @@ -660,6 +666,11 @@ class Elem : public ReferenceCountedObject, */ virtual unsigned int n_vertices () const = 0; + /** + * \returns The number of verticies on the side with index \p s. + */ + virtual unsigned int n_vertices_on_side (const unsigned short s) const = 0; + /** * \returns The number of edges the element that has been derived * from this class has. @@ -2465,6 +2476,13 @@ Elem::side_index_range() const +inline +IntRange +Elem::vertex_index_range() const +{ + return {0, cast_int(this->n_vertices())}; +} + inline std::unique_ptr Elem::side_ptr (unsigned int i) const diff --git a/include/geom/face.h b/include/geom/face.h index d3a818bf217..9cd50075690 100644 --- a/include/geom/face.h +++ b/include/geom/face.h @@ -66,6 +66,12 @@ class Face : public Elem */ virtual unsigned int n_faces() const override final { return 0; } + /** + * \returns 2. Every side has two vertices. + */ + virtual unsigned int n_vertices_on_side(const unsigned short libmesh_dbg_var(s)) const override final + { libmesh_assert_less(s, this->n_sides()); return 2; } + /** * build_side and build_edge are identical for faces. */ diff --git a/include/geom/face_inf_quad.h b/include/geom/face_inf_quad.h index 04fc4c3b78e..f24aef7164a 100644 --- a/include/geom/face_inf_quad.h +++ b/include/geom/face_inf_quad.h @@ -106,6 +106,12 @@ class InfQuad : public Elem */ virtual unsigned int n_vertices() const override final { return 4; } + /** + * \returns 2. Every side has two vertices. + */ + virtual unsigned int n_vertices_on_side(const unsigned short libmesh_dbg_var(s)) const override final + { libmesh_assert_less(s, this->n_sides()); return 2; } + /** * \returns 3. All infinite quads have 1 edge in the * base, and 2 perpendicular to the base. diff --git a/include/geom/node_elem.h b/include/geom/node_elem.h index ea8724afda4..cbd0d5af4bb 100644 --- a/include/geom/node_elem.h +++ b/include/geom/node_elem.h @@ -87,6 +87,12 @@ class NodeElem : public Elem */ virtual unsigned int n_vertices() const override { return 1; } + /** + * The \p Elem::n_vertices_on_side makes no sense for nodes. + */ + virtual unsigned int n_vertices_on_side(const unsigned short) const override + { libmesh_not_implemented(); return 0; } + /** * \returns 0. */ diff --git a/include/geom/remote_elem.h b/include/geom/remote_elem.h index 5f8267843bf..490e777c621 100644 --- a/include/geom/remote_elem.h +++ b/include/geom/remote_elem.h @@ -125,6 +125,9 @@ class RemoteElem : public Elem, virtual unsigned int n_vertices () const override { libmesh_not_implemented(); return 0; } + virtual unsigned int n_vertices_on_side(const unsigned short) const override + { libmesh_not_implemented(); return 0; } + virtual unsigned int n_edges () const override { libmesh_not_implemented(); return 0; } diff --git a/tests/geom/elem_test.C b/tests/geom/elem_test.C index 2795448558c..54bebcda16d 100644 --- a/tests/geom/elem_test.C +++ b/tests/geom/elem_test.C @@ -488,6 +488,21 @@ public: CPPUNIT_ASSERT_EQUAL(elem->build_side_ptr(s)->type(), elem->side_type(s)); } + void test_n_vertices_on_side() + { + LOG_UNIT_TEST; + + for (const auto & elem : _mesh->active_local_element_ptr_range()) + for (const auto s : elem->side_index_range()) + { + unsigned int n_vertices_on_side = 0; + for (const auto v : elem->vertex_index_range()) + if (elem->is_node_on_side(v, s)) + ++n_vertices_on_side; + CPPUNIT_ASSERT_EQUAL(n_vertices_on_side, elem->n_vertices_on_side(s)); + } + }; + void test_elem_side_builder() { LOG_UNIT_TEST; @@ -521,6 +536,7 @@ public: CPPUNIT_TEST( test_contains_point_node ); \ CPPUNIT_TEST( test_center_node_on_side ); \ CPPUNIT_TEST( test_side_type ); \ + CPPUNIT_TEST( test_n_vertices_on_side ); \ CPPUNIT_TEST( test_elem_side_builder ); #define INSTANTIATE_ELEMTEST(elemtype) \ From 09acf75b9027df69bcd67e33be2da1c7eb3ae62d Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Wed, 9 Nov 2022 10:00:38 -0700 Subject: [PATCH 04/30] Add Elem::n_nodes_on_side --- include/geom/cell_hex20.h | 8 ++++++-- include/geom/cell_hex27.h | 6 ++++++ include/geom/cell_hex8.h | 6 ++++++ include/geom/cell_inf_hex.h | 13 +++++++++++++ include/geom/cell_inf_hex16.h | 3 +++ include/geom/cell_inf_hex18.h | 3 +++ include/geom/cell_inf_hex8.h | 6 ++++++ include/geom/cell_inf_prism12.h | 6 ++++++ include/geom/cell_inf_prism6.h | 3 +++ include/geom/cell_prism.h | 13 +++++++++++++ include/geom/cell_prism15.h | 3 +++ include/geom/cell_prism18.h | 3 +++ include/geom/cell_prism20.h | 3 +++ include/geom/cell_prism21.h | 3 +++ include/geom/cell_prism6.h | 3 +++ include/geom/cell_pyramid.h | 12 ++++++++++++ include/geom/cell_pyramid13.h | 3 +++ include/geom/cell_pyramid14.h | 3 +++ include/geom/cell_pyramid5.h | 3 +++ include/geom/cell_tet10.h | 6 ++++++ include/geom/cell_tet14.h | 6 ++++++ include/geom/cell_tet4.h | 6 ++++++ include/geom/edge.h | 6 ++++++ include/geom/elem.h | 19 +++++++++++++++++++ include/geom/face_inf_quad4.h | 3 +++ include/geom/face_inf_quad6.h | 3 +++ include/geom/face_quad4.h | 6 ++++++ include/geom/face_quad8.h | 6 ++++++ include/geom/face_quad9.h | 6 ++++++ include/geom/face_tri3.h | 6 ++++++ include/geom/face_tri6.h | 6 ++++++ include/geom/face_tri7.h | 6 ++++++ include/geom/node_elem.h | 6 ++++++ include/geom/remote_elem.h | 3 +++ tests/geom/elem_test.C | 16 ++++++++++++++++ 35 files changed, 211 insertions(+), 2 deletions(-) diff --git a/include/geom/cell_hex20.h b/include/geom/cell_hex20.h index 18feb68a294..cf34de007e1 100644 --- a/include/geom/cell_hex20.h +++ b/include/geom/cell_hex20.h @@ -240,6 +240,12 @@ class Hex20 final : public Hex ElemType side_type (const unsigned int s) const override final; + /** + * \returns 8. Every side has eight nodes. + */ + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side_constant(s); } + protected: /** @@ -247,8 +253,6 @@ class Hex20 final : public Hex */ Node * _nodelinks_data[num_nodes]; - - #ifdef LIBMESH_ENABLE_AMR /** diff --git a/include/geom/cell_hex27.h b/include/geom/cell_hex27.h index 86bd5215d24..5b4a2d01ae1 100644 --- a/include/geom/cell_hex27.h +++ b/include/geom/cell_hex27.h @@ -258,6 +258,12 @@ class Hex27 final : public Hex ElemType side_type (const unsigned int s) const override final; + /** + * \returns 9. Every side has eight nodes. + */ + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side_constant(s); } + protected: diff --git a/include/geom/cell_hex8.h b/include/geom/cell_hex8.h index 78e45f08858..9dd7cf42944 100644 --- a/include/geom/cell_hex8.h +++ b/include/geom/cell_hex8.h @@ -215,6 +215,12 @@ class Hex8 final : public Hex ElemType side_type (const unsigned int s) const override final; + /** + * \returns 4. Every side has four nodes. + */ + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side_constant(s); } + protected: /** diff --git a/include/geom/cell_inf_hex.h b/include/geom/cell_inf_hex.h index b14a5ddbb85..3afaac58092 100644 --- a/include/geom/cell_inf_hex.h +++ b/include/geom/cell_inf_hex.h @@ -200,6 +200,19 @@ class InfHex : public InfCell */ static const unsigned int edge_sides_map[8][2]; + /** + * Helper for n_nodes_on_side() for InfHex-derived classes. + * + * That is, returns InfHex::nodes_per_side - \p remove_num + * for sides 1-4, and InfHex::nodes_per_side for side 0. + */ + template + unsigned int _n_nodes_on_side(const unsigned short s) const + { + static_assert(std::is_base_of::value, "Not a InfHex"); + return this->_n_nodes_on_side_constant(s) - ((s == 0) ? 0 : remove_num); + } + protected: /** diff --git a/include/geom/cell_inf_hex16.h b/include/geom/cell_inf_hex16.h index c8419ba4602..aaaa618896e 100644 --- a/include/geom/cell_inf_hex16.h +++ b/include/geom/cell_inf_hex16.h @@ -238,6 +238,9 @@ class InfHex16 final : public InfHex ElemType side_type (const unsigned int s) const override final; + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side(s); } + protected: /** diff --git a/include/geom/cell_inf_hex18.h b/include/geom/cell_inf_hex18.h index d09dcc41d62..1144139a0f9 100644 --- a/include/geom/cell_inf_hex18.h +++ b/include/geom/cell_inf_hex18.h @@ -253,6 +253,9 @@ class InfHex18 final : public InfHex ElemType side_type (const unsigned int s) const override final; + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side(s); } + protected: /** diff --git a/include/geom/cell_inf_hex8.h b/include/geom/cell_inf_hex8.h index 590be2aba8b..ce77e741b34 100644 --- a/include/geom/cell_inf_hex8.h +++ b/include/geom/cell_inf_hex8.h @@ -188,6 +188,12 @@ class InfHex8 final : public InfHex ElemType side_type (const unsigned int s) const override final; + /** + * \returns 4. Every side has four nodes. + */ + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side_constant(s); } + protected: /** diff --git a/include/geom/cell_inf_prism12.h b/include/geom/cell_inf_prism12.h index 6f9837ff52f..29b18281d0a 100644 --- a/include/geom/cell_inf_prism12.h +++ b/include/geom/cell_inf_prism12.h @@ -226,6 +226,12 @@ class InfPrism12 final : public InfPrism ElemType side_type (const unsigned int s) const override final; + /** + * \returns 6. Every side has six nodes. + */ + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side_constant(s); } + protected: /** diff --git a/include/geom/cell_inf_prism6.h b/include/geom/cell_inf_prism6.h index 3b1100e6cc2..cc3c5177a10 100644 --- a/include/geom/cell_inf_prism6.h +++ b/include/geom/cell_inf_prism6.h @@ -187,6 +187,9 @@ class InfPrism6 final : public InfPrism ElemType side_type (const unsigned int s) const override final; + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side_constant(s) - ((s == 0) ? 1 : 0); } + protected: /** diff --git a/include/geom/cell_prism.h b/include/geom/cell_prism.h index b856cb8854c..735b740df26 100644 --- a/include/geom/cell_prism.h +++ b/include/geom/cell_prism.h @@ -163,6 +163,19 @@ class Prism : public Cell protected: + /** + * Helper for n_nodes_on_side() for Prism-derived classes. + * + * That is, returns \p PrismClass::nodes_per_side for sides 1-3, and + * the same value minus \p remove_num for sides 0 and 4. + */ + template + unsigned int _n_nodes_on_side(const unsigned short s) const + { + static_assert(std::is_base_of::value, "Not a Prism"); + return this->_n_nodes_on_side_constant(s) - ((s == 0 || s == 4) ? remove_num : 0); + } + /** * Data for links to parent/neighbor/interior_parent elements. */ diff --git a/include/geom/cell_prism15.h b/include/geom/cell_prism15.h index 89c7ac56375..ce270731c48 100644 --- a/include/geom/cell_prism15.h +++ b/include/geom/cell_prism15.h @@ -245,6 +245,9 @@ class Prism15 final : public Prism ElemType side_type (const unsigned int s) const override final; + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return _n_nodes_on_side(s); } + protected: /** diff --git a/include/geom/cell_prism18.h b/include/geom/cell_prism18.h index fc646fa339c..259bb314398 100644 --- a/include/geom/cell_prism18.h +++ b/include/geom/cell_prism18.h @@ -263,6 +263,9 @@ class Prism18 final : public Prism ElemType side_type (const unsigned int s) const override final; + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return _n_nodes_on_side(s); } + protected: /** diff --git a/include/geom/cell_prism20.h b/include/geom/cell_prism20.h index e824e000c7f..bcd9fd8448c 100644 --- a/include/geom/cell_prism20.h +++ b/include/geom/cell_prism20.h @@ -262,6 +262,9 @@ class Prism20 final : public Prism ElemType side_type (const unsigned int s) const override final; + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return _n_nodes_on_side(s); } + protected: /** diff --git a/include/geom/cell_prism21.h b/include/geom/cell_prism21.h index c36da8469d1..f81a3af6c63 100644 --- a/include/geom/cell_prism21.h +++ b/include/geom/cell_prism21.h @@ -265,6 +265,9 @@ class Prism21 final : public Prism ElemType side_type (const unsigned int s) const override final; + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return _n_nodes_on_side(s); } + protected: /** diff --git a/include/geom/cell_prism6.h b/include/geom/cell_prism6.h index 5009bffda9b..606d4747cc3 100644 --- a/include/geom/cell_prism6.h +++ b/include/geom/cell_prism6.h @@ -205,6 +205,9 @@ class Prism6 final : public Prism ElemType side_type (const unsigned int s) const override final; + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return _n_nodes_on_side(s); } + protected: /** diff --git a/include/geom/cell_pyramid.h b/include/geom/cell_pyramid.h index f849bc8d2ef..ed84c9b55d2 100644 --- a/include/geom/cell_pyramid.h +++ b/include/geom/cell_pyramid.h @@ -186,6 +186,18 @@ class Pyramid : public Cell static const unsigned int edge_sides_map[8][2]; protected: + /** + * Helper for n_nodes_on_side() for Pyramid-derived classes. + * + * That is, returns PyramidClass::nodes_per_side - \p remove_num + * for sides 0-3, and PyramidClass::nodes_per_side for side 4. + */ + template + unsigned int _n_nodes_on_side(const unsigned short s) const + { + static_assert(std::is_base_of::value, "Not a Pyramid"); + return this->_n_nodes_on_side_constant(s) - ((s != 4) ? remove_num : 0); + } /** * Data for links to parent/neighbor/interior_parent elements. diff --git a/include/geom/cell_pyramid13.h b/include/geom/cell_pyramid13.h index 01acc193358..754cc9e7edf 100644 --- a/include/geom/cell_pyramid13.h +++ b/include/geom/cell_pyramid13.h @@ -233,6 +233,9 @@ class Pyramid13 final : public Pyramid ElemType side_type (const unsigned int s) const override final; + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return _n_nodes_on_side(s); } + protected: /** diff --git a/include/geom/cell_pyramid14.h b/include/geom/cell_pyramid14.h index 3a4aae940f8..d6db1661451 100644 --- a/include/geom/cell_pyramid14.h +++ b/include/geom/cell_pyramid14.h @@ -254,6 +254,9 @@ class Pyramid14 final : public Pyramid ElemType side_type (const unsigned int s) const override final; + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return _n_nodes_on_side(s); } + protected: /** diff --git a/include/geom/cell_pyramid5.h b/include/geom/cell_pyramid5.h index 9c08145b0e8..dd1b9b28c40 100644 --- a/include/geom/cell_pyramid5.h +++ b/include/geom/cell_pyramid5.h @@ -198,6 +198,9 @@ class Pyramid5 final : public Pyramid ElemType side_type (const unsigned int s) const override final; + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return _n_nodes_on_side(s); } + protected: /** diff --git a/include/geom/cell_tet10.h b/include/geom/cell_tet10.h index 9bb892f1afb..2379685d87e 100644 --- a/include/geom/cell_tet10.h +++ b/include/geom/cell_tet10.h @@ -241,6 +241,12 @@ class Tet10 final : public Tet ElemType side_type (const unsigned int s) const override final; + /** + * \returns 6. Every side has six nodes. + */ + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side_constant(s); } + protected: /** diff --git a/include/geom/cell_tet14.h b/include/geom/cell_tet14.h index 58ce212430d..bc7798ba86b 100644 --- a/include/geom/cell_tet14.h +++ b/include/geom/cell_tet14.h @@ -241,6 +241,12 @@ class Tet14 final : public Tet ElemType side_type (const unsigned int s) const override final; + /** + * \returns 7. Every side has seven nodes. + */ + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side_constant(s); } + #ifdef LIBMESH_ENABLE_AMR virtual const std::vector> & diff --git a/include/geom/cell_tet4.h b/include/geom/cell_tet4.h index 0ab14cc4122..7191083e62d 100644 --- a/include/geom/cell_tet4.h +++ b/include/geom/cell_tet4.h @@ -248,6 +248,12 @@ class Tet4 final : public Tet ElemType side_type (const unsigned int s) const override final; + /** + * \returns 3. Every side has three nodes. + */ + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side_constant(s); } + protected: /** diff --git a/include/geom/edge.h b/include/geom/edge.h index 72d12624c46..8ab20d91d8e 100644 --- a/include/geom/edge.h +++ b/include/geom/edge.h @@ -214,6 +214,12 @@ class Edge : public Elem ElemType side_type (const unsigned int s) const override final; + /** + * \returns 1. Every side has one node. + */ + virtual unsigned int n_nodes_on_side(const unsigned short libmesh_dbg_var(s)) const override final + { libmesh_assert_less(s, 2); return 1; } + protected: /** diff --git a/include/geom/elem.h b/include/geom/elem.h index 9a257be6f0f..cae15a24efa 100644 --- a/include/geom/elem.h +++ b/include/geom/elem.h @@ -598,6 +598,11 @@ class Elem : public ReferenceCountedObject, */ virtual unsigned int n_nodes () const = 0; + /** + * \returns The number of nodes on the side with index \p s. + */ + virtual unsigned int n_nodes_on_side (const unsigned short s) const = 0; + /** * The maximum number of nodes *any* element can contain. * This is useful for replacing heap vectors with stack arrays. @@ -2001,6 +2006,20 @@ class Elem : public ReferenceCountedObject, ElemType edgetype); + /** + * Helper for overriding n_nodes_on_side in derived classes. + * + * Performs bound checking on \p s and returns nodes_per_side + * for the given class for all sides. + */ + template + unsigned int _n_nodes_on_side_constant(const unsigned short libmesh_dbg_var(s)) const + { + static_assert(std::is_base_of::value, "Not an Elem"); + libmesh_assert_less(s, this->n_sides()); + return ElemClass::nodes_per_side; + } + #ifdef LIBMESH_ENABLE_AMR /** diff --git a/include/geom/face_inf_quad4.h b/include/geom/face_inf_quad4.h index 1500d521df1..57f818e930b 100644 --- a/include/geom/face_inf_quad4.h +++ b/include/geom/face_inf_quad4.h @@ -164,6 +164,9 @@ class InfQuad4 : public InfQuad virtual void flip(BoundaryInfo *) override final; + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side_constant(s); } + protected: /** diff --git a/include/geom/face_inf_quad6.h b/include/geom/face_inf_quad6.h index 28d36d38dd8..b52855cb201 100644 --- a/include/geom/face_inf_quad6.h +++ b/include/geom/face_inf_quad6.h @@ -200,6 +200,9 @@ class InfQuad6 : public InfQuad virtual void flip(BoundaryInfo *) override final; + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side_constant(s) - (s == 0 ? 0 : 1); } + protected: /** diff --git a/include/geom/face_quad4.h b/include/geom/face_quad4.h index c2c44ae1e06..0f7fb76b580 100644 --- a/include/geom/face_quad4.h +++ b/include/geom/face_quad4.h @@ -178,6 +178,12 @@ class Quad4 : public Quad ElemType side_type (const unsigned int s) const override final; + /** + * \returns 2. Every side has seven nodes. + */ + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side_constant(s); } + protected: /** diff --git a/include/geom/face_quad8.h b/include/geom/face_quad8.h index 731388b7a86..9ca14e3aec9 100644 --- a/include/geom/face_quad8.h +++ b/include/geom/face_quad8.h @@ -217,6 +217,12 @@ class Quad8 : public Quad ElemType side_type (const unsigned int s) const override final; + /** + * \returns 3. Every side has three nodes. + */ + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side_constant(s); } + protected: /** diff --git a/include/geom/face_quad9.h b/include/geom/face_quad9.h index 33f5c440e62..ea572fe324e 100644 --- a/include/geom/face_quad9.h +++ b/include/geom/face_quad9.h @@ -224,6 +224,12 @@ class Quad9 : public Quad ElemType side_type (const unsigned int s) const override final; + /** + * \returns 3. Every side has three nodes. + */ + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side_constant(s); } + protected: /** diff --git a/include/geom/face_tri3.h b/include/geom/face_tri3.h index 132e4c0078e..5a04c4bc534 100644 --- a/include/geom/face_tri3.h +++ b/include/geom/face_tri3.h @@ -203,6 +203,12 @@ class Tri3 : public Tri ElemType side_type (const unsigned int s) const override final; + /** + * \returns 2. Every side has two nodes. + */ + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side_constant(s); } + protected: /** diff --git a/include/geom/face_tri6.h b/include/geom/face_tri6.h index 2d568fa90aa..47d84b5a1db 100644 --- a/include/geom/face_tri6.h +++ b/include/geom/face_tri6.h @@ -227,6 +227,12 @@ class Tri6 : public Tri ElemType side_type (const unsigned int s) const override final; + /** + * \returns 3. Every side has three nodes. + */ + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side_constant(s); } + protected: /** diff --git a/include/geom/face_tri7.h b/include/geom/face_tri7.h index 953896d2d13..7a66c729fe1 100644 --- a/include/geom/face_tri7.h +++ b/include/geom/face_tri7.h @@ -233,6 +233,12 @@ class Tri7 : public Tri ElemType side_type (const unsigned int s) const override final; + /** + * \returns 3. Every side has three nodes. + */ + virtual unsigned int n_nodes_on_side(const unsigned short s) const override final + { return this->_n_nodes_on_side_constant(s); } + protected: /** diff --git a/include/geom/node_elem.h b/include/geom/node_elem.h index cbd0d5af4bb..72a0c8ed66f 100644 --- a/include/geom/node_elem.h +++ b/include/geom/node_elem.h @@ -77,6 +77,12 @@ class NodeElem : public Elem */ virtual unsigned int n_nodes() const override { return 1; } + /** + * The \p Elem::n_nodes_on_side makes no sense for nodes. + */ + virtual unsigned int n_nodes_on_side(const unsigned short) const override + { libmesh_not_implemented(); return 0; } + /** * \returns 0. */ diff --git a/include/geom/remote_elem.h b/include/geom/remote_elem.h index 490e777c621..659487add6c 100644 --- a/include/geom/remote_elem.h +++ b/include/geom/remote_elem.h @@ -119,6 +119,9 @@ class RemoteElem : public Elem, virtual unsigned int n_nodes () const override { libmesh_not_implemented(); return 0; } + virtual unsigned int n_nodes_on_side (const unsigned short) const override + { libmesh_not_implemented(); return 0; } + virtual unsigned int n_sides () const override { libmesh_not_implemented(); return 0; } diff --git a/tests/geom/elem_test.C b/tests/geom/elem_test.C index 54bebcda16d..77d7e357721 100644 --- a/tests/geom/elem_test.C +++ b/tests/geom/elem_test.C @@ -488,6 +488,21 @@ public: CPPUNIT_ASSERT_EQUAL(elem->build_side_ptr(s)->type(), elem->side_type(s)); } + void test_n_nodes_on_side() + { + LOG_UNIT_TEST; + + for (const auto & elem : _mesh->active_local_element_ptr_range()) + for (const auto s : elem->side_index_range()) + { + unsigned int n_nodes_on_side = 0; + for (const auto n : elem->node_index_range()) + if (elem->is_node_on_side(n, s)) + ++n_nodes_on_side; + CPPUNIT_ASSERT_EQUAL(n_nodes_on_side, elem->n_nodes_on_side(s)); + } + }; + void test_n_vertices_on_side() { LOG_UNIT_TEST; @@ -536,6 +551,7 @@ public: CPPUNIT_TEST( test_contains_point_node ); \ CPPUNIT_TEST( test_center_node_on_side ); \ CPPUNIT_TEST( test_side_type ); \ + CPPUNIT_TEST( test_n_nodes_on_side ); \ CPPUNIT_TEST( test_n_vertices_on_side ); \ CPPUNIT_TEST( test_elem_side_builder ); From 0941b260c44440e2269bafcf585d7746c9c4c90d Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Wed, 9 Nov 2022 11:31:17 -0700 Subject: [PATCH 05/30] Add Elem::nodes_on_side_ptr --- include/geom/cell_hex20.h | 3 +++ include/geom/cell_hex27.h | 3 +++ include/geom/cell_hex8.h | 3 +++ include/geom/cell_inf_hex16.h | 3 +++ include/geom/cell_inf_hex18.h | 3 +++ include/geom/cell_inf_hex8.h | 3 +++ include/geom/cell_inf_prism12.h | 3 +++ include/geom/cell_inf_prism6.h | 3 +++ include/geom/cell_prism15.h | 3 +++ include/geom/cell_prism18.h | 3 +++ include/geom/cell_prism20.h | 3 +++ include/geom/cell_prism21.h | 3 +++ include/geom/cell_prism6.h | 3 +++ include/geom/cell_pyramid13.h | 3 +++ include/geom/cell_pyramid14.h | 3 +++ include/geom/cell_pyramid5.h | 3 +++ include/geom/cell_tet10.h | 3 +++ include/geom/cell_tet14.h | 3 +++ include/geom/cell_tet4.h | 3 +++ include/geom/edge.h | 17 +++++++++++++++++ include/geom/edge_edge2.h | 4 ---- include/geom/edge_edge3.h | 4 ---- include/geom/edge_edge4.h | 4 ---- include/geom/elem.h | 21 ++++++++++++++++++++- include/geom/face_inf_quad4.h | 3 +++ include/geom/face_inf_quad6.h | 3 +++ include/geom/face_quad4.h | 3 +++ include/geom/face_quad8.h | 3 +++ include/geom/face_quad9.h | 3 +++ include/geom/face_tri3.h | 3 +++ include/geom/face_tri6.h | 3 +++ include/geom/face_tri7.h | 3 +++ include/geom/node_elem.h | 6 ++++++ include/geom/remote_elem.h | 3 +++ src/geom/edge.C | 15 +++++++++++++++ src/geom/edge_edge2.C | 4 ---- src/geom/edge_edge3.C | 4 ---- src/geom/edge_edge4.C | 4 ---- tests/geom/elem_test.C | 15 +++++++++++++++ 39 files changed, 157 insertions(+), 25 deletions(-) diff --git a/include/geom/cell_hex20.h b/include/geom/cell_hex20.h index cf34de007e1..336fffb27e1 100644 --- a/include/geom/cell_hex20.h +++ b/include/geom/cell_hex20.h @@ -124,6 +124,9 @@ class Hex20 final : public Hex virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/cell_hex27.h b/include/geom/cell_hex27.h index 5b4a2d01ae1..87ce1bbe056 100644 --- a/include/geom/cell_hex27.h +++ b/include/geom/cell_hex27.h @@ -124,6 +124,9 @@ class Hex27 final : public Hex virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/cell_hex8.h b/include/geom/cell_hex8.h index 9dd7cf42944..1b5086d10bb 100644 --- a/include/geom/cell_hex8.h +++ b/include/geom/cell_hex8.h @@ -109,6 +109,9 @@ class Hex8 final : public Hex virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/cell_inf_hex16.h b/include/geom/cell_inf_hex16.h index aaaa618896e..a928e40206d 100644 --- a/include/geom/cell_inf_hex16.h +++ b/include/geom/cell_inf_hex16.h @@ -124,6 +124,9 @@ class InfHex16 final : public InfHex virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/cell_inf_hex18.h b/include/geom/cell_inf_hex18.h index 1144139a0f9..5a7d2404a92 100644 --- a/include/geom/cell_inf_hex18.h +++ b/include/geom/cell_inf_hex18.h @@ -129,6 +129,9 @@ class InfHex18 final : public InfHex virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/cell_inf_hex8.h b/include/geom/cell_inf_hex8.h index ce77e741b34..9db4f3cd220 100644 --- a/include/geom/cell_inf_hex8.h +++ b/include/geom/cell_inf_hex8.h @@ -109,6 +109,9 @@ class InfHex8 final : public InfHex virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/cell_inf_prism12.h b/include/geom/cell_inf_prism12.h index 29b18281d0a..201f8310eab 100644 --- a/include/geom/cell_inf_prism12.h +++ b/include/geom/cell_inf_prism12.h @@ -115,6 +115,9 @@ class InfPrism12 final : public InfPrism virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/cell_inf_prism6.h b/include/geom/cell_inf_prism6.h index cc3c5177a10..d0a330bfb1a 100644 --- a/include/geom/cell_inf_prism6.h +++ b/include/geom/cell_inf_prism6.h @@ -111,6 +111,9 @@ class InfPrism6 final : public InfPrism virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/cell_prism15.h b/include/geom/cell_prism15.h index ce270731c48..28f95bc9260 100644 --- a/include/geom/cell_prism15.h +++ b/include/geom/cell_prism15.h @@ -129,6 +129,9 @@ class Prism15 final : public Prism virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/cell_prism18.h b/include/geom/cell_prism18.h index 259bb314398..c5da705a0d7 100644 --- a/include/geom/cell_prism18.h +++ b/include/geom/cell_prism18.h @@ -129,6 +129,9 @@ class Prism18 final : public Prism virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/cell_prism20.h b/include/geom/cell_prism20.h index bcd9fd8448c..10651a8f547 100644 --- a/include/geom/cell_prism20.h +++ b/include/geom/cell_prism20.h @@ -133,6 +133,9 @@ class Prism20 final : public Prism virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/cell_prism21.h b/include/geom/cell_prism21.h index f81a3af6c63..748195057b5 100644 --- a/include/geom/cell_prism21.h +++ b/include/geom/cell_prism21.h @@ -136,6 +136,9 @@ class Prism21 final : public Prism virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/cell_prism6.h b/include/geom/cell_prism6.h index 606d4747cc3..6669e0fca9b 100644 --- a/include/geom/cell_prism6.h +++ b/include/geom/cell_prism6.h @@ -107,6 +107,9 @@ class Prism6 final : public Prism virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/cell_pyramid13.h b/include/geom/cell_pyramid13.h index 754cc9e7edf..7ed50fe299c 100644 --- a/include/geom/cell_pyramid13.h +++ b/include/geom/cell_pyramid13.h @@ -128,6 +128,9 @@ class Pyramid13 final : public Pyramid virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/cell_pyramid14.h b/include/geom/cell_pyramid14.h index d6db1661451..befc706f02d 100644 --- a/include/geom/cell_pyramid14.h +++ b/include/geom/cell_pyramid14.h @@ -131,6 +131,9 @@ class Pyramid14 final : public Pyramid virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/cell_pyramid5.h b/include/geom/cell_pyramid5.h index dd1b9b28c40..fa7e1d89649 100644 --- a/include/geom/cell_pyramid5.h +++ b/include/geom/cell_pyramid5.h @@ -106,6 +106,9 @@ class Pyramid5 final : public Pyramid virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/cell_tet10.h b/include/geom/cell_tet10.h index 2379685d87e..7250799a065 100644 --- a/include/geom/cell_tet10.h +++ b/include/geom/cell_tet10.h @@ -118,6 +118,9 @@ class Tet10 final : public Tet virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/cell_tet14.h b/include/geom/cell_tet14.h index bc7798ba86b..f0b49c08de4 100644 --- a/include/geom/cell_tet14.h +++ b/include/geom/cell_tet14.h @@ -124,6 +124,9 @@ class Tet14 final : public Tet virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/cell_tet4.h b/include/geom/cell_tet4.h index 7191083e62d..1eba74915e9 100644 --- a/include/geom/cell_tet4.h +++ b/include/geom/cell_tet4.h @@ -113,6 +113,9 @@ class Tet4 final : public Tet virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/edge.h b/include/geom/edge.h index 8ab20d91d8e..c0652c088ba 100644 --- a/include/geom/edge.h +++ b/include/geom/edge.h @@ -58,6 +58,14 @@ class Edge : public Elem Edge & operator= (Edge &&) = delete; virtual ~Edge() = default; + /** + * Geometric constants for all edges. + */ + static const int num_sides = 2; + static const int num_edges = 0; + static const int nodes_per_side = 1; + static const int nodes_per_edge = invalid_int; + /** * \returns 1, the dimensionality of the object. */ @@ -188,11 +196,20 @@ class Edge : public Elem virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { libmesh_assert_less(s, this->n_sides()); return side_nodes_map[s]; } + virtual std::vector nodes_on_edge(const unsigned int e) const override; virtual std::vector sides_on_edge(const unsigned int) const override final { return {}; } + /** + * This maps the \f$ j^{th} \f$ node of the \f$ i^{th} \f$ side to + * element node numbers. + */ + static const unsigned int side_nodes_map[2][1]; + /** * \returns The "circumcenter of mass" (area-weighted average of * triangulation circumcenters) of the element. diff --git a/include/geom/edge_edge2.h b/include/geom/edge_edge2.h index 329c9353785..dfcadaa0784 100644 --- a/include/geom/edge_edge2.h +++ b/include/geom/edge_edge2.h @@ -171,11 +171,7 @@ class Edge2 : public Edge * Geometric constants for Edge2. */ static const int num_nodes = 2; - static const int num_sides = 2; - static const int num_edges = 0; static const int num_children = 2; - static const int nodes_per_side = 1; - static const int nodes_per_edge = invalid_int; virtual void flip(BoundaryInfo *) override final; diff --git a/include/geom/edge_edge3.h b/include/geom/edge_edge3.h index 3ce1285468b..9800444d4f3 100644 --- a/include/geom/edge_edge3.h +++ b/include/geom/edge_edge3.h @@ -198,11 +198,7 @@ class Edge3 : public Edge * Geometric constants for Edge3. */ static const int num_nodes = 3; - static const int num_sides = 2; - static const int num_edges = 0; static const int num_children = 2; - static const int nodes_per_side = 1; - static const int nodes_per_edge = invalid_int; virtual void flip(BoundaryInfo *) override final; diff --git a/include/geom/edge_edge4.h b/include/geom/edge_edge4.h index 0eccbcb0bb7..eaf692eaa2a 100644 --- a/include/geom/edge_edge4.h +++ b/include/geom/edge_edge4.h @@ -192,11 +192,7 @@ class Edge4 final : public Edge * Geometric constants for Edge4. */ static const int num_nodes = 4; - static const int num_sides = 2; - static const int num_edges = 0; static const int num_children = 2; - static const int nodes_per_side = 1; - static const int nodes_per_edge = invalid_int; virtual void flip(BoundaryInfo *) override final; diff --git a/include/geom/elem.h b/include/geom/elem.h index cae15a24efa..1abcd40fc91 100644 --- a/include/geom/elem.h +++ b/include/geom/elem.h @@ -750,6 +750,15 @@ class Elem : public ReferenceCountedObject, */ virtual std::vector nodes_on_side(const unsigned int /*s*/) const = 0; + /** + * \returns A pointer to the beginning of the array that contains the + * (local) node numbers on the specified side + * + * This does not create temproraries, unlike \p nodes_on_side. + * Use n_nodes_on_side for indexing. + */ + virtual const unsigned int * nodes_on_side_ptr(const unsigned short) const = 0; + /** * \returns the (local) node numbers on the specified edge */ @@ -2005,7 +2014,6 @@ class Elem : public ReferenceCountedObject, const unsigned int i, ElemType edgetype); - /** * Helper for overriding n_nodes_on_side in derived classes. * @@ -2020,6 +2028,17 @@ class Elem : public ReferenceCountedObject, return ElemClass::nodes_per_side; } + /** + * Helper for overriding nodes_on_side in derived classes. + */ + template + const unsigned int * _nodes_on_side_ptr(const unsigned short s) const + { + static_assert(std::is_base_of::value, "Not an Elem"); + libmesh_assert_less(s, std::extent::value); + return ElemClass::side_nodes_map[s]; + } + #ifdef LIBMESH_ENABLE_AMR /** diff --git a/include/geom/face_inf_quad4.h b/include/geom/face_inf_quad4.h index 57f818e930b..6f7fc18fdf7 100644 --- a/include/geom/face_inf_quad4.h +++ b/include/geom/face_inf_quad4.h @@ -105,6 +105,9 @@ class InfQuad4 : public InfQuad virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/face_inf_quad6.h b/include/geom/face_inf_quad6.h index b52855cb201..559a27d06f3 100644 --- a/include/geom/face_inf_quad6.h +++ b/include/geom/face_inf_quad6.h @@ -106,6 +106,9 @@ class InfQuad6 : public InfQuad virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/face_quad4.h b/include/geom/face_quad4.h index 0f7fb76b580..c032f03a935 100644 --- a/include/geom/face_quad4.h +++ b/include/geom/face_quad4.h @@ -101,6 +101,9 @@ class Quad4 : public Quad virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/face_quad8.h b/include/geom/face_quad8.h index 9ca14e3aec9..3ce33cb8411 100644 --- a/include/geom/face_quad8.h +++ b/include/geom/face_quad8.h @@ -104,6 +104,9 @@ class Quad8 : public Quad virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/face_quad9.h b/include/geom/face_quad9.h index ea572fe324e..8edbb54f5cf 100644 --- a/include/geom/face_quad9.h +++ b/include/geom/face_quad9.h @@ -104,6 +104,9 @@ class Quad9 : public Quad virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/face_tri3.h b/include/geom/face_tri3.h index 5a04c4bc534..5d9d39c7fa3 100644 --- a/include/geom/face_tri3.h +++ b/include/geom/face_tri3.h @@ -109,6 +109,9 @@ class Tri3 : public Tri virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/face_tri6.h b/include/geom/face_tri6.h index 47d84b5a1db..900fa09fdbc 100644 --- a/include/geom/face_tri6.h +++ b/include/geom/face_tri6.h @@ -114,6 +114,9 @@ class Tri6 : public Tri virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/face_tri7.h b/include/geom/face_tri7.h index 7a66c729fe1..589eb7de242 100644 --- a/include/geom/face_tri7.h +++ b/include/geom/face_tri7.h @@ -114,6 +114,9 @@ class Tri7 : public Tri virtual std::vector nodes_on_side(const unsigned int s) const override; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const override final + { return this->_nodes_on_side_ptr(s); } + virtual std::vector nodes_on_edge(const unsigned int e) const override; /** diff --git a/include/geom/node_elem.h b/include/geom/node_elem.h index 72a0c8ed66f..65ba5027815 100644 --- a/include/geom/node_elem.h +++ b/include/geom/node_elem.h @@ -83,6 +83,12 @@ class NodeElem : public Elem virtual unsigned int n_nodes_on_side(const unsigned short) const override { libmesh_not_implemented(); return 0; } + /** + * The \p Elem::nodes_on_side_ptr makes no sense for nodes. + */ + virtual const unsigned int * nodes_on_side_ptr(const unsigned short) const override final + { libmesh_not_implemented(); return nullptr; } + /** * \returns 0. */ diff --git a/include/geom/remote_elem.h b/include/geom/remote_elem.h index 659487add6c..e4f3fdc87b0 100644 --- a/include/geom/remote_elem.h +++ b/include/geom/remote_elem.h @@ -159,6 +159,9 @@ class RemoteElem : public Elem, return {0}; } + virtual const unsigned int * nodes_on_side_ptr(const unsigned short) const override + { libmesh_not_implemented(); return nullptr; } + virtual std::vector nodes_on_edge(const unsigned int) const override { libmesh_not_implemented(); diff --git a/src/geom/edge.C b/src/geom/edge.C index ebe238dfbdc..a8400cf9dd6 100644 --- a/src/geom/edge.C +++ b/src/geom/edge.C @@ -24,6 +24,21 @@ namespace libMesh { + +// ------------------------------------------------------------ +// Edge class static member initializations + +const int Edge::num_sides; +const int Edge::num_edges; +const int Edge::nodes_per_side; +const int Edge::nodes_per_edge; + +const unsigned int Edge::side_nodes_map[Edge::num_sides][Edge::nodes_per_side] = + { + {0}, // Side 0 + {1}, // Side 1 + }; + unsigned int Edge::local_side_node(unsigned int side, unsigned int /*side_node*/) const { diff --git a/src/geom/edge_edge2.C b/src/geom/edge_edge2.C index b8650e0b653..671294b123a 100644 --- a/src/geom/edge_edge2.C +++ b/src/geom/edge_edge2.C @@ -28,11 +28,7 @@ namespace libMesh // Edge2 class static member initializations const int Edge2::num_nodes; -const int Edge2::num_sides; -const int Edge2::num_edges; const int Edge2::num_children; -const int Edge2::nodes_per_side; -const int Edge2::nodes_per_edge; #ifdef LIBMESH_ENABLE_AMR diff --git a/src/geom/edge_edge3.C b/src/geom/edge_edge3.C index f99d691d070..e48b8ddb8dc 100644 --- a/src/geom/edge_edge3.C +++ b/src/geom/edge_edge3.C @@ -27,11 +27,7 @@ namespace libMesh // Edge3 class static member initializations const int Edge3::num_nodes; -const int Edge3::num_sides; -const int Edge3::num_edges; const int Edge3::num_children; -const int Edge3::nodes_per_side; -const int Edge3::nodes_per_edge; #ifdef LIBMESH_ENABLE_AMR diff --git a/src/geom/edge_edge4.C b/src/geom/edge_edge4.C index e23a69e1963..25ea0b12ea1 100644 --- a/src/geom/edge_edge4.C +++ b/src/geom/edge_edge4.C @@ -27,11 +27,7 @@ namespace libMesh // Edge4 class static member initializations const int Edge4::num_nodes; -const int Edge4::num_sides; -const int Edge4::num_edges; const int Edge4::num_children; -const int Edge4::nodes_per_side; -const int Edge4::nodes_per_edge; #ifdef LIBMESH_ENABLE_AMR diff --git a/tests/geom/elem_test.C b/tests/geom/elem_test.C index 77d7e357721..b310ef6799d 100644 --- a/tests/geom/elem_test.C +++ b/tests/geom/elem_test.C @@ -518,6 +518,20 @@ public: } }; + void test_nodes_on_side_ptr() + { + LOG_UNIT_TEST; + + for (const auto & elem : _mesh->active_local_element_ptr_range()) + for (const auto s : elem->side_index_range()) + { + const auto nodes_on_side = elem->nodes_on_side(s); + const auto nodes_on_side_ptr = elem->nodes_on_side_ptr(s); + for (const auto i : index_range(nodes_on_side)) + CPPUNIT_ASSERT_EQUAL(nodes_on_side[i], nodes_on_side_ptr[i]); + } + }; + void test_elem_side_builder() { LOG_UNIT_TEST; @@ -553,6 +567,7 @@ public: CPPUNIT_TEST( test_side_type ); \ CPPUNIT_TEST( test_n_nodes_on_side ); \ CPPUNIT_TEST( test_n_vertices_on_side ); \ + CPPUNIT_TEST( test_nodes_on_side_ptr ); \ CPPUNIT_TEST( test_elem_side_builder ); #define INSTANTIATE_ELEMTEST(elemtype) \ From 1c1d5b03c1cdfc06cefc967da98de940e0deb666 Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Wed, 9 Nov 2022 13:25:00 -0700 Subject: [PATCH 06/30] Add Elem::n_nodes_on_edge --- include/geom/cell_hex20.h | 6 ++++++ include/geom/cell_hex27.h | 6 ++++++ include/geom/cell_hex8.h | 6 ++++++ include/geom/cell_inf_hex16.h | 3 +++ include/geom/cell_inf_hex18.h | 3 +++ include/geom/cell_inf_hex8.h | 6 ++++++ include/geom/cell_inf_prism12.h | 3 +++ include/geom/cell_inf_prism6.h | 3 +++ include/geom/cell_prism15.h | 6 ++++++ include/geom/cell_prism18.h | 6 ++++++ include/geom/cell_prism20.h | 6 ++++++ include/geom/cell_prism21.h | 6 ++++++ include/geom/cell_prism6.h | 6 ++++++ include/geom/cell_pyramid13.h | 6 ++++++ include/geom/cell_pyramid14.h | 6 ++++++ include/geom/cell_pyramid5.h | 6 ++++++ include/geom/cell_tet10.h | 6 ++++++ include/geom/cell_tet14.h | 6 ++++++ include/geom/cell_tet4.h | 6 ++++++ include/geom/edge.h | 6 ++++++ include/geom/elem.h | 19 +++++++++++++++++++ include/geom/face.h | 3 +++ include/geom/face_inf_quad.h | 3 +++ include/geom/node_elem.h | 6 ++++++ include/geom/remote_elem.h | 3 +++ tests/geom/elem_test.C | 16 ++++++++++++++++ 26 files changed, 158 insertions(+) diff --git a/include/geom/cell_hex20.h b/include/geom/cell_hex20.h index 336fffb27e1..b418bdf6856 100644 --- a/include/geom/cell_hex20.h +++ b/include/geom/cell_hex20.h @@ -249,6 +249,12 @@ class Hex20 final : public Hex virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return this->_n_nodes_on_side_constant(s); } + /** + * \returns 3. Every edge has two nodes. + */ + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e); } + protected: /** diff --git a/include/geom/cell_hex27.h b/include/geom/cell_hex27.h index 87ce1bbe056..c83c80de66c 100644 --- a/include/geom/cell_hex27.h +++ b/include/geom/cell_hex27.h @@ -267,6 +267,12 @@ class Hex27 final : public Hex virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return this->_n_nodes_on_side_constant(s); } + /** + * \returns 3. Every edge has three nodes. + */ + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e); } + protected: diff --git a/include/geom/cell_hex8.h b/include/geom/cell_hex8.h index 1b5086d10bb..c87befa2cca 100644 --- a/include/geom/cell_hex8.h +++ b/include/geom/cell_hex8.h @@ -224,6 +224,12 @@ class Hex8 final : public Hex virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return this->_n_nodes_on_side_constant(s); } + /** + * \returns 2. Every edge has two nodes. + */ + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e); } + protected: /** diff --git a/include/geom/cell_inf_hex16.h b/include/geom/cell_inf_hex16.h index a928e40206d..43651cb4f7a 100644 --- a/include/geom/cell_inf_hex16.h +++ b/include/geom/cell_inf_hex16.h @@ -244,6 +244,9 @@ class InfHex16 final : public InfHex virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return this->_n_nodes_on_side(s); } + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e) - ((e < 4) ? 0 : 1); } + protected: /** diff --git a/include/geom/cell_inf_hex18.h b/include/geom/cell_inf_hex18.h index 5a7d2404a92..721c5890ad9 100644 --- a/include/geom/cell_inf_hex18.h +++ b/include/geom/cell_inf_hex18.h @@ -259,6 +259,9 @@ class InfHex18 final : public InfHex virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return this->_n_nodes_on_side(s); } + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e) - ((e < 4) ? 0 : 1); } + protected: /** diff --git a/include/geom/cell_inf_hex8.h b/include/geom/cell_inf_hex8.h index 9db4f3cd220..a3b41c4460a 100644 --- a/include/geom/cell_inf_hex8.h +++ b/include/geom/cell_inf_hex8.h @@ -197,6 +197,12 @@ class InfHex8 final : public InfHex virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return this->_n_nodes_on_side_constant(s); } + /** + * \returns 2. Every edge has two nodes. + */ + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e); } + protected: /** diff --git a/include/geom/cell_inf_prism12.h b/include/geom/cell_inf_prism12.h index 201f8310eab..9ccaf33b956 100644 --- a/include/geom/cell_inf_prism12.h +++ b/include/geom/cell_inf_prism12.h @@ -235,6 +235,9 @@ class InfPrism12 final : public InfPrism virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return this->_n_nodes_on_side_constant(s); } + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e) - ((e < 3) ? 0 : 1); } + protected: /** diff --git a/include/geom/cell_inf_prism6.h b/include/geom/cell_inf_prism6.h index d0a330bfb1a..3c6a72ecc26 100644 --- a/include/geom/cell_inf_prism6.h +++ b/include/geom/cell_inf_prism6.h @@ -193,6 +193,9 @@ class InfPrism6 final : public InfPrism virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return this->_n_nodes_on_side_constant(s) - ((s == 0) ? 1 : 0); } + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e); } + protected: /** diff --git a/include/geom/cell_prism15.h b/include/geom/cell_prism15.h index 28f95bc9260..d579d788da5 100644 --- a/include/geom/cell_prism15.h +++ b/include/geom/cell_prism15.h @@ -251,6 +251,12 @@ class Prism15 final : public Prism virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return _n_nodes_on_side(s); } + /** + * \returns 3. Every edge has three nodes. + */ + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e); } + protected: /** diff --git a/include/geom/cell_prism18.h b/include/geom/cell_prism18.h index c5da705a0d7..4c3e69d2b09 100644 --- a/include/geom/cell_prism18.h +++ b/include/geom/cell_prism18.h @@ -269,6 +269,12 @@ class Prism18 final : public Prism virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return _n_nodes_on_side(s); } + /** + * \returns 3. Every edge has three nodes. + */ + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e); } + protected: /** diff --git a/include/geom/cell_prism20.h b/include/geom/cell_prism20.h index 10651a8f547..492d262f5af 100644 --- a/include/geom/cell_prism20.h +++ b/include/geom/cell_prism20.h @@ -268,6 +268,12 @@ class Prism20 final : public Prism virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return _n_nodes_on_side(s); } + /** + * \returns 3. Every edge has three nodes. + */ + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e); } + protected: /** diff --git a/include/geom/cell_prism21.h b/include/geom/cell_prism21.h index 748195057b5..c2dd6d33430 100644 --- a/include/geom/cell_prism21.h +++ b/include/geom/cell_prism21.h @@ -271,6 +271,12 @@ class Prism21 final : public Prism virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return _n_nodes_on_side(s); } + /** + * \returns 3. Every edge has three nodes. + */ + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e); } + protected: /** diff --git a/include/geom/cell_prism6.h b/include/geom/cell_prism6.h index 6669e0fca9b..97f4ece10ac 100644 --- a/include/geom/cell_prism6.h +++ b/include/geom/cell_prism6.h @@ -211,6 +211,12 @@ class Prism6 final : public Prism virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return _n_nodes_on_side(s); } + /** + * \returns 2. Every edge has two nodes. + */ + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e); } + protected: /** diff --git a/include/geom/cell_pyramid13.h b/include/geom/cell_pyramid13.h index 7ed50fe299c..e243328d42e 100644 --- a/include/geom/cell_pyramid13.h +++ b/include/geom/cell_pyramid13.h @@ -239,6 +239,12 @@ class Pyramid13 final : public Pyramid virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return _n_nodes_on_side(s); } + /** + * \returns 3. Every edge has three nodes. + */ + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e); } + protected: /** diff --git a/include/geom/cell_pyramid14.h b/include/geom/cell_pyramid14.h index befc706f02d..27002abaa4c 100644 --- a/include/geom/cell_pyramid14.h +++ b/include/geom/cell_pyramid14.h @@ -260,6 +260,12 @@ class Pyramid14 final : public Pyramid virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return _n_nodes_on_side(s); } + /** + * \returns 3. Every edge has three nodes. + */ + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e); } + protected: /** diff --git a/include/geom/cell_pyramid5.h b/include/geom/cell_pyramid5.h index fa7e1d89649..d83dae6f9e9 100644 --- a/include/geom/cell_pyramid5.h +++ b/include/geom/cell_pyramid5.h @@ -204,6 +204,12 @@ class Pyramid5 final : public Pyramid virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return _n_nodes_on_side(s); } + /** + * \returns 2. Every edge has two nodes. + */ + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e); } + protected: /** diff --git a/include/geom/cell_tet10.h b/include/geom/cell_tet10.h index 7250799a065..ae79ba42df1 100644 --- a/include/geom/cell_tet10.h +++ b/include/geom/cell_tet10.h @@ -250,6 +250,12 @@ class Tet10 final : public Tet virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return this->_n_nodes_on_side_constant(s); } + /** + * \returns 3. Every edge has three nodes. + */ + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e); } + protected: /** diff --git a/include/geom/cell_tet14.h b/include/geom/cell_tet14.h index f0b49c08de4..5080743a4d3 100644 --- a/include/geom/cell_tet14.h +++ b/include/geom/cell_tet14.h @@ -250,6 +250,12 @@ class Tet14 final : public Tet virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return this->_n_nodes_on_side_constant(s); } + /** + * \returns 3. Every edge has three nodes. + */ + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e); } + #ifdef LIBMESH_ENABLE_AMR virtual const std::vector> & diff --git a/include/geom/cell_tet4.h b/include/geom/cell_tet4.h index 1eba74915e9..08ca940ec02 100644 --- a/include/geom/cell_tet4.h +++ b/include/geom/cell_tet4.h @@ -257,6 +257,12 @@ class Tet4 final : public Tet virtual unsigned int n_nodes_on_side(const unsigned short s) const override final { return this->_n_nodes_on_side_constant(s); } + /** + * \returns 2. Every edge has two nodes. + */ + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->_n_nodes_on_edge_constant(e); } + protected: /** diff --git a/include/geom/edge.h b/include/geom/edge.h index c0652c088ba..386fb6493f3 100644 --- a/include/geom/edge.h +++ b/include/geom/edge.h @@ -237,6 +237,12 @@ class Edge : public Elem virtual unsigned int n_nodes_on_side(const unsigned short libmesh_dbg_var(s)) const override final { libmesh_assert_less(s, 2); return 1; } + /** + * The \p Elem::n_nodes_on_edge() member makes no sense for edges. + */ + virtual unsigned int n_nodes_on_edge(const unsigned short) const override final + { libmesh_not_implemented(); return 0; } + protected: /** diff --git a/include/geom/elem.h b/include/geom/elem.h index 1abcd40fc91..2c991a5a14d 100644 --- a/include/geom/elem.h +++ b/include/geom/elem.h @@ -682,6 +682,11 @@ class Elem : public ReferenceCountedObject, */ virtual unsigned int n_edges () const = 0; + /** + * \returns The number of nodes on the edge with index \p e. + */ + virtual unsigned int n_nodes_on_edge (const unsigned short) const = 0; + /** * \returns An integer range from 0 up to (but not including) * the number of edges this element has. @@ -2028,6 +2033,20 @@ class Elem : public ReferenceCountedObject, return ElemClass::nodes_per_side; } + /** + * Helper for overriding n_nodes_per_edge in derived classes. + * + * Performs bound checking on \p s and returns nodes_per_edge + * for the given class for all edges. + */ + template + unsigned int _n_nodes_on_edge_constant(const unsigned short libmesh_dbg_var(s)) const + { + static_assert(std::is_base_of::value, "Not an Elem"); + libmesh_assert_less(s, this->n_edges()); + return ElemClass::nodes_per_edge; + } + /** * Helper for overriding nodes_on_side in derived classes. */ diff --git a/include/geom/face.h b/include/geom/face.h index 9cd50075690..4e70c9fec8e 100644 --- a/include/geom/face.h +++ b/include/geom/face.h @@ -72,6 +72,9 @@ class Face : public Elem virtual unsigned int n_vertices_on_side(const unsigned short libmesh_dbg_var(s)) const override final { libmesh_assert_less(s, this->n_sides()); return 2; } + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->n_nodes_on_side(e); } + /** * build_side and build_edge are identical for faces. */ diff --git a/include/geom/face_inf_quad.h b/include/geom/face_inf_quad.h index f24aef7164a..e6def39b24d 100644 --- a/include/geom/face_inf_quad.h +++ b/include/geom/face_inf_quad.h @@ -239,6 +239,9 @@ class InfQuad : public Elem virtual void orient(BoundaryInfo *) override final; + virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final + { return this->n_nodes_on_side(e); } + protected: /** diff --git a/include/geom/node_elem.h b/include/geom/node_elem.h index 65ba5027815..5851cb74981 100644 --- a/include/geom/node_elem.h +++ b/include/geom/node_elem.h @@ -83,6 +83,12 @@ class NodeElem : public Elem virtual unsigned int n_nodes_on_side(const unsigned short) const override { libmesh_not_implemented(); return 0; } + /** + * The \p Elem::n_nodes_on_edge makes no sense for nodes. + */ + virtual unsigned int n_nodes_on_edge(const unsigned short) const override + { libmesh_not_implemented(); return 0; } + /** * The \p Elem::nodes_on_side_ptr makes no sense for nodes. */ diff --git a/include/geom/remote_elem.h b/include/geom/remote_elem.h index e4f3fdc87b0..d83f923b270 100644 --- a/include/geom/remote_elem.h +++ b/include/geom/remote_elem.h @@ -122,6 +122,9 @@ class RemoteElem : public Elem, virtual unsigned int n_nodes_on_side (const unsigned short) const override { libmesh_not_implemented(); return 0; } + virtual unsigned int n_nodes_on_edge (const unsigned short) const override + { libmesh_not_implemented(); return 0; } + virtual unsigned int n_sides () const override { libmesh_not_implemented(); return 0; } diff --git a/tests/geom/elem_test.C b/tests/geom/elem_test.C index b310ef6799d..27e025ac84a 100644 --- a/tests/geom/elem_test.C +++ b/tests/geom/elem_test.C @@ -503,6 +503,21 @@ public: } }; + void test_n_nodes_on_edge() + { + LOG_UNIT_TEST; + + for (const auto & elem : _mesh->active_local_element_ptr_range()) + for (const auto e : elem->edge_index_range()) + { + unsigned int n_nodes_on_edge = 0; + for (const auto n : elem->node_index_range()) + if (elem->is_node_on_edge(n, e)) + ++n_nodes_on_edge; + CPPUNIT_ASSERT_EQUAL(n_nodes_on_edge, elem->n_nodes_on_edge(e)); + } + }; + void test_n_vertices_on_side() { LOG_UNIT_TEST; @@ -566,6 +581,7 @@ public: CPPUNIT_TEST( test_center_node_on_side ); \ CPPUNIT_TEST( test_side_type ); \ CPPUNIT_TEST( test_n_nodes_on_side ); \ + CPPUNIT_TEST( test_n_nodes_on_edge ); \ CPPUNIT_TEST( test_n_vertices_on_side ); \ CPPUNIT_TEST( test_nodes_on_side_ptr ); \ CPPUNIT_TEST( test_elem_side_builder ); From c080d7e0856e10e66796157ea97558a645c123dc Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Wed, 9 Nov 2022 13:39:13 -0700 Subject: [PATCH 07/30] Add Elem::nodes_on_edge_ptr --- include/geom/cell_hex20.h | 3 +++ include/geom/cell_hex27.h | 3 +++ include/geom/cell_hex8.h | 3 +++ include/geom/cell_inf_hex16.h | 3 +++ include/geom/cell_inf_hex18.h | 3 +++ include/geom/cell_inf_hex8.h | 3 +++ include/geom/cell_inf_prism12.h | 3 +++ include/geom/cell_inf_prism6.h | 3 +++ include/geom/cell_prism15.h | 3 +++ include/geom/cell_prism18.h | 3 +++ include/geom/cell_prism20.h | 3 +++ include/geom/cell_prism21.h | 3 +++ include/geom/cell_prism6.h | 3 +++ include/geom/cell_pyramid13.h | 3 +++ include/geom/cell_pyramid14.h | 3 +++ include/geom/cell_pyramid5.h | 3 +++ include/geom/cell_tet10.h | 3 +++ include/geom/cell_tet14.h | 3 +++ include/geom/cell_tet4.h | 3 +++ include/geom/edge.h | 3 +++ include/geom/elem.h | 24 ++++++++++++++++++++++-- include/geom/face.h | 3 +++ include/geom/face_inf_quad.h | 3 +++ include/geom/node_elem.h | 6 ++++++ include/geom/remote_elem.h | 3 +++ tests/geom/elem_test.C | 15 +++++++++++++++ 26 files changed, 112 insertions(+), 2 deletions(-) diff --git a/include/geom/cell_hex20.h b/include/geom/cell_hex20.h index b418bdf6856..6fcb53f161f 100644 --- a/include/geom/cell_hex20.h +++ b/include/geom/cell_hex20.h @@ -129,6 +129,9 @@ class Hex20 final : public Hex virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/cell_hex27.h b/include/geom/cell_hex27.h index c83c80de66c..9f1d4c1568f 100644 --- a/include/geom/cell_hex27.h +++ b/include/geom/cell_hex27.h @@ -129,6 +129,9 @@ class Hex27 final : public Hex virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/cell_hex8.h b/include/geom/cell_hex8.h index c87befa2cca..09b5e643f8f 100644 --- a/include/geom/cell_hex8.h +++ b/include/geom/cell_hex8.h @@ -114,6 +114,9 @@ class Hex8 final : public Hex virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/cell_inf_hex16.h b/include/geom/cell_inf_hex16.h index 43651cb4f7a..36d4a302243 100644 --- a/include/geom/cell_inf_hex16.h +++ b/include/geom/cell_inf_hex16.h @@ -129,6 +129,9 @@ class InfHex16 final : public InfHex virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/cell_inf_hex18.h b/include/geom/cell_inf_hex18.h index 721c5890ad9..305fbb37193 100644 --- a/include/geom/cell_inf_hex18.h +++ b/include/geom/cell_inf_hex18.h @@ -134,6 +134,9 @@ class InfHex18 final : public InfHex virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/cell_inf_hex8.h b/include/geom/cell_inf_hex8.h index a3b41c4460a..89bafb6f47e 100644 --- a/include/geom/cell_inf_hex8.h +++ b/include/geom/cell_inf_hex8.h @@ -114,6 +114,9 @@ class InfHex8 final : public InfHex virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/cell_inf_prism12.h b/include/geom/cell_inf_prism12.h index 9ccaf33b956..1c8c2a0b856 100644 --- a/include/geom/cell_inf_prism12.h +++ b/include/geom/cell_inf_prism12.h @@ -120,6 +120,9 @@ class InfPrism12 final : public InfPrism virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/cell_inf_prism6.h b/include/geom/cell_inf_prism6.h index 3c6a72ecc26..b9f6f5121ee 100644 --- a/include/geom/cell_inf_prism6.h +++ b/include/geom/cell_inf_prism6.h @@ -116,6 +116,9 @@ class InfPrism6 final : public InfPrism virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/cell_prism15.h b/include/geom/cell_prism15.h index d579d788da5..42b282105db 100644 --- a/include/geom/cell_prism15.h +++ b/include/geom/cell_prism15.h @@ -134,6 +134,9 @@ class Prism15 final : public Prism virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/cell_prism18.h b/include/geom/cell_prism18.h index 4c3e69d2b09..7759d14a565 100644 --- a/include/geom/cell_prism18.h +++ b/include/geom/cell_prism18.h @@ -134,6 +134,9 @@ class Prism18 final : public Prism virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/cell_prism20.h b/include/geom/cell_prism20.h index 492d262f5af..021b2bdc33a 100644 --- a/include/geom/cell_prism20.h +++ b/include/geom/cell_prism20.h @@ -138,6 +138,9 @@ class Prism20 final : public Prism virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/cell_prism21.h b/include/geom/cell_prism21.h index c2dd6d33430..eac0d9a187e 100644 --- a/include/geom/cell_prism21.h +++ b/include/geom/cell_prism21.h @@ -141,6 +141,9 @@ class Prism21 final : public Prism virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/cell_prism6.h b/include/geom/cell_prism6.h index 97f4ece10ac..0213ef2c343 100644 --- a/include/geom/cell_prism6.h +++ b/include/geom/cell_prism6.h @@ -112,6 +112,9 @@ class Prism6 final : public Prism virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/cell_pyramid13.h b/include/geom/cell_pyramid13.h index e243328d42e..72a7d7e608f 100644 --- a/include/geom/cell_pyramid13.h +++ b/include/geom/cell_pyramid13.h @@ -133,6 +133,9 @@ class Pyramid13 final : public Pyramid virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/cell_pyramid14.h b/include/geom/cell_pyramid14.h index 27002abaa4c..d009e1f1433 100644 --- a/include/geom/cell_pyramid14.h +++ b/include/geom/cell_pyramid14.h @@ -136,6 +136,9 @@ class Pyramid14 final : public Pyramid virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/cell_pyramid5.h b/include/geom/cell_pyramid5.h index d83dae6f9e9..c4a7272143c 100644 --- a/include/geom/cell_pyramid5.h +++ b/include/geom/cell_pyramid5.h @@ -111,6 +111,9 @@ class Pyramid5 final : public Pyramid virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/cell_tet10.h b/include/geom/cell_tet10.h index ae79ba42df1..dbe21e07c2e 100644 --- a/include/geom/cell_tet10.h +++ b/include/geom/cell_tet10.h @@ -123,6 +123,9 @@ class Tet10 final : public Tet virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/cell_tet14.h b/include/geom/cell_tet14.h index 5080743a4d3..2d560170c5c 100644 --- a/include/geom/cell_tet14.h +++ b/include/geom/cell_tet14.h @@ -129,6 +129,9 @@ class Tet14 final : public Tet virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/cell_tet4.h b/include/geom/cell_tet4.h index 08ca940ec02..97b0fc2ee6e 100644 --- a/include/geom/cell_tet4.h +++ b/include/geom/cell_tet4.h @@ -118,6 +118,9 @@ class Tet4 final : public Tet virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return this->_nodes_on_edge_ptr(e); } + /** * \returns \p true if the specified (local) node number is on the * specified edge. diff --git a/include/geom/edge.h b/include/geom/edge.h index 386fb6493f3..6353ec53eed 100644 --- a/include/geom/edge.h +++ b/include/geom/edge.h @@ -201,6 +201,9 @@ class Edge : public Elem virtual std::vector nodes_on_edge(const unsigned int e) const override; + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const override final + { return nodes_on_side_ptr(e); } + virtual std::vector sides_on_edge(const unsigned int) const override final { return {}; } diff --git a/include/geom/elem.h b/include/geom/elem.h index 2c991a5a14d..010287db229 100644 --- a/include/geom/elem.h +++ b/include/geom/elem.h @@ -757,18 +757,27 @@ class Elem : public ReferenceCountedObject, /** * \returns A pointer to the beginning of the array that contains the - * (local) node numbers on the specified side + * (local) node numbers on the side \p s * * This does not create temproraries, unlike \p nodes_on_side. * Use n_nodes_on_side for indexing. */ - virtual const unsigned int * nodes_on_side_ptr(const unsigned short) const = 0; + virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const = 0; /** * \returns the (local) node numbers on the specified edge */ virtual std::vector nodes_on_edge(const unsigned int /*e*/) const = 0; + /** + * \returns A pointer to the beginning of the array that contains the + * (local) node numbers on the edge \p e + * + * This does not create temproraries, unlike \p nodes_on_edge. + * Use n_nodes_on_edge for indexing. + */ + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const = 0; + /** * \returns the (local) side numbers that touch the specified edge */ @@ -2058,6 +2067,17 @@ class Elem : public ReferenceCountedObject, return ElemClass::side_nodes_map[s]; } + /** + * Helper for overriding nodes_on_side in derived classes. + */ + template + const unsigned int * _nodes_on_edge_ptr(const unsigned short s) const + { + static_assert(std::is_base_of::value, "Not an Elem"); + libmesh_assert_less(s, std::extent::value); + return ElemClass::edge_nodes_map[s]; + } + #ifdef LIBMESH_ENABLE_AMR /** diff --git a/include/geom/face.h b/include/geom/face.h index 4e70c9fec8e..3b7176e41ca 100644 --- a/include/geom/face.h +++ b/include/geom/face.h @@ -66,6 +66,9 @@ class Face : public Elem */ virtual unsigned int n_faces() const override final { return 0; } + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short s) const override final + { return nodes_on_side_ptr(s); } + /** * \returns 2. Every side has two vertices. */ diff --git a/include/geom/face_inf_quad.h b/include/geom/face_inf_quad.h index e6def39b24d..022ba8da8c5 100644 --- a/include/geom/face_inf_quad.h +++ b/include/geom/face_inf_quad.h @@ -242,6 +242,9 @@ class InfQuad : public Elem virtual unsigned int n_nodes_on_edge(const unsigned short e) const override final { return this->n_nodes_on_side(e); } + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short s) const override final + { return nodes_on_side_ptr(s); } + protected: /** diff --git a/include/geom/node_elem.h b/include/geom/node_elem.h index 5851cb74981..7bd02dac186 100644 --- a/include/geom/node_elem.h +++ b/include/geom/node_elem.h @@ -95,6 +95,12 @@ class NodeElem : public Elem virtual const unsigned int * nodes_on_side_ptr(const unsigned short) const override final { libmesh_not_implemented(); return nullptr; } + /** + * The \p Elem::nodes_on_edge_ptr makes no sense for nodes. + */ + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short) const override final + { libmesh_not_implemented(); return nullptr; } + /** * \returns 0. */ diff --git a/include/geom/remote_elem.h b/include/geom/remote_elem.h index d83f923b270..7e2f8066946 100644 --- a/include/geom/remote_elem.h +++ b/include/geom/remote_elem.h @@ -171,6 +171,9 @@ class RemoteElem : public Elem, return {0}; } + virtual const unsigned int * nodes_on_edge_ptr(const unsigned short) const override + { libmesh_not_implemented(); return nullptr; } + virtual std::vector sides_on_edge(const unsigned int) const override { libmesh_not_implemented(); diff --git a/tests/geom/elem_test.C b/tests/geom/elem_test.C index 27e025ac84a..a4a20200004 100644 --- a/tests/geom/elem_test.C +++ b/tests/geom/elem_test.C @@ -547,6 +547,20 @@ public: } }; + void test_nodes_on_edge_ptr() + { + LOG_UNIT_TEST; + + for (const auto & elem : _mesh->active_local_element_ptr_range()) + for (const auto s : elem->side_index_range()) + { + const auto nodes_on_edge = elem->nodes_on_edge(s); + const auto nodes_on_edge_ptr = elem->nodes_on_edge_ptr(s); + for (const auto i : index_range(nodes_on_edge)) + CPPUNIT_ASSERT_EQUAL(nodes_on_edge_ptr[i], nodes_on_edge_ptr[i]); + } + }; + void test_elem_side_builder() { LOG_UNIT_TEST; @@ -584,6 +598,7 @@ public: CPPUNIT_TEST( test_n_nodes_on_edge ); \ CPPUNIT_TEST( test_n_vertices_on_side ); \ CPPUNIT_TEST( test_nodes_on_side_ptr ); \ + CPPUNIT_TEST( test_nodes_on_edge_ptr ); \ CPPUNIT_TEST( test_elem_side_builder ); #define INSTANTIATE_ELEMTEST(elemtype) \ From c58be1e461f4dde3355c11adf039e491fe641534 Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Mon, 14 Nov 2022 07:54:44 -0700 Subject: [PATCH 08/30] Add ElemCorner --- include/geom/elem.h | 19 ++-- include/geom/elem_corner.h | 188 ++++++++++++++++++++++++++++++++++ src/geom/elem.C | 3 - src/geom/elem_corner.C | 89 ++++++++++++++++ tests/geom/elem_corner_test.C | 113 ++++++++++++++++++++ 5 files changed, 397 insertions(+), 15 deletions(-) create mode 100644 include/geom/elem_corner.h create mode 100644 src/geom/elem_corner.C create mode 100644 tests/geom/elem_corner_test.C diff --git a/include/geom/elem.h b/include/geom/elem.h index 010287db229..08de4a52dbe 100644 --- a/include/geom/elem.h +++ b/include/geom/elem.h @@ -39,7 +39,7 @@ #include #include #include -#include // CHAR_BIT +#include // CHAR_BIT, std::numeric_limits #include #include #include @@ -224,18 +224,13 @@ class Elem : public ReferenceCountedObject, /** * A static integral constant representing an invalid subdomain id. * See also DofObject::{invalid_id, invalid_unique_id, invalid_processor_id}. - * - * \note We don't use the static_cast(-1) trick here since - * \p subdomain_id_type is sometimes a *signed* integer for - * compatibility reasons (see libmesh/id_types.h). - * - * \note Normally you can declare static const integral types - * directly in the header file (C++ standard, 9.4.2/4) but - * std::numeric_limits::max() is not considered a "constant - * expression". This one is therefore defined in elem.C. - * http://stackoverflow.com/questions/2738435/using-numeric-limitsmax-in-constant-expressions */ - static const subdomain_id_type invalid_subdomain_id; + static constexpr subdomain_id_type invalid_subdomain_id = std::numeric_limits::max(); + + /** + * A static integral constant representing an invalid index to a vertex. + */ + static constexpr unsigned short invalid_vertex = std::numeric_limits::max(); /** * \returns A pointer to the "reference element" associated diff --git a/include/geom/elem_corner.h b/include/geom/elem_corner.h new file mode 100644 index 00000000000..07a83e3e9ed --- /dev/null +++ b/include/geom/elem_corner.h @@ -0,0 +1,188 @@ +// The libMesh Finite Element Library. +// Copyright (C) 2002-2022 Benjamin S. Kirk, John W. Peterson, Roy H. Stogner + +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License, or (at your option) any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. + +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + + +#ifndef LIBMESH_ELEMCORNER_H +#define LIBMESH_ELEMCORNER_H + +#include "libmesh/libmesh_common.h" + +#if LIBMESH_DIM > 1 + +#include "libmesh/elem.h" + +#include // std::pair + +namespace libMesh +{ + +/** + * The \p ElemCorner is a helper class for defining whether or not + * _something_ is at an element vertex or edge. In this context, + * we define corner as a vertex in 2D and as a vertex or an edge + * in 3D. + * + * This class is typically used in intersection algorithms, in which + * it should be interfaced with by using the \p at_corner(), + * \p at_edge(), and \p at_vertex() methods. + * + * Internally, it keeps track of whether or not at one of these + * "corners" by storing a set of indicies that denote vertex indices. + * If the first is valid and the second is not, it implies + * being at the vertex with said index. If both are valid, it implies + * being at the edge defined by the verticies with said indices. + */ +class ElemCorner : public std::pair +{ +public: + /** + * Default constructor: sets entires to invalid (not at vertex or edge) + */ + ElemCorner() + : std::pair(Elem::invalid_vertex, + Elem::invalid_vertex) { } + + /** + * Constructor with given vertex indices \p v1 and \p v2. + */ + ElemCorner(const unsigned short v1, const unsigned short v2) + : std::pair(v1, v2) { } + + /** + * @returns true if at the corner (edge or vertex) + */ + bool at_corner() const { return first != Elem::invalid_vertex; } + + /** + * @returns true if the vertex index data is invalid + */ + bool is_invalid() const + { return first == Elem::invalid_vertex && second == Elem::invalid_vertex; } + + /** + * @returns true if at a vertex + */ + bool at_vertex() const + { return first != Elem::invalid_vertex && second == Elem::invalid_vertex; } + /** + * @returns true if at vertex \p v + */ + bool at_vertex(const unsigned short v) const + { return first == v && second == Elem::invalid_vertex; } + + /** + * Invalidates the current state + */ + void invalidate() + { + first = Elem::invalid_vertex; + second = Elem::invalid_vertex; + } + + /** + * @returns The vertex ID when at a vertex + */ + unsigned short vertex() const + { libmesh_assert(at_vertex()); return first; } + + /** + * Prints the current state (at edge, at vertex, not at either) + */ + std::string print() const; + + /** + * Sets the "at vertex" state + */ + void set_vertex(const unsigned short v) + { + libmesh_assert_not_equal_to(v, Elem::invalid_vertex); + first = v; + second = Elem::invalid_vertex; + } + +#if LIBMESH_DIM > 2 + /** + * @returns true if at an edge + */ + bool at_edge() const + { return first != Elem::invalid_vertex && second != Elem::invalid_vertex; } + /** + * @returns true if at the edge defined by vertices \p v1 and \p v2 + */ + bool at_edge(const unsigned short v1, const unsigned short v2) const + { + libmesh_assert_not_equal_to(v1, Elem::invalid_vertex); + libmesh_assert_not_equal_to(v2, Elem::invalid_vertex); + return (first == v1 && second == v2) || (first == v2 && second == v1); + } + /** + * @returns true if at the edge with index \p e on element \p + */ + bool at_edge(const Elem & elem, const unsigned short e) const; + + /** + * @returns The vertices that contain the edge when at an edge + */ + const std::pair & edge_vertices() const + { libmesh_assert(at_edge()); return *this; } + + /** + * Sets the "at edge" state + */ + void set_edge(const unsigned short v1, const unsigned short v2) + { + libmesh_assert_not_equal_to(v1, Elem::invalid_vertex); + libmesh_assert_not_equal_to(v2, Elem::invalid_vertex); + first = v1; + second = v2; + } + /** + * Sets the "at edge" state + */ + void set_edge(const std::pair & vs) + { set_edge(vs.first, vs.second); } + + /** + * @returns The edge when at an edge + */ + std::unique_ptr build_edge(const Elem & elem) const; +#endif + + /** + * @returns The vertex point when at a vertex + */ + const Point & vertex_point(const Elem & elem) const + { return elem.point(vertex()); } + + /** + * @returns Whether or not the current state (at vertex/edge) is valid + * for the given \p elem and \p point. \p tol is used as the tolerance + * to pass to the equality checks. + * + * This ONLY checks for validity when at_corner(). + */ + bool is_valid(const Elem & elem, const Point & point, const Real tol = TOLERANCE) const; +}; + +} // namespace libMesh + +std::ostream & operator<<(std::ostream & os, const libMesh::ElemCorner & elem_corner); + +#endif // LIBMESH_DIM > 1 + +#endif // LIBMESH_ELEMCORNER_H diff --git a/src/geom/elem.C b/src/geom/elem.C index bec33a4a2ee..efad9187086 100644 --- a/src/geom/elem.C +++ b/src/geom/elem.C @@ -82,7 +82,6 @@ #include #include // for std::ostream_iterator #include -#include // for std::numeric_limits<> #include // for std::sqrt() #include @@ -93,8 +92,6 @@ namespace libMesh Threads::spin_mutex parent_indices_mutex; Threads::spin_mutex parent_bracketing_nodes_mutex; -const subdomain_id_type Elem::invalid_subdomain_id = std::numeric_limits::max(); - // Initialize static member variables const unsigned int Elem::max_n_nodes; diff --git a/src/geom/elem_corner.C b/src/geom/elem_corner.C new file mode 100644 index 00000000000..f9affc02da1 --- /dev/null +++ b/src/geom/elem_corner.C @@ -0,0 +1,89 @@ +// The libMesh Finite Element Library. +// Copyright (C) 2002-2022 Benjamin S. Kirk, John W. Peterson, Roy H. Stogner + +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License, or (at your option) any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. + +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + +// Local includes +#include "libmesh/elem_corner.h" + +#if LIBMESH_DIM > 1 + +namespace libMesh +{ + +#if LIBMESH_DIM > 2 +bool ElemCorner::at_edge(const Elem & elem, const unsigned short e) const +{ + libmesh_assert_less(e, elem.n_edges()); + if (!at_edge()) + return false; + const unsigned int * nodes_on_edge_ptr = elem.nodes_on_edge_ptr(e); + return at_edge(nodes_on_edge_ptr[0], nodes_on_edge_ptr[1]); +} + +std::unique_ptr ElemCorner::build_edge(const Elem & elem) const +{ + libmesh_assert(at_edge()); + libmesh_assert_less(first, elem.n_vertices()); + libmesh_assert_less(second, elem.n_vertices()); + + for (const auto e : elem.edge_index_range()) + if (elem.is_node_on_edge(first, e) && elem.is_node_on_edge(second, e)) + return elem.build_edge_ptr(e); + + libmesh_error_msg("Element does not contain vertices in ElemCorner"); +} +#endif + +std::string ElemCorner::print() const +{ + std::stringstream oss; + if (at_vertex()) + oss << "at vertex " << vertex(); +#if LIBMESH_DIM > 2 + else if (at_edge()) + oss << "at edge with vertices " << first << " and " << second; +#endif + else + oss << "not at corner"; + return oss.str(); +} + +bool ElemCorner::is_valid(const Elem & elem, const Point & point, const Real tol) const +{ + libmesh_assert(first == Elem::invalid_vertex || first < elem.n_vertices()); + libmesh_assert(second == Elem::invalid_vertex || second < elem.n_vertices()); + + if (at_vertex()) + return vertex_point(elem).absolute_fuzzy_equals(point, tol); +#if LIBMESH_DIM > 2 + if (elem.dim() == 3 && at_edge()) + return build_edge(elem)->contains_point(point, tol); +#endif + + return true; +} + +} // namespace libMesh + +std::ostream & +operator<<(std::ostream & os, const libMesh::ElemCorner & elem_corner) +{ + os << elem_corner.print(); + return os; +} + +#endif // LIBMESH_DIM > 1 diff --git a/tests/geom/elem_corner_test.C b/tests/geom/elem_corner_test.C new file mode 100644 index 00000000000..6e9690486f1 --- /dev/null +++ b/tests/geom/elem_corner_test.C @@ -0,0 +1,113 @@ +#include +#include +#include + +#include "test_comm.h" + +#include "libmesh_cppunit.h" + +using namespace libMesh; + +#if LIBMESH_DIM > 1 +class ElemCornerTest : public CppUnit::TestCase +{ + +public: + LIBMESH_CPPUNIT_TEST_SUITE( ElemCornerTest ); + CPPUNIT_TEST( test ); + CPPUNIT_TEST_SUITE_END(); + +public: + + void test() + { + LOG_UNIT_TEST; + + // QUAD elem for vertex testing + Mesh mesh_2d (*TestCommWorld); + MeshTools::Generation::build_square (mesh_2d, 1, 1); + const auto & quad = mesh_2d.elem_ref(0); + + // Default constructor: unvalid state + const ElemCorner default_corner; + CPPUNIT_ASSERT(default_corner.is_invalid()); + CPPUNIT_ASSERT(!default_corner.at_corner()); + CPPUNIT_ASSERT(!default_corner.at_vertex()); +#if LIBMESH_DIM > 2 + CPPUNIT_ASSERT(!default_corner.at_edge()); +#endif // LIBMESH_DIM > 2 + CPPUNIT_ASSERT_EQUAL((std::string)"not at corner", default_corner.print()); + CPPUNIT_ASSERT(default_corner.is_valid(quad, quad.point(0))); + + // At vertex + const ElemCorner at_vertex(0, Elem::invalid_vertex); + CPPUNIT_ASSERT(!at_vertex.is_invalid()); + CPPUNIT_ASSERT(at_vertex.at_corner()); + CPPUNIT_ASSERT(at_vertex.at_vertex()); +#if LIBMESH_DIM> 2 + CPPUNIT_ASSERT(!at_vertex.at_edge()); + CPPUNIT_ASSERT(!at_vertex.at_edge(0, 1)); + CPPUNIT_ASSERT(!at_vertex.at_edge(quad, 0)); +#endif // LIBMESH_DIM > 2 + CPPUNIT_ASSERT(at_vertex.at_vertex(0)); + CPPUNIT_ASSERT(!at_vertex.at_vertex(1)); + CPPUNIT_ASSERT_EQUAL(at_vertex.vertex(), (unsigned short)0); + CPPUNIT_ASSERT(at_vertex.is_valid(quad, quad.point(0))); + CPPUNIT_ASSERT(!at_vertex.is_valid(quad, quad.point(2))); + +#if LIBMESH_DIM > 2 + // HEX elem for edge testing + Mesh mesh_3d (*TestCommWorld); + MeshTools::Generation::build_cube (mesh_3d, 1, 1, 1); + const auto & hex = mesh_3d.elem_ref(0); + + // At edge + const ElemCorner at_edge(0, 1); + CPPUNIT_ASSERT(!at_edge.is_invalid()); + CPPUNIT_ASSERT(at_edge.at_corner()); + CPPUNIT_ASSERT(!at_edge.at_vertex()); + CPPUNIT_ASSERT(!at_edge.at_vertex(0)); + CPPUNIT_ASSERT(at_edge.at_edge()); + CPPUNIT_ASSERT(at_edge.at_edge(0, 1)); + CPPUNIT_ASSERT(at_edge.at_edge(1, 0)); + CPPUNIT_ASSERT(at_edge.at_edge(hex, 0)); + CPPUNIT_ASSERT_EQUAL(at_edge.edge_vertices().first, (unsigned short)0); + CPPUNIT_ASSERT_EQUAL(at_edge.edge_vertices().second, (unsigned short)1); + CPPUNIT_ASSERT(!at_edge.is_invalid()); + CPPUNIT_ASSERT(at_edge.is_valid(hex, (hex.point(0) + hex.point(1)) * 0.5)); + CPPUNIT_ASSERT(at_edge.is_valid(hex, hex.point(0))); + CPPUNIT_ASSERT(at_edge.is_valid(hex, hex.point(1))); + CPPUNIT_ASSERT(!at_edge.is_valid(hex, (hex.point(2)) * 0.5)); + + // build_edge + auto edge_elem = at_edge.build_edge(hex); + CPPUNIT_ASSERT((edge_elem->point(0).absolute_fuzzy_equals(hex.point(0)) + && edge_elem->point(1).absolute_fuzzy_equals(hex.point(1))) || + ((edge_elem->point(1).absolute_fuzzy_equals(hex.point(0)) + && edge_elem->point(0).absolute_fuzzy_equals(hex.point(1))))); +#endif // LIBMESH_DIM > 2 + + // For testing non-const methods + ElemCorner corner(0, 0); + + // invalidate + corner.invalidate(); + CPPUNIT_ASSERT(corner.is_invalid()); + + // set_vertex + corner.set_vertex(0); + CPPUNIT_ASSERT(corner.at_vertex(0)); + + // set_edge +#if LIBMESH_DIM > 2 + corner.set_edge(0, 1); + CPPUNIT_ASSERT(corner.at_edge(0, 1)); + corner.set_edge(std::pair(1, 2)); + CPPUNIT_ASSERT(corner.at_edge(1, 2)); +#endif // LIBMESH_DIM > 2 + } + +}; +#endif // LIBMESH_DIM > 1 + +CPPUNIT_TEST_SUITE_REGISTRATION( ElemCornerTest ); From ff7e024c6cfc24de88295f502bd5539a5d02f31a Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Mon, 14 Nov 2022 07:56:18 -0700 Subject: [PATCH 09/30] Add IntersectionTools and within_segment --- include/geom/intersection_tools.h | 75 ++++++++++++++++++++++++++++ src/geom/intersection_tools.C | 67 +++++++++++++++++++++++++ tests/geom/intersection_tools_test.C | 52 +++++++++++++++++++ 3 files changed, 194 insertions(+) create mode 100644 include/geom/intersection_tools.h create mode 100644 src/geom/intersection_tools.C create mode 100644 tests/geom/intersection_tools_test.C diff --git a/include/geom/intersection_tools.h b/include/geom/intersection_tools.h new file mode 100644 index 00000000000..46df9828bec --- /dev/null +++ b/include/geom/intersection_tools.h @@ -0,0 +1,75 @@ +// The libMesh Finite Element Library. +// Copyright (C) 2002-2022 Benjamin S. Kirk, John W. Peterson, Roy H. Stogner + +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License, or (at your option) any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. + +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + + +#ifndef LIBMESH_INTERSECTIONTOOLS_H +#define LIBMESH_INTERSECTIONTOOLS_H + +#include "libmesh/libmesh_common.h" + +namespace libMesh +{ + +class Point; + +namespace IntersectionTools +{ + +/** + * Enum that represents the result of the \p within_segment() methods. +*/ +enum WithinSegmentResult : int { + NOT_WITHIN = 0, + AT_BEGINNING = 1, + AT_END = 2, + BETWEEN = 3 }; + +/** + * Checks whether or not a point is within a line segment + * @param s1 The first point on the segment + * @param s2 The second point on the segment + * @param length The segment length (for optimization if it's already computed) + * @param p The point + * @param tol The tolerance to use + * @return Enum denoting whether or not the point is not within, at s1, + * at s2, or between [s1, s2] + */ +WithinSegmentResult within_segment(const Point & s1, + const Point & s2, + const Real length, + const Point & p, + const Real tol = TOLERANCE); + +/** + * Checks whether or not a point is within a line segment + * @param s1 The first point on the segment + * @param s2 The second point on the segment + * @param p The point + * @param tol The tolerance to use + * @return Enum denoting whether or not the point is not within, at s1, + * at s2, or between [s1, s2] + */ +WithinSegmentResult within_segment(const Point & s1, + const Point & s2, + const Point & p, + const Real tol = TOLERANCE); + +} // namespace IntersectionTools +} // namespace libMesh + +#endif // LIBMESH_INTERSECTIONTOOLS_H diff --git a/src/geom/intersection_tools.C b/src/geom/intersection_tools.C new file mode 100644 index 00000000000..cb8bcb886a2 --- /dev/null +++ b/src/geom/intersection_tools.C @@ -0,0 +1,67 @@ +// The libMesh Finite Element Library. +// Copyright (C) 2002-2022 Benjamin S. Kirk, John W. Peterson, Roy H. Stogner + +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License, or (at your option) any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. + +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + + +#include "libmesh/intersection_tools.h" + +#include "libmesh/point.h" + +namespace libMesh::IntersectionTools +{ + +WithinSegmentResult within_segment(const Point & s1, + const Point & s2, + const Real length, + const Point & p, + const Real tol) +{ + libmesh_assert(!s1.absolute_fuzzy_equals(s2, tol)); + libmesh_assert_less(std::abs((s1 - s2).norm() - length), tol); + + const auto diff1 = p - s1; + const auto diff2 = p - s2; + const auto tol_scaled = tol * length; + + if (diff1 * diff2 > tol_scaled) + return NOT_WITHIN; + + const auto diff1_norm = diff1.norm(); + if (diff1_norm < tol_scaled) + return AT_BEGINNING; + + const auto diff2_norm = diff2.norm(); + if (diff2_norm < tol_scaled) + return AT_END; + + // whether or not p is _between_ [s1, s2] + if (std::abs(diff1_norm + diff2_norm - length) < tol_scaled) + return BETWEEN; + return NOT_WITHIN; +} + +WithinSegmentResult within_segment(const Point & s1, + const Point & s2, + const Point & p, + const Real tol) +{ + return within_segment(s1, s2, (s1 - s2).norm(), p, tol); +} + +} // namespace libMesh::IntersectionTools + + diff --git a/tests/geom/intersection_tools_test.C b/tests/geom/intersection_tools_test.C new file mode 100644 index 00000000000..6246a7130bb --- /dev/null +++ b/tests/geom/intersection_tools_test.C @@ -0,0 +1,52 @@ +#include "libmesh_cppunit.h" + +#include +#include +#include + +using namespace libMesh; + +class IntersectionToolsTest : public CppUnit::TestCase +{ + +public: + LIBMESH_CPPUNIT_TEST_SUITE( IntersectionToolsTest ); + CPPUNIT_TEST( within_segment ); + CPPUNIT_TEST_SUITE_END(); + +public: + + void within_segment() + { + LOG_UNIT_TEST; + + const Point s1(1.0, 2.0, 3.0); + const Point s2(2.0, 3.0, 4.0); + const auto length_vec = s2 - s1; + const auto length = length_vec.norm(); + const auto s1_to_s2 = length_vec / length; + + int segments = 10; + Real dx = (Real)1 / segments * length; + for (const auto i : make_range(-1, segments + 1)) + { + const auto p = s1 + Real(i) * dx * s1_to_s2; + IntersectionTools::WithinSegmentResult within_result = IntersectionTools::WithinSegmentResult::NOT_WITHIN; + if (i == 0) + within_result = IntersectionTools::WithinSegmentResult::AT_BEGINNING; + else if (i > 0 && i < segments) + within_result = IntersectionTools::WithinSegmentResult::BETWEEN; + else if (i == segments) + within_result = IntersectionTools::WithinSegmentResult::AT_END; + + CPPUNIT_ASSERT_EQUAL(IntersectionTools::within_segment(s1, s2, length, p), within_result); + CPPUNIT_ASSERT_EQUAL(IntersectionTools::within_segment(s1, s2, p), within_result); + } + + CPPUNIT_ASSERT_EQUAL(IntersectionTools::within_segment(s1, s2, Point(9.9, 5, 3)), + IntersectionTools::WithinSegmentResult::NOT_WITHIN); + } + +}; + +CPPUNIT_TEST_SUITE_REGISTRATION( IntersectionToolsTest ); From 4887954c9a8996cfef1624b31c41d8fddb59cdfa Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Wed, 9 Nov 2022 15:22:02 -0700 Subject: [PATCH 10/30] Add IntersectionTools::collinear --- include/geom/intersection_tools.h | 13 ++++++++++++ src/geom/intersection_tools.C | 14 +++++++++++++ tests/geom/intersection_tools_test.C | 30 ++++++++++++++++++++++++++++ 3 files changed, 57 insertions(+) diff --git a/include/geom/intersection_tools.h b/include/geom/intersection_tools.h index 46df9828bec..f14be59f543 100644 --- a/include/geom/intersection_tools.h +++ b/include/geom/intersection_tools.h @@ -69,6 +69,19 @@ WithinSegmentResult within_segment(const Point & s1, const Point & p, const Real tol = TOLERANCE); +/** + * Checks whether or not the given points are collinear + * @param p1 The first point + * @param p2 The second point + * @param p3 The third point + * @param tol The tolerance to use + * @return Whether or not the given points are collinear + */ +bool collinear(const Point & p1, + const Point & p2, + const Point & p3, + const Real tol = TOLERANCE); + } // namespace IntersectionTools } // namespace libMesh diff --git a/src/geom/intersection_tools.C b/src/geom/intersection_tools.C index cb8bcb886a2..8beda8ee5e9 100644 --- a/src/geom/intersection_tools.C +++ b/src/geom/intersection_tools.C @@ -20,6 +20,7 @@ #include "libmesh/intersection_tools.h" #include "libmesh/point.h" +#include "libmesh/int_range.h" namespace libMesh::IntersectionTools { @@ -62,6 +63,19 @@ WithinSegmentResult within_segment(const Point & s1, return within_segment(s1, s2, (s1 - s2).norm(), p, tol); } +bool collinear(const Point & p1, + const Point & p2, + const Point & p3, + const Real tol) +{ + // (p1 -> p2) X (p1 - > p3) should be == the zero vector + const auto p1p2_cross_p1p3 = (p2 - p1).cross(p3 - p1); + for (const auto i : make_range(LIBMESH_DIM)) + if (std::abs(p1p2_cross_p1p3(i)) > tol) + return false; + return true; +} + } // namespace libMesh::IntersectionTools diff --git a/tests/geom/intersection_tools_test.C b/tests/geom/intersection_tools_test.C index 6246a7130bb..d03836b9b6b 100644 --- a/tests/geom/intersection_tools_test.C +++ b/tests/geom/intersection_tools_test.C @@ -12,6 +12,7 @@ class IntersectionToolsTest : public CppUnit::TestCase public: LIBMESH_CPPUNIT_TEST_SUITE( IntersectionToolsTest ); CPPUNIT_TEST( within_segment ); + CPPUNIT_TEST( collinear ); CPPUNIT_TEST_SUITE_END(); public: @@ -47,6 +48,35 @@ public: IntersectionTools::WithinSegmentResult::NOT_WITHIN); } + void collinear() + { + LOG_UNIT_TEST; + + const auto do_assert = [](const Point & p1, + const Point & p2, + const Point & p3, + const bool collinear) + { + CPPUNIT_ASSERT_EQUAL(IntersectionTools::collinear(p1, p2, p3), collinear); + CPPUNIT_ASSERT_EQUAL(IntersectionTools::collinear(p1, p3, p2), collinear); + CPPUNIT_ASSERT_EQUAL(IntersectionTools::collinear(p2, p1, p3), collinear); + CPPUNIT_ASSERT_EQUAL(IntersectionTools::collinear(p2, p3, p1), collinear); + CPPUNIT_ASSERT_EQUAL(IntersectionTools::collinear(p3, p1, p2), collinear); + CPPUNIT_ASSERT_EQUAL(IntersectionTools::collinear(p3, p2, p1), collinear); + }; + + // two of the same points + do_assert(Point(1, 2, 3), Point(1, 2, 3), Point(4, 5, 6), true); + + // three of the same points + do_assert(Point(1, 2, 3), Point(1, 2, 3), Point(1, 2, 3), true); + + // all in a line + do_assert(Point(1, 1, 2), Point(1, 1, 3), Point(1, 1, 0), true); + + // not collinear + do_assert(Point(0, 1, 2), Point(0, 1, 3), Point(1, 5, 10), false); + } }; CPPUNIT_TEST_SUITE_REGISTRATION( IntersectionToolsTest ); From 1dad25af3e35a0598951c6fcca73d215421f21eb Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Thu, 10 Nov 2022 10:33:58 -0700 Subject: [PATCH 11/30] Add IntersectionTools::within_edge_on_side --- include/geom/intersection_tools.h | 27 +++++ src/geom/intersection_tools.C | 67 ++++++++++++ tests/geom/intersection_tools_test.C | 150 +++++++++++++++++++++++++++ 3 files changed, 244 insertions(+) diff --git a/include/geom/intersection_tools.h b/include/geom/intersection_tools.h index f14be59f543..3a062280b64 100644 --- a/include/geom/intersection_tools.h +++ b/include/geom/intersection_tools.h @@ -25,6 +25,8 @@ namespace libMesh { +class Elem; +class ElemCorner; class Point; namespace IntersectionTools @@ -82,6 +84,31 @@ bool collinear(const Point & p1, const Point & p3, const Real tol = TOLERANCE); +/** + * \returns True if the given point is contained within an edge + * on the given side of an element + * @param elem The element + * @param p The point + * @param s The side + * @param corner To be filled with the edge/vertex that the point + * is within/at or, if any (must be initially invalid) + * @param linearize Whether or not to "linearize" the check, if this + * is set to false and edges are found to not be collinear, an error + * is thrown + * + * \p corner will be set to an "at vertex" state if the point is + * both within the edge _and_ at a vertex. + * + * This method is only implemented for three-dimensional, finite + * elements. +*/ +bool within_edge_on_side(const Elem & elem, + const Point & p, + const unsigned short s, + ElemCorner & corner, + const bool linearize = false, + const Real tol = TOLERANCE); + } // namespace IntersectionTools } // namespace libMesh diff --git a/src/geom/intersection_tools.C b/src/geom/intersection_tools.C index 8beda8ee5e9..94a3dc31db9 100644 --- a/src/geom/intersection_tools.C +++ b/src/geom/intersection_tools.C @@ -21,6 +21,8 @@ #include "libmesh/point.h" #include "libmesh/int_range.h" +#include "libmesh/elem.h" +#include "libmesh/elem_corner.h" namespace libMesh::IntersectionTools { @@ -76,6 +78,71 @@ bool collinear(const Point & p1, return true; } +bool within_edge_on_side(const Elem & elem, + const Point & p, + const unsigned short s, + ElemCorner & corner, + const bool linearize, + const Real tol) +{ + libmesh_assert_less(s, elem.n_sides()); + libmesh_assert(corner.is_invalid()); + libmesh_assert_equal_to(elem.dim(), 3); + + // For higher order than linear without linearization, make sure + // that our edges are collinear + if (elem.default_order() > 1 && !linearize) + for (const auto e : elem.edge_index_range()) + { + // we should expect 3 edges for our higher order elems + libmesh_assert_equal_to(elem.n_nodes_on_edge(e), 3); + + const unsigned int * edge_nodes_map = elem.nodes_on_edge_ptr(e); + if (!collinear(elem.point(edge_nodes_map[0]), + elem.point(edge_nodes_map[1]), + elem.point(edge_nodes_map[2]))) + libmesh_error_msg("Failed to use Cell::without_edge_on_side without linearization " + "because an edge was found that is not collinear."); + } + + const auto vs = elem.n_vertices_on_side(s); + const unsigned int * side_nodes_map = elem.nodes_on_side_ptr(s); + + // side_nodes_map will point to something like [v0, v1, v2, v3] + // With the loop below, we're going to check (in this order): + // [v3 -> v0], [v0 -> v1], [v1 -> v2], [v2 -> v3] + auto last_v = side_nodes_map[vs - 1]; + for (const auto side_v : make_range(vs)) + { + const auto other_v = side_nodes_map[side_v]; + const auto within_result = within_segment(elem.point(last_v), elem.point(other_v), p, tol); + if (within_result == NOT_WITHIN) + { + last_v = side_nodes_map[side_v]; + continue; + } + + if (within_result == BETWEEN) + { + corner.set_edge(last_v, other_v); + libmesh_assert(corner.build_edge(elem)->close_to_point(p, tol)); + } + else if (within_result == AT_BEGINNING) + { + corner.set_vertex(last_v); + libmesh_assert(elem.point(last_v).absolute_fuzzy_equals(p, tol)); + } + else + { + corner.set_vertex(other_v); + libmesh_assert(elem.point(other_v).absolute_fuzzy_equals(p, tol)); + } + return true; + } + + return false; +} + } // namespace libMesh::IntersectionTools diff --git a/tests/geom/intersection_tools_test.C b/tests/geom/intersection_tools_test.C index d03836b9b6b..5f4635403db 100644 --- a/tests/geom/intersection_tools_test.C +++ b/tests/geom/intersection_tools_test.C @@ -1,8 +1,15 @@ #include "libmesh_cppunit.h" +#include "test_comm.h" + #include #include #include +#include +#include +#include +#include +#include using namespace libMesh; @@ -80,3 +87,146 @@ public: }; CPPUNIT_TEST_SUITE_REGISTRATION( IntersectionToolsTest ); + +template +class MeshedIntersectionToolsTest : public CppUnit::TestCase { + +private: + std::unique_ptr _mesh; + +protected: + std::string libmesh_suite_name; + +public: + void setUp() + { + const Real minpos = 1.5, maxpos = 4.86; + const unsigned int N = 3; + + _mesh = std::make_unique(*TestCommWorld); + auto test_elem = Elem::build(elem_type); + + const unsigned int dim = test_elem->dim(); + const unsigned int use_y = dim > 1; + const unsigned int use_z = dim > 2; + + MeshTools::Generation::build_cube (*_mesh, + N, N*use_y, N*use_z, + minpos, maxpos, + minpos, use_y*maxpos, + minpos, use_z*maxpos, + elem_type); + } + + void test_within_edge_on_side() + { + LOG_UNIT_TEST; + + if (_mesh->mesh_dimension() != 3) + return; + + // check locations at every node + for (const auto & elem : _mesh->active_local_element_ptr_range()) + for (const auto s : elem->side_index_range()) + for (const auto e : elem->edge_index_range()) + for (const auto n : elem->nodes_on_edge(e)) + { + ElemCorner corner; + const auto within = IntersectionTools::within_edge_on_side(*elem, + elem->point(n), + s, + corner); + + CPPUNIT_ASSERT_EQUAL(within, elem->is_node_on_side(n, s)); + if (elem->is_node_on_side(n, s)) + { + CPPUNIT_ASSERT_EQUAL(elem->is_vertex(n), corner.at_vertex(n)); + CPPUNIT_ASSERT_EQUAL(elem->is_vertex(n), !corner.at_edge(*elem, e)); + } + } + + // cut edges into segments + for (const auto & elem : _mesh->active_local_element_ptr_range()) + for (const auto e : elem->edge_index_range()) + for (const auto s : elem->side_index_range()) + if (elem->is_edge_on_side(e, s)) + { + const auto nodes_on_edge = elem->nodes_on_edge(e); + const auto & p1 = elem->point(nodes_on_edge[0]); + const auto & p2 = elem->point(nodes_on_edge[1]); + const auto length_vec = p2 - p1; + const auto length = length_vec.norm(); + const auto p1_to_p2 = length_vec / length; + + int segments = 5; + Real dx = (Real)1 / segments * length; + for (const auto i : make_range(-1, segments + 1)) + { + const auto p = p1 + Real(i) * dx * p1_to_p2; + ElemCorner corner; + const auto within = IntersectionTools::within_edge_on_side(*elem, + p, + s, + corner); + + CPPUNIT_ASSERT_EQUAL(within, i >= 0 && i <= segments); + CPPUNIT_ASSERT_EQUAL(corner.at_vertex(nodes_on_edge[0]), i == 0); + CPPUNIT_ASSERT_EQUAL(corner.at_vertex(nodes_on_edge[1]), i == segments); + CPPUNIT_ASSERT_EQUAL(corner.at_edge(*elem, e), i > 0 && i < segments); + } + } + + // check elem centroids + for (const auto & elem : _mesh->active_local_element_ptr_range()) + for (const auto s : elem->side_index_range()) + { + ElemCorner corner; + CPPUNIT_ASSERT(!IntersectionTools::within_edge_on_side(*elem, + elem->vertex_average(), + s, + corner)); + } + } + +}; + +#define MESHEDINTERSECTIONTOOLSTEST \ + CPPUNIT_TEST( test_within_edge_on_side ); + +#define INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(elemtype) \ + class MeshedIntersectionToolsTest_##elemtype : public MeshedIntersectionToolsTest { \ + public: \ + MeshedIntersectionToolsTest_##elemtype() : \ + MeshedIntersectionToolsTest() { \ + if (unitlog->summarized_logs_enabled()) \ + this->libmesh_suite_name = "MeshedIntersectionToolsTest"; \ + else \ + this->libmesh_suite_name = "MeshedIntersectionToolsTest_" #elemtype; \ + } \ + CPPUNIT_TEST_SUITE( MeshedIntersectionToolsTest_##elemtype ); \ + MESHEDINTERSECTIONTOOLSTEST; \ + CPPUNIT_TEST_SUITE_END(); \ + }; \ + \ + CPPUNIT_TEST_SUITE_REGISTRATION( MeshedIntersectionToolsTest_##elemtype ) + + +#if LIBMESH_DIM > 2 +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(TET4); +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(TET10); +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(TET14); + +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(HEX8); +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(HEX20); +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(HEX27); + +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(PRISM6); +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(PRISM15); +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(PRISM18); +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(PRISM20); +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(PRISM21); + +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(PYRAMID5); +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(PYRAMID13); +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(PYRAMID14); +#endif // LIBMESH_DIM > 2 From cf19f26dfeb90213809acb9fce996b1fcd40cc37 Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Mon, 14 Nov 2022 09:37:23 -0700 Subject: [PATCH 12/30] ElemCorner improvements - Add 1D edge support for at vertex - Add 2D support/testing for being at an edge (a side) - Add additional testing --- include/geom/elem_corner.h | 8 +- src/geom/elem_corner.C | 15 +--- tests/geom/elem_corner_test.C | 140 ++++++++++++++++++++++------------ 3 files changed, 98 insertions(+), 65 deletions(-) diff --git a/include/geom/elem_corner.h b/include/geom/elem_corner.h index 07a83e3e9ed..17fda77f4ab 100644 --- a/include/geom/elem_corner.h +++ b/include/geom/elem_corner.h @@ -22,8 +22,6 @@ #include "libmesh/libmesh_common.h" -#if LIBMESH_DIM > 1 - #include "libmesh/elem.h" #include // std::pair @@ -115,7 +113,6 @@ class ElemCorner : public std::pair second = Elem::invalid_vertex; } -#if LIBMESH_DIM > 2 /** * @returns true if at an edge */ @@ -128,6 +125,7 @@ class ElemCorner : public std::pair { libmesh_assert_not_equal_to(v1, Elem::invalid_vertex); libmesh_assert_not_equal_to(v2, Elem::invalid_vertex); + libmesh_assert_not_equal_to(v1, v2); return (first == v1 && second == v2) || (first == v2 && second == v1); } /** @@ -148,6 +146,7 @@ class ElemCorner : public std::pair { libmesh_assert_not_equal_to(v1, Elem::invalid_vertex); libmesh_assert_not_equal_to(v2, Elem::invalid_vertex); + libmesh_assert_not_equal_to(v1, v2); first = v1; second = v2; } @@ -161,7 +160,6 @@ class ElemCorner : public std::pair * @returns The edge when at an edge */ std::unique_ptr build_edge(const Elem & elem) const; -#endif /** * @returns The vertex point when at a vertex @@ -183,6 +181,4 @@ class ElemCorner : public std::pair std::ostream & operator<<(std::ostream & os, const libMesh::ElemCorner & elem_corner); -#endif // LIBMESH_DIM > 1 - #endif // LIBMESH_ELEMCORNER_H diff --git a/src/geom/elem_corner.C b/src/geom/elem_corner.C index f9affc02da1..efc59cbf8c0 100644 --- a/src/geom/elem_corner.C +++ b/src/geom/elem_corner.C @@ -19,14 +19,13 @@ // Local includes #include "libmesh/elem_corner.h" -#if LIBMESH_DIM > 1 namespace libMesh { -#if LIBMESH_DIM > 2 bool ElemCorner::at_edge(const Elem & elem, const unsigned short e) const { + libmesh_assert_greater(elem.dim(), 1); libmesh_assert_less(e, elem.n_edges()); if (!at_edge()) return false; @@ -36,6 +35,7 @@ bool ElemCorner::at_edge(const Elem & elem, const unsigned short e) const std::unique_ptr ElemCorner::build_edge(const Elem & elem) const { + libmesh_assert_greater(elem.dim(), 1); libmesh_assert(at_edge()); libmesh_assert_less(first, elem.n_vertices()); libmesh_assert_less(second, elem.n_vertices()); @@ -46,17 +46,14 @@ std::unique_ptr ElemCorner::build_edge(const Elem & elem) const libmesh_error_msg("Element does not contain vertices in ElemCorner"); } -#endif std::string ElemCorner::print() const { std::stringstream oss; if (at_vertex()) oss << "at vertex " << vertex(); -#if LIBMESH_DIM > 2 else if (at_edge()) oss << "at edge with vertices " << first << " and " << second; -#endif else oss << "not at corner"; return oss.str(); @@ -68,11 +65,9 @@ bool ElemCorner::is_valid(const Elem & elem, const Point & point, const Real tol libmesh_assert(second == Elem::invalid_vertex || second < elem.n_vertices()); if (at_vertex()) - return vertex_point(elem).absolute_fuzzy_equals(point, tol); -#if LIBMESH_DIM > 2 - if (elem.dim() == 3 && at_edge()) + return vertex_point(elem).relative_fuzzy_equals(point, tol); + if (at_edge()) return build_edge(elem)->contains_point(point, tol); -#endif return true; } @@ -85,5 +80,3 @@ operator<<(std::ostream & os, const libMesh::ElemCorner & elem_corner) os << elem_corner.print(); return os; } - -#endif // LIBMESH_DIM > 1 diff --git a/tests/geom/elem_corner_test.C b/tests/geom/elem_corner_test.C index 6e9690486f1..b77df593309 100644 --- a/tests/geom/elem_corner_test.C +++ b/tests/geom/elem_corner_test.C @@ -23,68 +23,112 @@ public: { LOG_UNIT_TEST; - // QUAD elem for vertex testing - Mesh mesh_2d (*TestCommWorld); - MeshTools::Generation::build_square (mesh_2d, 1, 1); - const auto & quad = mesh_2d.elem_ref(0); - // Default constructor: unvalid state const ElemCorner default_corner; CPPUNIT_ASSERT(default_corner.is_invalid()); CPPUNIT_ASSERT(!default_corner.at_corner()); CPPUNIT_ASSERT(!default_corner.at_vertex()); -#if LIBMESH_DIM > 2 CPPUNIT_ASSERT(!default_corner.at_edge()); -#endif // LIBMESH_DIM > 2 CPPUNIT_ASSERT_EQUAL((std::string)"not at corner", default_corner.print()); - CPPUNIT_ASSERT(default_corner.is_valid(quad, quad.point(0))); - - // At vertex - const ElemCorner at_vertex(0, Elem::invalid_vertex); - CPPUNIT_ASSERT(!at_vertex.is_invalid()); - CPPUNIT_ASSERT(at_vertex.at_corner()); - CPPUNIT_ASSERT(at_vertex.at_vertex()); -#if LIBMESH_DIM> 2 - CPPUNIT_ASSERT(!at_vertex.at_edge()); - CPPUNIT_ASSERT(!at_vertex.at_edge(0, 1)); - CPPUNIT_ASSERT(!at_vertex.at_edge(quad, 0)); -#endif // LIBMESH_DIM > 2 - CPPUNIT_ASSERT(at_vertex.at_vertex(0)); - CPPUNIT_ASSERT(!at_vertex.at_vertex(1)); - CPPUNIT_ASSERT_EQUAL(at_vertex.vertex(), (unsigned short)0); - CPPUNIT_ASSERT(at_vertex.is_valid(quad, quad.point(0))); - CPPUNIT_ASSERT(!at_vertex.is_valid(quad, quad.point(2))); + + // EDGE elem for vertex testing + Mesh mesh_1d (*TestCommWorld); + MeshTools::Generation::build_line(mesh_1d, 1); + const auto edge = mesh_1d.elem_ptr(0); + + // At edge vertex + const ElemCorner at_edge_vertex(1, Elem::invalid_vertex); + CPPUNIT_ASSERT(!at_edge_vertex.is_invalid()); + CPPUNIT_ASSERT(at_edge_vertex.at_corner()); + CPPUNIT_ASSERT(at_edge_vertex.at_vertex()); + CPPUNIT_ASSERT(!at_edge_vertex.at_edge()); + CPPUNIT_ASSERT(at_edge_vertex.at_vertex(1)); + CPPUNIT_ASSERT_EQUAL(at_edge_vertex.vertex(), (unsigned short)1); + if (edge) + for (const auto v : edge->vertex_index_range()) + { + CPPUNIT_ASSERT_EQUAL(at_edge_vertex.at_vertex(v), v == 1); + CPPUNIT_ASSERT_EQUAL(at_edge_vertex.is_valid(*edge, edge->point(v)), v == 1); + } + +#if LIBMESH_DIM > 1 + // QUAD elem for vertex testing + Mesh mesh_2d (*TestCommWorld); + MeshTools::Generation::build_square (mesh_2d, 1, 1); + const auto quad = mesh_2d.elem_ptr(0); + + // At quad vertex + const ElemCorner at_quad_vertex(0, Elem::invalid_vertex); + CPPUNIT_ASSERT(!at_quad_vertex.is_invalid()); + CPPUNIT_ASSERT(at_quad_vertex.at_corner()); + CPPUNIT_ASSERT(at_quad_vertex.at_vertex()); + CPPUNIT_ASSERT(!at_quad_vertex.at_edge()); + CPPUNIT_ASSERT(!at_quad_vertex.at_edge(0, 1)); + CPPUNIT_ASSERT(at_quad_vertex.at_vertex(0)); + CPPUNIT_ASSERT(!at_quad_vertex.at_vertex(1)); + CPPUNIT_ASSERT_EQUAL(at_quad_vertex.vertex(), (unsigned short)0); + if (quad) + { + for (const auto v : quad->vertex_index_range()) + CPPUNIT_ASSERT(default_corner.is_valid(*quad, quad->point(v))); + for (const auto e : quad->edge_index_range()) + CPPUNIT_ASSERT(!at_quad_vertex.at_edge(*quad, e)); + for (const auto v : quad->vertex_index_range()) + CPPUNIT_ASSERT_EQUAL(at_quad_vertex.is_valid(*quad, quad->point(v)), v == 0); + } + + // At quad "edge" (a side) + const ElemCorner at_quad_edge(1, 2); + CPPUNIT_ASSERT(!at_quad_edge.is_invalid()); + CPPUNIT_ASSERT(at_quad_edge.at_corner()); + CPPUNIT_ASSERT(!at_quad_edge.at_vertex()); + CPPUNIT_ASSERT(at_quad_edge.at_edge()); + CPPUNIT_ASSERT(!at_quad_edge.at_edge(0, 1)); + CPPUNIT_ASSERT(at_quad_edge.at_edge(1, 2)); + CPPUNIT_ASSERT_EQUAL(at_quad_edge.edge_vertices().first, (unsigned short)1); + CPPUNIT_ASSERT_EQUAL(at_quad_edge.edge_vertices().second, (unsigned short)2); + if (quad) + { + CPPUNIT_ASSERT(at_quad_edge.is_valid(*quad, 0.5 * (quad->point(1) + quad->point(2)))); + for (const auto e : quad->edge_index_range()) + CPPUNIT_ASSERT_EQUAL(at_quad_edge.at_edge(*quad, e), e == 1); + } +#endif #if LIBMESH_DIM > 2 // HEX elem for edge testing Mesh mesh_3d (*TestCommWorld); MeshTools::Generation::build_cube (mesh_3d, 1, 1, 1); - const auto & hex = mesh_3d.elem_ref(0); + const auto hex = mesh_3d.elem_ptr(0); // At edge - const ElemCorner at_edge(0, 1); - CPPUNIT_ASSERT(!at_edge.is_invalid()); - CPPUNIT_ASSERT(at_edge.at_corner()); - CPPUNIT_ASSERT(!at_edge.at_vertex()); - CPPUNIT_ASSERT(!at_edge.at_vertex(0)); - CPPUNIT_ASSERT(at_edge.at_edge()); - CPPUNIT_ASSERT(at_edge.at_edge(0, 1)); - CPPUNIT_ASSERT(at_edge.at_edge(1, 0)); - CPPUNIT_ASSERT(at_edge.at_edge(hex, 0)); - CPPUNIT_ASSERT_EQUAL(at_edge.edge_vertices().first, (unsigned short)0); - CPPUNIT_ASSERT_EQUAL(at_edge.edge_vertices().second, (unsigned short)1); - CPPUNIT_ASSERT(!at_edge.is_invalid()); - CPPUNIT_ASSERT(at_edge.is_valid(hex, (hex.point(0) + hex.point(1)) * 0.5)); - CPPUNIT_ASSERT(at_edge.is_valid(hex, hex.point(0))); - CPPUNIT_ASSERT(at_edge.is_valid(hex, hex.point(1))); - CPPUNIT_ASSERT(!at_edge.is_valid(hex, (hex.point(2)) * 0.5)); - - // build_edge - auto edge_elem = at_edge.build_edge(hex); - CPPUNIT_ASSERT((edge_elem->point(0).absolute_fuzzy_equals(hex.point(0)) - && edge_elem->point(1).absolute_fuzzy_equals(hex.point(1))) || - ((edge_elem->point(1).absolute_fuzzy_equals(hex.point(0)) - && edge_elem->point(0).absolute_fuzzy_equals(hex.point(1))))); + const ElemCorner at_hex_edge(0, 1); + CPPUNIT_ASSERT(!at_hex_edge.is_invalid()); + CPPUNIT_ASSERT(at_hex_edge.at_corner()); + CPPUNIT_ASSERT(!at_hex_edge.at_vertex()); + CPPUNIT_ASSERT(!at_hex_edge.at_vertex(0)); + CPPUNIT_ASSERT(at_hex_edge.at_edge()); + CPPUNIT_ASSERT(at_hex_edge.at_edge(0, 1)); + CPPUNIT_ASSERT(at_hex_edge.at_edge(1, 0)); + CPPUNIT_ASSERT_EQUAL(at_hex_edge.edge_vertices().first, (unsigned short)0); + CPPUNIT_ASSERT_EQUAL(at_hex_edge.edge_vertices().second, (unsigned short)1); + CPPUNIT_ASSERT(!at_hex_edge.is_invalid()); + if (hex) + { + CPPUNIT_ASSERT(at_hex_edge.is_valid(*hex, (hex->point(0) + hex->point(1)) * 0.5)); + for (const auto e : hex->edge_index_range()) + CPPUNIT_ASSERT_EQUAL(at_hex_edge.at_edge(*hex, e), e == 0); + for (const auto v : hex->vertex_index_range()) + CPPUNIT_ASSERT_EQUAL(at_hex_edge.is_valid(*hex, hex->point(v)), v == 0 || v == 1); + CPPUNIT_ASSERT(!at_hex_edge.is_valid(*hex, (hex->point(2)) * 0.5)); + + // build_edge + auto edge_elem = at_hex_edge.build_edge(*hex); + CPPUNIT_ASSERT((edge_elem->point(0).absolute_fuzzy_equals(hex->point(0)) + && edge_elem->point(1).absolute_fuzzy_equals(hex->point(1))) || + ((edge_elem->point(1).absolute_fuzzy_equals(hex->point(0)) + && edge_elem->point(0).absolute_fuzzy_equals(hex->point(1))))); + } #endif // LIBMESH_DIM > 2 // For testing non-const methods From 0600a0fa3d865da6d61613c0c6dce27f4cded206 Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Mon, 14 Nov 2022 09:43:01 -0700 Subject: [PATCH 13/30] Add test for ElemCorner::build_edge for 2D --- tests/geom/elem_corner_test.C | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/tests/geom/elem_corner_test.C b/tests/geom/elem_corner_test.C index b77df593309..29e4eb33712 100644 --- a/tests/geom/elem_corner_test.C +++ b/tests/geom/elem_corner_test.C @@ -93,6 +93,11 @@ public: for (const auto e : quad->edge_index_range()) CPPUNIT_ASSERT_EQUAL(at_quad_edge.at_edge(*quad, e), e == 1); } + auto quad_edge_elem = at_quad_edge.build_edge(*quad); + CPPUNIT_ASSERT((quad_edge_elem->point(0).absolute_fuzzy_equals(quad->point(1)) + && quad_edge_elem->point(1).absolute_fuzzy_equals(quad->point(2))) || + ((quad_edge_elem->point(0).absolute_fuzzy_equals(quad->point(2)) + && quad_edge_elem->point(1).absolute_fuzzy_equals(quad->point(1))))); #endif #if LIBMESH_DIM > 2 @@ -123,11 +128,11 @@ public: CPPUNIT_ASSERT(!at_hex_edge.is_valid(*hex, (hex->point(2)) * 0.5)); // build_edge - auto edge_elem = at_hex_edge.build_edge(*hex); - CPPUNIT_ASSERT((edge_elem->point(0).absolute_fuzzy_equals(hex->point(0)) - && edge_elem->point(1).absolute_fuzzy_equals(hex->point(1))) || - ((edge_elem->point(1).absolute_fuzzy_equals(hex->point(0)) - && edge_elem->point(0).absolute_fuzzy_equals(hex->point(1))))); + auto hex_edge_elem = at_hex_edge.build_edge(*hex); + CPPUNIT_ASSERT((hex_edge_elem->point(0).absolute_fuzzy_equals(hex->point(0)) + && hex_edge_elem->point(1).absolute_fuzzy_equals(hex->point(1))) || + ((hex_edge_elem->point(1).absolute_fuzzy_equals(hex->point(0)) + && hex_edge_elem->point(0).absolute_fuzzy_equals(hex->point(1))))); } #endif // LIBMESH_DIM > 2 From ba4c2261c425728867c59b07600499e0285a3e68 Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Mon, 14 Nov 2022 09:47:12 -0700 Subject: [PATCH 14/30] Fix spelling --- include/geom/elem.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/geom/elem.h b/include/geom/elem.h index 08de4a52dbe..d99bdb5aeda 100644 --- a/include/geom/elem.h +++ b/include/geom/elem.h @@ -754,7 +754,7 @@ class Elem : public ReferenceCountedObject, * \returns A pointer to the beginning of the array that contains the * (local) node numbers on the side \p s * - * This does not create temproraries, unlike \p nodes_on_side. + * This does not create temporaries, unlike \p nodes_on_side. * Use n_nodes_on_side for indexing. */ virtual const unsigned int * nodes_on_side_ptr(const unsigned short s) const = 0; @@ -768,7 +768,7 @@ class Elem : public ReferenceCountedObject, * \returns A pointer to the beginning of the array that contains the * (local) node numbers on the edge \p e * - * This does not create temproraries, unlike \p nodes_on_edge. + * This does not create temporaries, unlike \p nodes_on_edge. * Use n_nodes_on_edge for indexing. */ virtual const unsigned int * nodes_on_edge_ptr(const unsigned short e) const = 0; From 697438c2d9f6ba2c1a9043abebf37f6468f577bd Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Mon, 14 Nov 2022 09:49:40 -0700 Subject: [PATCH 15/30] Correct assertion: we need _at least_ 3 nodes/edge --- src/geom/intersection_tools.C | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/geom/intersection_tools.C b/src/geom/intersection_tools.C index 94a3dc31db9..23859f590ec 100644 --- a/src/geom/intersection_tools.C +++ b/src/geom/intersection_tools.C @@ -94,8 +94,8 @@ bool within_edge_on_side(const Elem & elem, if (elem.default_order() > 1 && !linearize) for (const auto e : elem.edge_index_range()) { - // we should expect 3 edges for our higher order elems - libmesh_assert_equal_to(elem.n_nodes_on_edge(e), 3); + // we should expect at least 3 nodes/edges for our higher order elems + libmesh_assert_greater_equal(elem.n_nodes_on_edge(e), 3); const unsigned int * edge_nodes_map = elem.nodes_on_edge_ptr(e); if (!collinear(elem.point(edge_nodes_map[0]), From 55202ab053b6b86d1fe5d2652ccaa4205a973053 Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Mon, 14 Nov 2022 12:32:29 -0700 Subject: [PATCH 16/30] Make within_segment more robust with a relative tolerance --- include/geom/intersection_tools.h | 16 ----------- src/geom/intersection_tools.C | 43 ++++++++++++---------------- tests/geom/intersection_tools_test.C | 1 - 3 files changed, 18 insertions(+), 42 deletions(-) diff --git a/include/geom/intersection_tools.h b/include/geom/intersection_tools.h index 3a062280b64..3beaed511e3 100644 --- a/include/geom/intersection_tools.h +++ b/include/geom/intersection_tools.h @@ -41,22 +41,6 @@ enum WithinSegmentResult : int { AT_END = 2, BETWEEN = 3 }; -/** - * Checks whether or not a point is within a line segment - * @param s1 The first point on the segment - * @param s2 The second point on the segment - * @param length The segment length (for optimization if it's already computed) - * @param p The point - * @param tol The tolerance to use - * @return Enum denoting whether or not the point is not within, at s1, - * at s2, or between [s1, s2] - */ -WithinSegmentResult within_segment(const Point & s1, - const Point & s2, - const Real length, - const Point & p, - const Real tol = TOLERANCE); - /** * Checks whether or not a point is within a line segment * @param s1 The first point on the segment diff --git a/src/geom/intersection_tools.C b/src/geom/intersection_tools.C index 23859f590ec..8c4b5548d2d 100644 --- a/src/geom/intersection_tools.C +++ b/src/geom/intersection_tools.C @@ -29,40 +29,33 @@ namespace libMesh::IntersectionTools WithinSegmentResult within_segment(const Point & s1, const Point & s2, - const Real length, const Point & p, const Real tol) { - libmesh_assert(!s1.absolute_fuzzy_equals(s2, tol)); - libmesh_assert_less(std::abs((s1 - s2).norm() - length), tol); + libmesh_assert(!s1.relative_fuzzy_equals(s2, tol)); + // First, check whether or not the points are collinear + const auto l = s1 - s2; + const auto l_norm = l.norm(); const auto diff1 = p - s1; - const auto diff2 = p - s2; - const auto tol_scaled = tol * length; - - if (diff1 * diff2 > tol_scaled) - return NOT_WITHIN; - const auto diff1_norm = diff1.norm(); - if (diff1_norm < tol_scaled) - return AT_BEGINNING; - - const auto diff2_norm = diff2.norm(); - if (diff2_norm < tol_scaled) - return AT_END; + if ((std::abs(l * diff1) / (l_norm * diff1_norm)) < ((Real)1 - tol)) + return NOT_WITHIN; - // whether or not p is _between_ [s1, s2] - if (std::abs(diff1_norm + diff2_norm - length) < tol_scaled) + // If the points are collinear, make sure that p is + // somewhere between [s1, s2] + const auto diff2_norm = (p - s2).norm(); + const auto tol_scaled = tol * l_norm; + if (std::abs(diff1_norm + diff2_norm - l_norm) < tol_scaled) + { + if (diff1_norm < tol_scaled) + return AT_BEGINNING; + if (diff2_norm < tol_scaled) + return AT_END; return BETWEEN; - return NOT_WITHIN; -} + } -WithinSegmentResult within_segment(const Point & s1, - const Point & s2, - const Point & p, - const Real tol) -{ - return within_segment(s1, s2, (s1 - s2).norm(), p, tol); + return NOT_WITHIN; } bool collinear(const Point & p1, diff --git a/tests/geom/intersection_tools_test.C b/tests/geom/intersection_tools_test.C index 5f4635403db..c0d2e833094 100644 --- a/tests/geom/intersection_tools_test.C +++ b/tests/geom/intersection_tools_test.C @@ -47,7 +47,6 @@ public: else if (i == segments) within_result = IntersectionTools::WithinSegmentResult::AT_END; - CPPUNIT_ASSERT_EQUAL(IntersectionTools::within_segment(s1, s2, length, p), within_result); CPPUNIT_ASSERT_EQUAL(IntersectionTools::within_segment(s1, s2, p), within_result); } From 13f2ec823c9291f47db293f990750cb306df2584 Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Mon, 14 Nov 2022 12:36:28 -0700 Subject: [PATCH 17/30] Update docstring to note relative tolerance --- include/geom/intersection_tools.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/geom/intersection_tools.h b/include/geom/intersection_tools.h index 3beaed511e3..f1ba2f110be 100644 --- a/include/geom/intersection_tools.h +++ b/include/geom/intersection_tools.h @@ -46,7 +46,7 @@ enum WithinSegmentResult : int { * @param s1 The first point on the segment * @param s2 The second point on the segment * @param p The point - * @param tol The tolerance to use + * @param tol The relative tolerance to use * @return Enum denoting whether or not the point is not within, at s1, * at s2, or between [s1, s2] */ From 0f0a476b9a44c1269bb2a3f27548373962d5ca39 Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Mon, 14 Nov 2022 12:58:22 -0700 Subject: [PATCH 18/30] Make collinear more robust with a relative tolerance --- include/geom/intersection_tools.h | 3 ++- src/geom/intersection_tools.C | 14 ++++++++------ 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/include/geom/intersection_tools.h b/include/geom/intersection_tools.h index f1ba2f110be..63c786605f2 100644 --- a/include/geom/intersection_tools.h +++ b/include/geom/intersection_tools.h @@ -60,7 +60,8 @@ WithinSegmentResult within_segment(const Point & s1, * @param p1 The first point * @param p2 The second point * @param p3 The third point - * @param tol The tolerance to use + * @param tol The tolerance to use (absolute tolerance of the cosine + * of the angle between [p1 -> p2] and [p1 -> p3]) * @return Whether or not the given points are collinear */ bool collinear(const Point & p1, diff --git a/src/geom/intersection_tools.C b/src/geom/intersection_tools.C index 8c4b5548d2d..f2f476b177f 100644 --- a/src/geom/intersection_tools.C +++ b/src/geom/intersection_tools.C @@ -63,12 +63,14 @@ bool collinear(const Point & p1, const Point & p3, const Real tol) { - // (p1 -> p2) X (p1 - > p3) should be == the zero vector - const auto p1p2_cross_p1p3 = (p2 - p1).cross(p3 - p1); - for (const auto i : make_range(LIBMESH_DIM)) - if (std::abs(p1p2_cross_p1p3(i)) > tol) - return false; - return true; + const auto p2_p1 = p1 - p2; + const auto p2_p1_norm = p2_p1.norm(); + const auto p3_p2 = p2 - p3; + const auto p3_p2_norm = p3_p2.norm(); + const auto denom = p2_p1_norm * p3_p2_norm; + if (denom == 0) // same points + return true; + return (std::abs(p2_p1 * p3_p2) / denom) > ((Real)1 - tol); } bool within_edge_on_side(const Elem & elem, From 5c29b5b9e67b8fb7a33fdcaed88f3ea2529f9a29 Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Mon, 14 Nov 2022 13:25:36 -0700 Subject: [PATCH 19/30] Make within_edge_on_side more robust with a relative tolerance --- src/geom/intersection_tools.C | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/geom/intersection_tools.C b/src/geom/intersection_tools.C index f2f476b177f..09a6684001f 100644 --- a/src/geom/intersection_tools.C +++ b/src/geom/intersection_tools.C @@ -120,17 +120,17 @@ bool within_edge_on_side(const Elem & elem, if (within_result == BETWEEN) { corner.set_edge(last_v, other_v); - libmesh_assert(corner.build_edge(elem)->close_to_point(p, tol)); + libmesh_assert(corner.build_edge(elem)->contains_point(p, tol)); } else if (within_result == AT_BEGINNING) { corner.set_vertex(last_v); - libmesh_assert(elem.point(last_v).absolute_fuzzy_equals(p, tol)); + libmesh_assert(elem.point(last_v).relative_fuzzy_equals(p, tol)); } else { corner.set_vertex(other_v); - libmesh_assert(elem.point(other_v).absolute_fuzzy_equals(p, tol)); + libmesh_assert(elem.point(other_v).relative_fuzzy_equals(p, tol)); } return true; } From c054c9844a88f1aec322e6cad18ce0daed2bd543 Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Mon, 14 Nov 2022 13:37:10 -0700 Subject: [PATCH 20/30] Add proxy version of ElemCorner::build_edge --- include/geom/elem_corner.h | 6 +++++- src/geom/elem_corner.C | 14 ++++++++++++-- 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/include/geom/elem_corner.h b/include/geom/elem_corner.h index 17fda77f4ab..1e070bc7ec3 100644 --- a/include/geom/elem_corner.h +++ b/include/geom/elem_corner.h @@ -157,7 +157,11 @@ class ElemCorner : public std::pair { set_edge(vs.first, vs.second); } /** - * @returns The edge when at an edge + * Builds an edge of element \p elem into the Elem \p edge when at an edge + */ + void build_edge(const Elem & elem, std::unique_ptr & edge) const; + /** + * @returns The built edge of element \p elem when at an edge */ std::unique_ptr build_edge(const Elem & elem) const; diff --git a/src/geom/elem_corner.C b/src/geom/elem_corner.C index efc59cbf8c0..9468449e6f5 100644 --- a/src/geom/elem_corner.C +++ b/src/geom/elem_corner.C @@ -33,7 +33,7 @@ bool ElemCorner::at_edge(const Elem & elem, const unsigned short e) const return at_edge(nodes_on_edge_ptr[0], nodes_on_edge_ptr[1]); } -std::unique_ptr ElemCorner::build_edge(const Elem & elem) const +void ElemCorner::build_edge(const Elem & elem, std::unique_ptr & edge) const { libmesh_assert_greater(elem.dim(), 1); libmesh_assert(at_edge()); @@ -42,11 +42,21 @@ std::unique_ptr ElemCorner::build_edge(const Elem & elem) const for (const auto e : elem.edge_index_range()) if (elem.is_node_on_edge(first, e) && elem.is_node_on_edge(second, e)) - return elem.build_edge_ptr(e); + { + elem.build_edge_ptr(edge, e); + return; + } libmesh_error_msg("Element does not contain vertices in ElemCorner"); } +std::unique_ptr ElemCorner::build_edge(const Elem & elem) const +{ + std::unique_ptr edge; + build_edge(elem, edge); + return edge; +} + std::string ElemCorner::print() const { std::stringstream oss; From 53ec5302ad5a0807b5490a7ef1200bc8e1095b01 Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Mon, 14 Nov 2022 08:43:55 -0700 Subject: [PATCH 21/30] Re-bootstrap --- Makefile.in | 237 +++++++++++++++++++++++++++++------- include/Makefile.in | 2 + include/include_HEADERS | 2 + include/libmesh/Makefile.am | 8 ++ include/libmesh/Makefile.in | 25 ++-- src/libmesh_SOURCES | 2 + tests/Makefile.am | 2 + tests/Makefile.in | 228 +++++++++++++++++++++++++++++++++- 8 files changed, 446 insertions(+), 60 deletions(-) diff --git a/Makefile.in b/Makefile.in index 043fb445fa8..8195f97bd1b 100644 --- a/Makefile.in +++ b/Makefile.in @@ -346,16 +346,17 @@ am__libmesh_dbg_la_SOURCES_DIST = src/base/default_coupling.C \ src/geom/cell_tet4.C src/geom/edge.C src/geom/edge_edge2.C \ src/geom/edge_edge3.C src/geom/edge_edge4.C \ src/geom/edge_inf_edge2.C src/geom/elem.C \ - src/geom/elem_cutter.C src/geom/elem_quality.C \ - src/geom/elem_refinement.C src/geom/elem_side_builder.C \ - src/geom/face.C src/geom/face_inf_quad.C \ - src/geom/face_inf_quad4.C src/geom/face_inf_quad6.C \ - src/geom/face_quad.C src/geom/face_quad4.C \ - src/geom/face_quad4_shell.C src/geom/face_quad8.C \ - src/geom/face_quad8_shell.C src/geom/face_quad9.C \ - src/geom/face_tri.C src/geom/face_tri3.C \ + src/geom/elem_corner.C src/geom/elem_cutter.C \ + src/geom/elem_quality.C src/geom/elem_refinement.C \ + src/geom/elem_side_builder.C src/geom/face.C \ + src/geom/face_inf_quad.C src/geom/face_inf_quad4.C \ + src/geom/face_inf_quad6.C src/geom/face_quad.C \ + src/geom/face_quad4.C src/geom/face_quad4_shell.C \ + src/geom/face_quad8.C src/geom/face_quad8_shell.C \ + src/geom/face_quad9.C src/geom/face_tri.C src/geom/face_tri3.C \ src/geom/face_tri3_shell.C src/geom/face_tri3_subdivision.C \ - src/geom/face_tri6.C src/geom/face_tri7.C src/geom/node.C \ + src/geom/face_tri6.C src/geom/face_tri7.C \ + src/geom/intersection_tools.C src/geom/node.C \ src/geom/node_elem.C src/geom/plane.C src/geom/point.C \ src/geom/reference_elem.C src/geom/reference_elem.data \ src/geom/remote_elem.C src/geom/sphere.C src/geom/surface.C \ @@ -715,6 +716,7 @@ am__objects_1 = src/base/libmesh_dbg_la-default_coupling.lo \ src/geom/libmesh_dbg_la-edge_edge4.lo \ src/geom/libmesh_dbg_la-edge_inf_edge2.lo \ src/geom/libmesh_dbg_la-elem.lo \ + src/geom/libmesh_dbg_la-elem_corner.lo \ src/geom/libmesh_dbg_la-elem_cutter.lo \ src/geom/libmesh_dbg_la-elem_quality.lo \ src/geom/libmesh_dbg_la-elem_refinement.lo \ @@ -735,6 +737,7 @@ am__objects_1 = src/base/libmesh_dbg_la-default_coupling.lo \ src/geom/libmesh_dbg_la-face_tri3_subdivision.lo \ src/geom/libmesh_dbg_la-face_tri6.lo \ src/geom/libmesh_dbg_la-face_tri7.lo \ + src/geom/libmesh_dbg_la-intersection_tools.lo \ src/geom/libmesh_dbg_la-node.lo \ src/geom/libmesh_dbg_la-node_elem.lo \ src/geom/libmesh_dbg_la-plane.lo \ @@ -1107,16 +1110,17 @@ am__libmesh_devel_la_SOURCES_DIST = src/base/default_coupling.C \ src/geom/cell_tet4.C src/geom/edge.C src/geom/edge_edge2.C \ src/geom/edge_edge3.C src/geom/edge_edge4.C \ src/geom/edge_inf_edge2.C src/geom/elem.C \ - src/geom/elem_cutter.C src/geom/elem_quality.C \ - src/geom/elem_refinement.C src/geom/elem_side_builder.C \ - src/geom/face.C src/geom/face_inf_quad.C \ - src/geom/face_inf_quad4.C src/geom/face_inf_quad6.C \ - src/geom/face_quad.C src/geom/face_quad4.C \ - src/geom/face_quad4_shell.C src/geom/face_quad8.C \ - src/geom/face_quad8_shell.C src/geom/face_quad9.C \ - src/geom/face_tri.C src/geom/face_tri3.C \ + src/geom/elem_corner.C src/geom/elem_cutter.C \ + src/geom/elem_quality.C src/geom/elem_refinement.C \ + src/geom/elem_side_builder.C src/geom/face.C \ + src/geom/face_inf_quad.C src/geom/face_inf_quad4.C \ + src/geom/face_inf_quad6.C src/geom/face_quad.C \ + src/geom/face_quad4.C src/geom/face_quad4_shell.C \ + src/geom/face_quad8.C src/geom/face_quad8_shell.C \ + src/geom/face_quad9.C src/geom/face_tri.C src/geom/face_tri3.C \ src/geom/face_tri3_shell.C src/geom/face_tri3_subdivision.C \ - src/geom/face_tri6.C src/geom/face_tri7.C src/geom/node.C \ + src/geom/face_tri6.C src/geom/face_tri7.C \ + src/geom/intersection_tools.C src/geom/node.C \ src/geom/node_elem.C src/geom/plane.C src/geom/point.C \ src/geom/reference_elem.C src/geom/reference_elem.data \ src/geom/remote_elem.C src/geom/sphere.C src/geom/surface.C \ @@ -1475,6 +1479,7 @@ am__objects_2 = src/base/libmesh_devel_la-default_coupling.lo \ src/geom/libmesh_devel_la-edge_edge4.lo \ src/geom/libmesh_devel_la-edge_inf_edge2.lo \ src/geom/libmesh_devel_la-elem.lo \ + src/geom/libmesh_devel_la-elem_corner.lo \ src/geom/libmesh_devel_la-elem_cutter.lo \ src/geom/libmesh_devel_la-elem_quality.lo \ src/geom/libmesh_devel_la-elem_refinement.lo \ @@ -1495,6 +1500,7 @@ am__objects_2 = src/base/libmesh_devel_la-default_coupling.lo \ src/geom/libmesh_devel_la-face_tri3_subdivision.lo \ src/geom/libmesh_devel_la-face_tri6.lo \ src/geom/libmesh_devel_la-face_tri7.lo \ + src/geom/libmesh_devel_la-intersection_tools.lo \ src/geom/libmesh_devel_la-node.lo \ src/geom/libmesh_devel_la-node_elem.lo \ src/geom/libmesh_devel_la-plane.lo \ @@ -1864,16 +1870,17 @@ am__libmesh_oprof_la_SOURCES_DIST = src/base/default_coupling.C \ src/geom/cell_tet4.C src/geom/edge.C src/geom/edge_edge2.C \ src/geom/edge_edge3.C src/geom/edge_edge4.C \ src/geom/edge_inf_edge2.C src/geom/elem.C \ - src/geom/elem_cutter.C src/geom/elem_quality.C \ - src/geom/elem_refinement.C src/geom/elem_side_builder.C \ - src/geom/face.C src/geom/face_inf_quad.C \ - src/geom/face_inf_quad4.C src/geom/face_inf_quad6.C \ - src/geom/face_quad.C src/geom/face_quad4.C \ - src/geom/face_quad4_shell.C src/geom/face_quad8.C \ - src/geom/face_quad8_shell.C src/geom/face_quad9.C \ - src/geom/face_tri.C src/geom/face_tri3.C \ + src/geom/elem_corner.C src/geom/elem_cutter.C \ + src/geom/elem_quality.C src/geom/elem_refinement.C \ + src/geom/elem_side_builder.C src/geom/face.C \ + src/geom/face_inf_quad.C src/geom/face_inf_quad4.C \ + src/geom/face_inf_quad6.C src/geom/face_quad.C \ + src/geom/face_quad4.C src/geom/face_quad4_shell.C \ + src/geom/face_quad8.C src/geom/face_quad8_shell.C \ + src/geom/face_quad9.C src/geom/face_tri.C src/geom/face_tri3.C \ src/geom/face_tri3_shell.C src/geom/face_tri3_subdivision.C \ - src/geom/face_tri6.C src/geom/face_tri7.C src/geom/node.C \ + src/geom/face_tri6.C src/geom/face_tri7.C \ + src/geom/intersection_tools.C src/geom/node.C \ src/geom/node_elem.C src/geom/plane.C src/geom/point.C \ src/geom/reference_elem.C src/geom/reference_elem.data \ src/geom/remote_elem.C src/geom/sphere.C src/geom/surface.C \ @@ -2232,6 +2239,7 @@ am__objects_3 = src/base/libmesh_oprof_la-default_coupling.lo \ src/geom/libmesh_oprof_la-edge_edge4.lo \ src/geom/libmesh_oprof_la-edge_inf_edge2.lo \ src/geom/libmesh_oprof_la-elem.lo \ + src/geom/libmesh_oprof_la-elem_corner.lo \ src/geom/libmesh_oprof_la-elem_cutter.lo \ src/geom/libmesh_oprof_la-elem_quality.lo \ src/geom/libmesh_oprof_la-elem_refinement.lo \ @@ -2252,6 +2260,7 @@ am__objects_3 = src/base/libmesh_oprof_la-default_coupling.lo \ src/geom/libmesh_oprof_la-face_tri3_subdivision.lo \ src/geom/libmesh_oprof_la-face_tri6.lo \ src/geom/libmesh_oprof_la-face_tri7.lo \ + src/geom/libmesh_oprof_la-intersection_tools.lo \ src/geom/libmesh_oprof_la-node.lo \ src/geom/libmesh_oprof_la-node_elem.lo \ src/geom/libmesh_oprof_la-plane.lo \ @@ -2621,16 +2630,17 @@ am__libmesh_opt_la_SOURCES_DIST = src/base/default_coupling.C \ src/geom/cell_tet4.C src/geom/edge.C src/geom/edge_edge2.C \ src/geom/edge_edge3.C src/geom/edge_edge4.C \ src/geom/edge_inf_edge2.C src/geom/elem.C \ - src/geom/elem_cutter.C src/geom/elem_quality.C \ - src/geom/elem_refinement.C src/geom/elem_side_builder.C \ - src/geom/face.C src/geom/face_inf_quad.C \ - src/geom/face_inf_quad4.C src/geom/face_inf_quad6.C \ - src/geom/face_quad.C src/geom/face_quad4.C \ - src/geom/face_quad4_shell.C src/geom/face_quad8.C \ - src/geom/face_quad8_shell.C src/geom/face_quad9.C \ - src/geom/face_tri.C src/geom/face_tri3.C \ + src/geom/elem_corner.C src/geom/elem_cutter.C \ + src/geom/elem_quality.C src/geom/elem_refinement.C \ + src/geom/elem_side_builder.C src/geom/face.C \ + src/geom/face_inf_quad.C src/geom/face_inf_quad4.C \ + src/geom/face_inf_quad6.C src/geom/face_quad.C \ + src/geom/face_quad4.C src/geom/face_quad4_shell.C \ + src/geom/face_quad8.C src/geom/face_quad8_shell.C \ + src/geom/face_quad9.C src/geom/face_tri.C src/geom/face_tri3.C \ src/geom/face_tri3_shell.C src/geom/face_tri3_subdivision.C \ - src/geom/face_tri6.C src/geom/face_tri7.C src/geom/node.C \ + src/geom/face_tri6.C src/geom/face_tri7.C \ + src/geom/intersection_tools.C src/geom/node.C \ src/geom/node_elem.C src/geom/plane.C src/geom/point.C \ src/geom/reference_elem.C src/geom/reference_elem.data \ src/geom/remote_elem.C src/geom/sphere.C src/geom/surface.C \ @@ -2989,6 +2999,7 @@ am__objects_4 = src/base/libmesh_opt_la-default_coupling.lo \ src/geom/libmesh_opt_la-edge_edge4.lo \ src/geom/libmesh_opt_la-edge_inf_edge2.lo \ src/geom/libmesh_opt_la-elem.lo \ + src/geom/libmesh_opt_la-elem_corner.lo \ src/geom/libmesh_opt_la-elem_cutter.lo \ src/geom/libmesh_opt_la-elem_quality.lo \ src/geom/libmesh_opt_la-elem_refinement.lo \ @@ -3009,6 +3020,7 @@ am__objects_4 = src/base/libmesh_opt_la-default_coupling.lo \ src/geom/libmesh_opt_la-face_tri3_subdivision.lo \ src/geom/libmesh_opt_la-face_tri6.lo \ src/geom/libmesh_opt_la-face_tri7.lo \ + src/geom/libmesh_opt_la-intersection_tools.lo \ src/geom/libmesh_opt_la-node.lo \ src/geom/libmesh_opt_la-node_elem.lo \ src/geom/libmesh_opt_la-plane.lo \ @@ -3377,16 +3389,17 @@ am__libmesh_prof_la_SOURCES_DIST = src/base/default_coupling.C \ src/geom/cell_tet4.C src/geom/edge.C src/geom/edge_edge2.C \ src/geom/edge_edge3.C src/geom/edge_edge4.C \ src/geom/edge_inf_edge2.C src/geom/elem.C \ - src/geom/elem_cutter.C src/geom/elem_quality.C \ - src/geom/elem_refinement.C src/geom/elem_side_builder.C \ - src/geom/face.C src/geom/face_inf_quad.C \ - src/geom/face_inf_quad4.C src/geom/face_inf_quad6.C \ - src/geom/face_quad.C src/geom/face_quad4.C \ - src/geom/face_quad4_shell.C src/geom/face_quad8.C \ - src/geom/face_quad8_shell.C src/geom/face_quad9.C \ - src/geom/face_tri.C src/geom/face_tri3.C \ + src/geom/elem_corner.C src/geom/elem_cutter.C \ + src/geom/elem_quality.C src/geom/elem_refinement.C \ + src/geom/elem_side_builder.C src/geom/face.C \ + src/geom/face_inf_quad.C src/geom/face_inf_quad4.C \ + src/geom/face_inf_quad6.C src/geom/face_quad.C \ + src/geom/face_quad4.C src/geom/face_quad4_shell.C \ + src/geom/face_quad8.C src/geom/face_quad8_shell.C \ + src/geom/face_quad9.C src/geom/face_tri.C src/geom/face_tri3.C \ src/geom/face_tri3_shell.C src/geom/face_tri3_subdivision.C \ - src/geom/face_tri6.C src/geom/face_tri7.C src/geom/node.C \ + src/geom/face_tri6.C src/geom/face_tri7.C \ + src/geom/intersection_tools.C src/geom/node.C \ src/geom/node_elem.C src/geom/plane.C src/geom/point.C \ src/geom/reference_elem.C src/geom/reference_elem.data \ src/geom/remote_elem.C src/geom/sphere.C src/geom/surface.C \ @@ -3745,6 +3758,7 @@ am__objects_5 = src/base/libmesh_prof_la-default_coupling.lo \ src/geom/libmesh_prof_la-edge_edge4.lo \ src/geom/libmesh_prof_la-edge_inf_edge2.lo \ src/geom/libmesh_prof_la-elem.lo \ + src/geom/libmesh_prof_la-elem_corner.lo \ src/geom/libmesh_prof_la-elem_cutter.lo \ src/geom/libmesh_prof_la-elem_quality.lo \ src/geom/libmesh_prof_la-elem_refinement.lo \ @@ -3765,6 +3779,7 @@ am__objects_5 = src/base/libmesh_prof_la-default_coupling.lo \ src/geom/libmesh_prof_la-face_tri3_subdivision.lo \ src/geom/libmesh_prof_la-face_tri6.lo \ src/geom/libmesh_prof_la-face_tri7.lo \ + src/geom/libmesh_prof_la-intersection_tools.lo \ src/geom/libmesh_prof_la-node.lo \ src/geom/libmesh_prof_la-node_elem.lo \ src/geom/libmesh_prof_la-plane.lo \ @@ -5104,6 +5119,7 @@ am__depfiles_remade = src/apps/$(DEPDIR)/amr_dbg-amr.Po \ src/geom/$(DEPDIR)/libmesh_dbg_la-edge_edge4.Plo \ src/geom/$(DEPDIR)/libmesh_dbg_la-edge_inf_edge2.Plo \ src/geom/$(DEPDIR)/libmesh_dbg_la-elem.Plo \ + src/geom/$(DEPDIR)/libmesh_dbg_la-elem_corner.Plo \ src/geom/$(DEPDIR)/libmesh_dbg_la-elem_cutter.Plo \ src/geom/$(DEPDIR)/libmesh_dbg_la-elem_quality.Plo \ src/geom/$(DEPDIR)/libmesh_dbg_la-elem_refinement.Plo \ @@ -5124,6 +5140,7 @@ am__depfiles_remade = src/apps/$(DEPDIR)/amr_dbg-amr.Po \ src/geom/$(DEPDIR)/libmesh_dbg_la-face_tri3_subdivision.Plo \ src/geom/$(DEPDIR)/libmesh_dbg_la-face_tri6.Plo \ src/geom/$(DEPDIR)/libmesh_dbg_la-face_tri7.Plo \ + src/geom/$(DEPDIR)/libmesh_dbg_la-intersection_tools.Plo \ src/geom/$(DEPDIR)/libmesh_dbg_la-node.Plo \ src/geom/$(DEPDIR)/libmesh_dbg_la-node_elem.Plo \ src/geom/$(DEPDIR)/libmesh_dbg_la-plane.Plo \ @@ -5166,6 +5183,7 @@ am__depfiles_remade = src/apps/$(DEPDIR)/amr_dbg-amr.Po \ src/geom/$(DEPDIR)/libmesh_devel_la-edge_edge4.Plo \ src/geom/$(DEPDIR)/libmesh_devel_la-edge_inf_edge2.Plo \ src/geom/$(DEPDIR)/libmesh_devel_la-elem.Plo \ + src/geom/$(DEPDIR)/libmesh_devel_la-elem_corner.Plo \ src/geom/$(DEPDIR)/libmesh_devel_la-elem_cutter.Plo \ src/geom/$(DEPDIR)/libmesh_devel_la-elem_quality.Plo \ src/geom/$(DEPDIR)/libmesh_devel_la-elem_refinement.Plo \ @@ -5186,6 +5204,7 @@ am__depfiles_remade = src/apps/$(DEPDIR)/amr_dbg-amr.Po \ src/geom/$(DEPDIR)/libmesh_devel_la-face_tri3_subdivision.Plo \ src/geom/$(DEPDIR)/libmesh_devel_la-face_tri6.Plo \ src/geom/$(DEPDIR)/libmesh_devel_la-face_tri7.Plo \ + src/geom/$(DEPDIR)/libmesh_devel_la-intersection_tools.Plo \ src/geom/$(DEPDIR)/libmesh_devel_la-node.Plo \ src/geom/$(DEPDIR)/libmesh_devel_la-node_elem.Plo \ src/geom/$(DEPDIR)/libmesh_devel_la-plane.Plo \ @@ -5228,6 +5247,7 @@ am__depfiles_remade = src/apps/$(DEPDIR)/amr_dbg-amr.Po \ src/geom/$(DEPDIR)/libmesh_oprof_la-edge_edge4.Plo \ src/geom/$(DEPDIR)/libmesh_oprof_la-edge_inf_edge2.Plo \ src/geom/$(DEPDIR)/libmesh_oprof_la-elem.Plo \ + src/geom/$(DEPDIR)/libmesh_oprof_la-elem_corner.Plo \ src/geom/$(DEPDIR)/libmesh_oprof_la-elem_cutter.Plo \ src/geom/$(DEPDIR)/libmesh_oprof_la-elem_quality.Plo \ src/geom/$(DEPDIR)/libmesh_oprof_la-elem_refinement.Plo \ @@ -5248,6 +5268,7 @@ am__depfiles_remade = src/apps/$(DEPDIR)/amr_dbg-amr.Po \ src/geom/$(DEPDIR)/libmesh_oprof_la-face_tri3_subdivision.Plo \ src/geom/$(DEPDIR)/libmesh_oprof_la-face_tri6.Plo \ src/geom/$(DEPDIR)/libmesh_oprof_la-face_tri7.Plo \ + src/geom/$(DEPDIR)/libmesh_oprof_la-intersection_tools.Plo \ src/geom/$(DEPDIR)/libmesh_oprof_la-node.Plo \ src/geom/$(DEPDIR)/libmesh_oprof_la-node_elem.Plo \ src/geom/$(DEPDIR)/libmesh_oprof_la-plane.Plo \ @@ -5290,6 +5311,7 @@ am__depfiles_remade = src/apps/$(DEPDIR)/amr_dbg-amr.Po \ src/geom/$(DEPDIR)/libmesh_opt_la-edge_edge4.Plo \ src/geom/$(DEPDIR)/libmesh_opt_la-edge_inf_edge2.Plo \ src/geom/$(DEPDIR)/libmesh_opt_la-elem.Plo \ + src/geom/$(DEPDIR)/libmesh_opt_la-elem_corner.Plo \ src/geom/$(DEPDIR)/libmesh_opt_la-elem_cutter.Plo \ src/geom/$(DEPDIR)/libmesh_opt_la-elem_quality.Plo \ src/geom/$(DEPDIR)/libmesh_opt_la-elem_refinement.Plo \ @@ -5310,6 +5332,7 @@ am__depfiles_remade = src/apps/$(DEPDIR)/amr_dbg-amr.Po \ src/geom/$(DEPDIR)/libmesh_opt_la-face_tri3_subdivision.Plo \ src/geom/$(DEPDIR)/libmesh_opt_la-face_tri6.Plo \ src/geom/$(DEPDIR)/libmesh_opt_la-face_tri7.Plo \ + src/geom/$(DEPDIR)/libmesh_opt_la-intersection_tools.Plo \ src/geom/$(DEPDIR)/libmesh_opt_la-node.Plo \ src/geom/$(DEPDIR)/libmesh_opt_la-node_elem.Plo \ src/geom/$(DEPDIR)/libmesh_opt_la-plane.Plo \ @@ -5352,6 +5375,7 @@ am__depfiles_remade = src/apps/$(DEPDIR)/amr_dbg-amr.Po \ src/geom/$(DEPDIR)/libmesh_prof_la-edge_edge4.Plo \ src/geom/$(DEPDIR)/libmesh_prof_la-edge_inf_edge2.Plo \ src/geom/$(DEPDIR)/libmesh_prof_la-elem.Plo \ + src/geom/$(DEPDIR)/libmesh_prof_la-elem_corner.Plo \ src/geom/$(DEPDIR)/libmesh_prof_la-elem_cutter.Plo \ src/geom/$(DEPDIR)/libmesh_prof_la-elem_quality.Plo \ src/geom/$(DEPDIR)/libmesh_prof_la-elem_refinement.Plo \ @@ -5372,6 +5396,7 @@ am__depfiles_remade = src/apps/$(DEPDIR)/amr_dbg-amr.Po \ src/geom/$(DEPDIR)/libmesh_prof_la-face_tri3_subdivision.Plo \ src/geom/$(DEPDIR)/libmesh_prof_la-face_tri6.Plo \ src/geom/$(DEPDIR)/libmesh_prof_la-face_tri7.Plo \ + src/geom/$(DEPDIR)/libmesh_prof_la-intersection_tools.Plo \ src/geom/$(DEPDIR)/libmesh_prof_la-node.Plo \ src/geom/$(DEPDIR)/libmesh_prof_la-node_elem.Plo \ src/geom/$(DEPDIR)/libmesh_prof_la-plane.Plo \ @@ -7508,6 +7533,7 @@ libmesh_SOURCES = \ src/geom/edge_edge4.C \ src/geom/edge_inf_edge2.C \ src/geom/elem.C \ + src/geom/elem_corner.C \ src/geom/elem_cutter.C \ src/geom/elem_quality.C \ src/geom/elem_refinement.C \ @@ -7528,6 +7554,7 @@ libmesh_SOURCES = \ src/geom/face_tri3_subdivision.C \ src/geom/face_tri6.C \ src/geom/face_tri7.C \ + src/geom/intersection_tools.C \ src/geom/node.C \ src/geom/node_elem.C \ src/geom/plane.C \ @@ -8589,6 +8616,8 @@ src/geom/libmesh_dbg_la-edge_inf_edge2.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_dbg_la-elem.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) +src/geom/libmesh_dbg_la-elem_corner.lo: src/geom/$(am__dirstamp) \ + src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_dbg_la-elem_cutter.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_dbg_la-elem_quality.lo: src/geom/$(am__dirstamp) \ @@ -8629,6 +8658,8 @@ src/geom/libmesh_dbg_la-face_tri6.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_dbg_la-face_tri7.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) +src/geom/libmesh_dbg_la-intersection_tools.lo: \ + src/geom/$(am__dirstamp) src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_dbg_la-node.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_dbg_la-node_elem.lo: src/geom/$(am__dirstamp) \ @@ -9752,6 +9783,8 @@ src/geom/libmesh_devel_la-edge_inf_edge2.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_devel_la-elem.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) +src/geom/libmesh_devel_la-elem_corner.lo: src/geom/$(am__dirstamp) \ + src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_devel_la-elem_cutter.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_devel_la-elem_quality.lo: src/geom/$(am__dirstamp) \ @@ -9792,6 +9825,8 @@ src/geom/libmesh_devel_la-face_tri6.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_devel_la-face_tri7.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) +src/geom/libmesh_devel_la-intersection_tools.lo: \ + src/geom/$(am__dirstamp) src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_devel_la-node.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_devel_la-node_elem.lo: src/geom/$(am__dirstamp) \ @@ -10852,6 +10887,8 @@ src/geom/libmesh_oprof_la-edge_inf_edge2.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_oprof_la-elem.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) +src/geom/libmesh_oprof_la-elem_corner.lo: src/geom/$(am__dirstamp) \ + src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_oprof_la-elem_cutter.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_oprof_la-elem_quality.lo: src/geom/$(am__dirstamp) \ @@ -10892,6 +10929,8 @@ src/geom/libmesh_oprof_la-face_tri6.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_oprof_la-face_tri7.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) +src/geom/libmesh_oprof_la-intersection_tools.lo: \ + src/geom/$(am__dirstamp) src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_oprof_la-node.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_oprof_la-node_elem.lo: src/geom/$(am__dirstamp) \ @@ -11952,6 +11991,8 @@ src/geom/libmesh_opt_la-edge_inf_edge2.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_opt_la-elem.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) +src/geom/libmesh_opt_la-elem_corner.lo: src/geom/$(am__dirstamp) \ + src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_opt_la-elem_cutter.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_opt_la-elem_quality.lo: src/geom/$(am__dirstamp) \ @@ -11992,6 +12033,8 @@ src/geom/libmesh_opt_la-face_tri6.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_opt_la-face_tri7.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) +src/geom/libmesh_opt_la-intersection_tools.lo: \ + src/geom/$(am__dirstamp) src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_opt_la-node.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_opt_la-node_elem.lo: src/geom/$(am__dirstamp) \ @@ -13049,6 +13092,8 @@ src/geom/libmesh_prof_la-edge_inf_edge2.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_prof_la-elem.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) +src/geom/libmesh_prof_la-elem_corner.lo: src/geom/$(am__dirstamp) \ + src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_prof_la-elem_cutter.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_prof_la-elem_quality.lo: src/geom/$(am__dirstamp) \ @@ -13089,6 +13134,8 @@ src/geom/libmesh_prof_la-face_tri6.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_prof_la-face_tri7.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) +src/geom/libmesh_prof_la-intersection_tools.lo: \ + src/geom/$(am__dirstamp) src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_prof_la-node.lo: src/geom/$(am__dirstamp) \ src/geom/$(DEPDIR)/$(am__dirstamp) src/geom/libmesh_prof_la-node_elem.lo: src/geom/$(am__dirstamp) \ @@ -14967,6 +15014,7 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_dbg_la-edge_edge4.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_dbg_la-edge_inf_edge2.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_dbg_la-elem.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_dbg_la-elem_corner.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_dbg_la-elem_cutter.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_dbg_la-elem_quality.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_dbg_la-elem_refinement.Plo@am__quote@ # am--include-marker @@ -14987,6 +15035,7 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_dbg_la-face_tri3_subdivision.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_dbg_la-face_tri6.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_dbg_la-face_tri7.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_dbg_la-intersection_tools.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_dbg_la-node.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_dbg_la-node_elem.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_dbg_la-plane.Plo@am__quote@ # am--include-marker @@ -15029,6 +15078,7 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_devel_la-edge_edge4.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_devel_la-edge_inf_edge2.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_devel_la-elem.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_devel_la-elem_corner.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_devel_la-elem_cutter.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_devel_la-elem_quality.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_devel_la-elem_refinement.Plo@am__quote@ # am--include-marker @@ -15049,6 +15099,7 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_devel_la-face_tri3_subdivision.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_devel_la-face_tri6.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_devel_la-face_tri7.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_devel_la-intersection_tools.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_devel_la-node.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_devel_la-node_elem.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_devel_la-plane.Plo@am__quote@ # am--include-marker @@ -15091,6 +15142,7 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_oprof_la-edge_edge4.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_oprof_la-edge_inf_edge2.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_oprof_la-elem.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_oprof_la-elem_corner.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_oprof_la-elem_cutter.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_oprof_la-elem_quality.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_oprof_la-elem_refinement.Plo@am__quote@ # am--include-marker @@ -15111,6 +15163,7 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_oprof_la-face_tri3_subdivision.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_oprof_la-face_tri6.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_oprof_la-face_tri7.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_oprof_la-intersection_tools.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_oprof_la-node.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_oprof_la-node_elem.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_oprof_la-plane.Plo@am__quote@ # am--include-marker @@ -15153,6 +15206,7 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_opt_la-edge_edge4.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_opt_la-edge_inf_edge2.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_opt_la-elem.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_opt_la-elem_corner.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_opt_la-elem_cutter.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_opt_la-elem_quality.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_opt_la-elem_refinement.Plo@am__quote@ # am--include-marker @@ -15173,6 +15227,7 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_opt_la-face_tri3_subdivision.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_opt_la-face_tri6.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_opt_la-face_tri7.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_opt_la-intersection_tools.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_opt_la-node.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_opt_la-node_elem.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_opt_la-plane.Plo@am__quote@ # am--include-marker @@ -15215,6 +15270,7 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_prof_la-edge_edge4.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_prof_la-edge_inf_edge2.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_prof_la-elem.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_prof_la-elem_corner.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_prof_la-elem_cutter.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_prof_la-elem_quality.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_prof_la-elem_refinement.Plo@am__quote@ # am--include-marker @@ -15235,6 +15291,7 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_prof_la-face_tri3_subdivision.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_prof_la-face_tri6.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_prof_la-face_tri7.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_prof_la-intersection_tools.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_prof_la-node.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_prof_la-node_elem.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@src/geom/$(DEPDIR)/libmesh_prof_la-plane.Plo@am__quote@ # am--include-marker @@ -17668,6 +17725,13 @@ src/geom/libmesh_dbg_la-elem.lo: src/geom/elem.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_dbg_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_dbg_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_dbg_la-elem.lo `test -f 'src/geom/elem.C' || echo '$(srcdir)/'`src/geom/elem.C +src/geom/libmesh_dbg_la-elem_corner.lo: src/geom/elem_corner.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_dbg_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_dbg_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_dbg_la-elem_corner.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_dbg_la-elem_corner.Tpo -c -o src/geom/libmesh_dbg_la-elem_corner.lo `test -f 'src/geom/elem_corner.C' || echo '$(srcdir)/'`src/geom/elem_corner.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_dbg_la-elem_corner.Tpo src/geom/$(DEPDIR)/libmesh_dbg_la-elem_corner.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='src/geom/elem_corner.C' object='src/geom/libmesh_dbg_la-elem_corner.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_dbg_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_dbg_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_dbg_la-elem_corner.lo `test -f 'src/geom/elem_corner.C' || echo '$(srcdir)/'`src/geom/elem_corner.C + src/geom/libmesh_dbg_la-elem_cutter.lo: src/geom/elem_cutter.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_dbg_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_dbg_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_dbg_la-elem_cutter.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_dbg_la-elem_cutter.Tpo -c -o src/geom/libmesh_dbg_la-elem_cutter.lo `test -f 'src/geom/elem_cutter.C' || echo '$(srcdir)/'`src/geom/elem_cutter.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_dbg_la-elem_cutter.Tpo src/geom/$(DEPDIR)/libmesh_dbg_la-elem_cutter.Plo @@ -17808,6 +17872,13 @@ src/geom/libmesh_dbg_la-face_tri7.lo: src/geom/face_tri7.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_dbg_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_dbg_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_dbg_la-face_tri7.lo `test -f 'src/geom/face_tri7.C' || echo '$(srcdir)/'`src/geom/face_tri7.C +src/geom/libmesh_dbg_la-intersection_tools.lo: src/geom/intersection_tools.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_dbg_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_dbg_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_dbg_la-intersection_tools.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_dbg_la-intersection_tools.Tpo -c -o src/geom/libmesh_dbg_la-intersection_tools.lo `test -f 'src/geom/intersection_tools.C' || echo '$(srcdir)/'`src/geom/intersection_tools.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_dbg_la-intersection_tools.Tpo src/geom/$(DEPDIR)/libmesh_dbg_la-intersection_tools.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='src/geom/intersection_tools.C' object='src/geom/libmesh_dbg_la-intersection_tools.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_dbg_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_dbg_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_dbg_la-intersection_tools.lo `test -f 'src/geom/intersection_tools.C' || echo '$(srcdir)/'`src/geom/intersection_tools.C + src/geom/libmesh_dbg_la-node.lo: src/geom/node.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_dbg_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_dbg_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_dbg_la-node.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_dbg_la-node.Tpo -c -o src/geom/libmesh_dbg_la-node.lo `test -f 'src/geom/node.C' || echo '$(srcdir)/'`src/geom/node.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_dbg_la-node.Tpo src/geom/$(DEPDIR)/libmesh_dbg_la-node.Plo @@ -20790,6 +20861,13 @@ src/geom/libmesh_devel_la-elem.lo: src/geom/elem.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_devel_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_devel_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_devel_la-elem.lo `test -f 'src/geom/elem.C' || echo '$(srcdir)/'`src/geom/elem.C +src/geom/libmesh_devel_la-elem_corner.lo: src/geom/elem_corner.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_devel_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_devel_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_devel_la-elem_corner.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_devel_la-elem_corner.Tpo -c -o src/geom/libmesh_devel_la-elem_corner.lo `test -f 'src/geom/elem_corner.C' || echo '$(srcdir)/'`src/geom/elem_corner.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_devel_la-elem_corner.Tpo src/geom/$(DEPDIR)/libmesh_devel_la-elem_corner.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='src/geom/elem_corner.C' object='src/geom/libmesh_devel_la-elem_corner.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_devel_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_devel_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_devel_la-elem_corner.lo `test -f 'src/geom/elem_corner.C' || echo '$(srcdir)/'`src/geom/elem_corner.C + src/geom/libmesh_devel_la-elem_cutter.lo: src/geom/elem_cutter.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_devel_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_devel_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_devel_la-elem_cutter.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_devel_la-elem_cutter.Tpo -c -o src/geom/libmesh_devel_la-elem_cutter.lo `test -f 'src/geom/elem_cutter.C' || echo '$(srcdir)/'`src/geom/elem_cutter.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_devel_la-elem_cutter.Tpo src/geom/$(DEPDIR)/libmesh_devel_la-elem_cutter.Plo @@ -20930,6 +21008,13 @@ src/geom/libmesh_devel_la-face_tri7.lo: src/geom/face_tri7.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_devel_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_devel_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_devel_la-face_tri7.lo `test -f 'src/geom/face_tri7.C' || echo '$(srcdir)/'`src/geom/face_tri7.C +src/geom/libmesh_devel_la-intersection_tools.lo: src/geom/intersection_tools.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_devel_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_devel_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_devel_la-intersection_tools.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_devel_la-intersection_tools.Tpo -c -o src/geom/libmesh_devel_la-intersection_tools.lo `test -f 'src/geom/intersection_tools.C' || echo '$(srcdir)/'`src/geom/intersection_tools.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_devel_la-intersection_tools.Tpo src/geom/$(DEPDIR)/libmesh_devel_la-intersection_tools.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='src/geom/intersection_tools.C' object='src/geom/libmesh_devel_la-intersection_tools.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_devel_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_devel_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_devel_la-intersection_tools.lo `test -f 'src/geom/intersection_tools.C' || echo '$(srcdir)/'`src/geom/intersection_tools.C + src/geom/libmesh_devel_la-node.lo: src/geom/node.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_devel_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_devel_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_devel_la-node.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_devel_la-node.Tpo -c -o src/geom/libmesh_devel_la-node.lo `test -f 'src/geom/node.C' || echo '$(srcdir)/'`src/geom/node.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_devel_la-node.Tpo src/geom/$(DEPDIR)/libmesh_devel_la-node.Plo @@ -23912,6 +23997,13 @@ src/geom/libmesh_oprof_la-elem.lo: src/geom/elem.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_oprof_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_oprof_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_oprof_la-elem.lo `test -f 'src/geom/elem.C' || echo '$(srcdir)/'`src/geom/elem.C +src/geom/libmesh_oprof_la-elem_corner.lo: src/geom/elem_corner.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_oprof_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_oprof_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_oprof_la-elem_corner.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_oprof_la-elem_corner.Tpo -c -o src/geom/libmesh_oprof_la-elem_corner.lo `test -f 'src/geom/elem_corner.C' || echo '$(srcdir)/'`src/geom/elem_corner.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_oprof_la-elem_corner.Tpo src/geom/$(DEPDIR)/libmesh_oprof_la-elem_corner.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='src/geom/elem_corner.C' object='src/geom/libmesh_oprof_la-elem_corner.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_oprof_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_oprof_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_oprof_la-elem_corner.lo `test -f 'src/geom/elem_corner.C' || echo '$(srcdir)/'`src/geom/elem_corner.C + src/geom/libmesh_oprof_la-elem_cutter.lo: src/geom/elem_cutter.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_oprof_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_oprof_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_oprof_la-elem_cutter.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_oprof_la-elem_cutter.Tpo -c -o src/geom/libmesh_oprof_la-elem_cutter.lo `test -f 'src/geom/elem_cutter.C' || echo '$(srcdir)/'`src/geom/elem_cutter.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_oprof_la-elem_cutter.Tpo src/geom/$(DEPDIR)/libmesh_oprof_la-elem_cutter.Plo @@ -24052,6 +24144,13 @@ src/geom/libmesh_oprof_la-face_tri7.lo: src/geom/face_tri7.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_oprof_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_oprof_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_oprof_la-face_tri7.lo `test -f 'src/geom/face_tri7.C' || echo '$(srcdir)/'`src/geom/face_tri7.C +src/geom/libmesh_oprof_la-intersection_tools.lo: src/geom/intersection_tools.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_oprof_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_oprof_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_oprof_la-intersection_tools.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_oprof_la-intersection_tools.Tpo -c -o src/geom/libmesh_oprof_la-intersection_tools.lo `test -f 'src/geom/intersection_tools.C' || echo '$(srcdir)/'`src/geom/intersection_tools.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_oprof_la-intersection_tools.Tpo src/geom/$(DEPDIR)/libmesh_oprof_la-intersection_tools.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='src/geom/intersection_tools.C' object='src/geom/libmesh_oprof_la-intersection_tools.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_oprof_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_oprof_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_oprof_la-intersection_tools.lo `test -f 'src/geom/intersection_tools.C' || echo '$(srcdir)/'`src/geom/intersection_tools.C + src/geom/libmesh_oprof_la-node.lo: src/geom/node.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_oprof_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_oprof_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_oprof_la-node.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_oprof_la-node.Tpo -c -o src/geom/libmesh_oprof_la-node.lo `test -f 'src/geom/node.C' || echo '$(srcdir)/'`src/geom/node.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_oprof_la-node.Tpo src/geom/$(DEPDIR)/libmesh_oprof_la-node.Plo @@ -27034,6 +27133,13 @@ src/geom/libmesh_opt_la-elem.lo: src/geom/elem.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_opt_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_opt_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_opt_la-elem.lo `test -f 'src/geom/elem.C' || echo '$(srcdir)/'`src/geom/elem.C +src/geom/libmesh_opt_la-elem_corner.lo: src/geom/elem_corner.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_opt_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_opt_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_opt_la-elem_corner.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_opt_la-elem_corner.Tpo -c -o src/geom/libmesh_opt_la-elem_corner.lo `test -f 'src/geom/elem_corner.C' || echo '$(srcdir)/'`src/geom/elem_corner.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_opt_la-elem_corner.Tpo src/geom/$(DEPDIR)/libmesh_opt_la-elem_corner.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='src/geom/elem_corner.C' object='src/geom/libmesh_opt_la-elem_corner.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_opt_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_opt_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_opt_la-elem_corner.lo `test -f 'src/geom/elem_corner.C' || echo '$(srcdir)/'`src/geom/elem_corner.C + src/geom/libmesh_opt_la-elem_cutter.lo: src/geom/elem_cutter.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_opt_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_opt_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_opt_la-elem_cutter.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_opt_la-elem_cutter.Tpo -c -o src/geom/libmesh_opt_la-elem_cutter.lo `test -f 'src/geom/elem_cutter.C' || echo '$(srcdir)/'`src/geom/elem_cutter.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_opt_la-elem_cutter.Tpo src/geom/$(DEPDIR)/libmesh_opt_la-elem_cutter.Plo @@ -27174,6 +27280,13 @@ src/geom/libmesh_opt_la-face_tri7.lo: src/geom/face_tri7.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_opt_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_opt_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_opt_la-face_tri7.lo `test -f 'src/geom/face_tri7.C' || echo '$(srcdir)/'`src/geom/face_tri7.C +src/geom/libmesh_opt_la-intersection_tools.lo: src/geom/intersection_tools.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_opt_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_opt_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_opt_la-intersection_tools.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_opt_la-intersection_tools.Tpo -c -o src/geom/libmesh_opt_la-intersection_tools.lo `test -f 'src/geom/intersection_tools.C' || echo '$(srcdir)/'`src/geom/intersection_tools.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_opt_la-intersection_tools.Tpo src/geom/$(DEPDIR)/libmesh_opt_la-intersection_tools.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='src/geom/intersection_tools.C' object='src/geom/libmesh_opt_la-intersection_tools.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_opt_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_opt_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_opt_la-intersection_tools.lo `test -f 'src/geom/intersection_tools.C' || echo '$(srcdir)/'`src/geom/intersection_tools.C + src/geom/libmesh_opt_la-node.lo: src/geom/node.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_opt_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_opt_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_opt_la-node.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_opt_la-node.Tpo -c -o src/geom/libmesh_opt_la-node.lo `test -f 'src/geom/node.C' || echo '$(srcdir)/'`src/geom/node.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_opt_la-node.Tpo src/geom/$(DEPDIR)/libmesh_opt_la-node.Plo @@ -30156,6 +30269,13 @@ src/geom/libmesh_prof_la-elem.lo: src/geom/elem.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_prof_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_prof_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_prof_la-elem.lo `test -f 'src/geom/elem.C' || echo '$(srcdir)/'`src/geom/elem.C +src/geom/libmesh_prof_la-elem_corner.lo: src/geom/elem_corner.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_prof_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_prof_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_prof_la-elem_corner.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_prof_la-elem_corner.Tpo -c -o src/geom/libmesh_prof_la-elem_corner.lo `test -f 'src/geom/elem_corner.C' || echo '$(srcdir)/'`src/geom/elem_corner.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_prof_la-elem_corner.Tpo src/geom/$(DEPDIR)/libmesh_prof_la-elem_corner.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='src/geom/elem_corner.C' object='src/geom/libmesh_prof_la-elem_corner.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_prof_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_prof_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_prof_la-elem_corner.lo `test -f 'src/geom/elem_corner.C' || echo '$(srcdir)/'`src/geom/elem_corner.C + src/geom/libmesh_prof_la-elem_cutter.lo: src/geom/elem_cutter.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_prof_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_prof_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_prof_la-elem_cutter.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_prof_la-elem_cutter.Tpo -c -o src/geom/libmesh_prof_la-elem_cutter.lo `test -f 'src/geom/elem_cutter.C' || echo '$(srcdir)/'`src/geom/elem_cutter.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_prof_la-elem_cutter.Tpo src/geom/$(DEPDIR)/libmesh_prof_la-elem_cutter.Plo @@ -30296,6 +30416,13 @@ src/geom/libmesh_prof_la-face_tri7.lo: src/geom/face_tri7.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_prof_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_prof_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_prof_la-face_tri7.lo `test -f 'src/geom/face_tri7.C' || echo '$(srcdir)/'`src/geom/face_tri7.C +src/geom/libmesh_prof_la-intersection_tools.lo: src/geom/intersection_tools.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_prof_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_prof_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_prof_la-intersection_tools.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_prof_la-intersection_tools.Tpo -c -o src/geom/libmesh_prof_la-intersection_tools.lo `test -f 'src/geom/intersection_tools.C' || echo '$(srcdir)/'`src/geom/intersection_tools.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_prof_la-intersection_tools.Tpo src/geom/$(DEPDIR)/libmesh_prof_la-intersection_tools.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='src/geom/intersection_tools.C' object='src/geom/libmesh_prof_la-intersection_tools.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_prof_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_prof_la_CXXFLAGS) $(CXXFLAGS) -c -o src/geom/libmesh_prof_la-intersection_tools.lo `test -f 'src/geom/intersection_tools.C' || echo '$(srcdir)/'`src/geom/intersection_tools.C + src/geom/libmesh_prof_la-node.lo: src/geom/node.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libmesh_prof_la_CPPFLAGS) $(CPPFLAGS) $(libmesh_prof_la_CXXFLAGS) $(CXXFLAGS) -MT src/geom/libmesh_prof_la-node.lo -MD -MP -MF src/geom/$(DEPDIR)/libmesh_prof_la-node.Tpo -c -o src/geom/libmesh_prof_la-node.lo `test -f 'src/geom/node.C' || echo '$(srcdir)/'`src/geom/node.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) src/geom/$(DEPDIR)/libmesh_prof_la-node.Tpo src/geom/$(DEPDIR)/libmesh_prof_la-node.Plo @@ -34117,6 +34244,7 @@ distclean: distclean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-edge_edge4.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-edge_inf_edge2.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-elem.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-elem_corner.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-elem_cutter.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-elem_quality.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-elem_refinement.Plo @@ -34137,6 +34265,7 @@ distclean: distclean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-face_tri3_subdivision.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-face_tri6.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-face_tri7.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-intersection_tools.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-node.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-node_elem.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-plane.Plo @@ -34179,6 +34308,7 @@ distclean: distclean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-edge_edge4.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-edge_inf_edge2.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-elem.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-elem_corner.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-elem_cutter.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-elem_quality.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-elem_refinement.Plo @@ -34199,6 +34329,7 @@ distclean: distclean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-face_tri3_subdivision.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-face_tri6.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-face_tri7.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-intersection_tools.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-node.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-node_elem.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-plane.Plo @@ -34241,6 +34372,7 @@ distclean: distclean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-edge_edge4.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-edge_inf_edge2.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-elem.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-elem_corner.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-elem_cutter.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-elem_quality.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-elem_refinement.Plo @@ -34261,6 +34393,7 @@ distclean: distclean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-face_tri3_subdivision.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-face_tri6.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-face_tri7.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-intersection_tools.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-node.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-node_elem.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-plane.Plo @@ -34303,6 +34436,7 @@ distclean: distclean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-edge_edge4.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-edge_inf_edge2.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-elem.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-elem_corner.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-elem_cutter.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-elem_quality.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-elem_refinement.Plo @@ -34323,6 +34457,7 @@ distclean: distclean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-face_tri3_subdivision.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-face_tri6.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-face_tri7.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-intersection_tools.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-node.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-node_elem.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-plane.Plo @@ -34365,6 +34500,7 @@ distclean: distclean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-edge_edge4.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-edge_inf_edge2.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-elem.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-elem_corner.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-elem_cutter.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-elem_quality.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-elem_refinement.Plo @@ -34385,6 +34521,7 @@ distclean: distclean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-face_tri3_subdivision.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-face_tri6.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-face_tri7.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-intersection_tools.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-node.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-node_elem.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-plane.Plo @@ -36452,6 +36589,7 @@ maintainer-clean: maintainer-clean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-edge_edge4.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-edge_inf_edge2.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-elem.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-elem_corner.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-elem_cutter.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-elem_quality.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-elem_refinement.Plo @@ -36472,6 +36610,7 @@ maintainer-clean: maintainer-clean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-face_tri3_subdivision.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-face_tri6.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-face_tri7.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-intersection_tools.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-node.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-node_elem.Plo -rm -f src/geom/$(DEPDIR)/libmesh_dbg_la-plane.Plo @@ -36514,6 +36653,7 @@ maintainer-clean: maintainer-clean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-edge_edge4.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-edge_inf_edge2.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-elem.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-elem_corner.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-elem_cutter.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-elem_quality.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-elem_refinement.Plo @@ -36534,6 +36674,7 @@ maintainer-clean: maintainer-clean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-face_tri3_subdivision.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-face_tri6.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-face_tri7.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-intersection_tools.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-node.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-node_elem.Plo -rm -f src/geom/$(DEPDIR)/libmesh_devel_la-plane.Plo @@ -36576,6 +36717,7 @@ maintainer-clean: maintainer-clean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-edge_edge4.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-edge_inf_edge2.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-elem.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-elem_corner.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-elem_cutter.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-elem_quality.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-elem_refinement.Plo @@ -36596,6 +36738,7 @@ maintainer-clean: maintainer-clean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-face_tri3_subdivision.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-face_tri6.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-face_tri7.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-intersection_tools.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-node.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-node_elem.Plo -rm -f src/geom/$(DEPDIR)/libmesh_oprof_la-plane.Plo @@ -36638,6 +36781,7 @@ maintainer-clean: maintainer-clean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-edge_edge4.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-edge_inf_edge2.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-elem.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-elem_corner.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-elem_cutter.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-elem_quality.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-elem_refinement.Plo @@ -36658,6 +36802,7 @@ maintainer-clean: maintainer-clean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-face_tri3_subdivision.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-face_tri6.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-face_tri7.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-intersection_tools.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-node.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-node_elem.Plo -rm -f src/geom/$(DEPDIR)/libmesh_opt_la-plane.Plo @@ -36700,6 +36845,7 @@ maintainer-clean: maintainer-clean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-edge_edge4.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-edge_inf_edge2.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-elem.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-elem_corner.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-elem_cutter.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-elem_quality.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-elem_refinement.Plo @@ -36720,6 +36866,7 @@ maintainer-clean: maintainer-clean-recursive -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-face_tri3_subdivision.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-face_tri6.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-face_tri7.Plo + -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-intersection_tools.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-node.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-node_elem.Plo -rm -f src/geom/$(DEPDIR)/libmesh_prof_la-plane.Plo diff --git a/include/Makefile.in b/include/Makefile.in index 328648c0577..c31c7304227 100644 --- a/include/Makefile.in +++ b/include/Makefile.in @@ -729,6 +729,7 @@ include_HEADERS = \ geom/edge_edge4.h \ geom/edge_inf_edge2.h \ geom/elem.h \ + geom/elem_corner.h \ geom/elem_cutter.h \ geom/elem_hash.h \ geom/elem_internal.h \ @@ -751,6 +752,7 @@ include_HEADERS = \ geom/face_tri3_subdivision.h \ geom/face_tri6.h \ geom/face_tri7.h \ + geom/intersection_tools.h \ geom/node.h \ geom/node_elem.h \ geom/node_range.h \ diff --git a/include/include_HEADERS b/include/include_HEADERS index 85b43d9d4f1..6f2a7677613 100644 --- a/include/include_HEADERS +++ b/include/include_HEADERS @@ -139,6 +139,7 @@ include_HEADERS = \ geom/edge_edge4.h \ geom/edge_inf_edge2.h \ geom/elem.h \ + geom/elem_corner.h \ geom/elem_cutter.h \ geom/elem_hash.h \ geom/elem_internal.h \ @@ -161,6 +162,7 @@ include_HEADERS = \ geom/face_tri3_subdivision.h \ geom/face_tri6.h \ geom/face_tri7.h \ + geom/intersection_tools.h \ geom/node.h \ geom/node_elem.h \ geom/node_range.h \ diff --git a/include/libmesh/Makefile.am b/include/libmesh/Makefile.am index 2d49e348066..6f0f85b51ad 100644 --- a/include/libmesh/Makefile.am +++ b/include/libmesh/Makefile.am @@ -129,6 +129,7 @@ BUILT_SOURCES = \ edge_edge4.h \ edge_inf_edge2.h \ elem.h \ + elem_corner.h \ elem_cutter.h \ elem_hash.h \ elem_internal.h \ @@ -151,6 +152,7 @@ BUILT_SOURCES = \ face_tri3_subdivision.h \ face_tri6.h \ face_tri7.h \ + intersection_tools.h \ node.h \ node_elem.h \ node_range.h \ @@ -947,6 +949,9 @@ edge_inf_edge2.h: $(top_srcdir)/include/geom/edge_inf_edge2.h elem.h: $(top_srcdir)/include/geom/elem.h $(AM_V_GEN)rm -f $@ && $(LN_S) -f $< $@ +elem_corner.h: $(top_srcdir)/include/geom/elem_corner.h + $(AM_V_GEN)rm -f $@ && $(LN_S) -f $< $@ + elem_cutter.h: $(top_srcdir)/include/geom/elem_cutter.h $(AM_V_GEN)rm -f $@ && $(LN_S) -f $< $@ @@ -1013,6 +1018,9 @@ face_tri6.h: $(top_srcdir)/include/geom/face_tri6.h face_tri7.h: $(top_srcdir)/include/geom/face_tri7.h $(AM_V_GEN)rm -f $@ && $(LN_S) -f $< $@ +intersection_tools.h: $(top_srcdir)/include/geom/intersection_tools.h + $(AM_V_GEN)rm -f $@ && $(LN_S) -f $< $@ + node.h: $(top_srcdir)/include/geom/node.h $(AM_V_GEN)rm -f $@ && $(LN_S) -f $< $@ diff --git a/include/libmesh/Makefile.in b/include/libmesh/Makefile.in index b1b04d126ea..032f07d7980 100644 --- a/include/libmesh/Makefile.in +++ b/include/libmesh/Makefile.in @@ -547,15 +547,16 @@ BUILT_SOURCES = auto_ptr.h default_coupling.h dirichlet_boundaries.h \ cell_pyramid5.h cell_tet.h cell_tet10.h cell_tet14.h \ cell_tet4.h compare_elems_by_level.h edge.h edge_edge2.h \ edge_edge3.h edge_edge4.h edge_inf_edge2.h elem.h \ - elem_cutter.h elem_hash.h elem_internal.h elem_quality.h \ - elem_range.h elem_side_builder.h face.h face_inf_quad.h \ - face_inf_quad4.h face_inf_quad6.h face_quad.h face_quad4.h \ - face_quad4_shell.h face_quad8.h face_quad8_shell.h \ - face_quad9.h face_tri.h face_tri3.h face_tri3_shell.h \ - face_tri3_subdivision.h face_tri6.h face_tri7.h node.h \ - node_elem.h node_range.h plane.h point.h reference_elem.h \ - remote_elem.h side.h sphere.h stored_range.h surface.h \ - abaqus_io.h boundary_info.h boundary_mesh.h checkpoint_io.h \ + elem_corner.h elem_cutter.h elem_hash.h elem_internal.h \ + elem_quality.h elem_range.h elem_side_builder.h face.h \ + face_inf_quad.h face_inf_quad4.h face_inf_quad6.h face_quad.h \ + face_quad4.h face_quad4_shell.h face_quad8.h \ + face_quad8_shell.h face_quad9.h face_tri.h face_tri3.h \ + face_tri3_shell.h face_tri3_subdivision.h face_tri6.h \ + face_tri7.h intersection_tools.h node.h node_elem.h \ + node_range.h plane.h point.h reference_elem.h remote_elem.h \ + side.h sphere.h stored_range.h surface.h abaqus_io.h \ + boundary_info.h boundary_mesh.h checkpoint_io.h \ distributed_mesh.h dyna_io.h ensight_io.h exodusII_io.h \ exodusII_io_helper.h exodus_header_info.h fro_io.h gmsh_io.h \ gmv_io.h gnuplot_io.h inf_elem_builder.h matlab_io.h \ @@ -1282,6 +1283,9 @@ edge_inf_edge2.h: $(top_srcdir)/include/geom/edge_inf_edge2.h elem.h: $(top_srcdir)/include/geom/elem.h $(AM_V_GEN)rm -f $@ && $(LN_S) -f $< $@ +elem_corner.h: $(top_srcdir)/include/geom/elem_corner.h + $(AM_V_GEN)rm -f $@ && $(LN_S) -f $< $@ + elem_cutter.h: $(top_srcdir)/include/geom/elem_cutter.h $(AM_V_GEN)rm -f $@ && $(LN_S) -f $< $@ @@ -1348,6 +1352,9 @@ face_tri6.h: $(top_srcdir)/include/geom/face_tri6.h face_tri7.h: $(top_srcdir)/include/geom/face_tri7.h $(AM_V_GEN)rm -f $@ && $(LN_S) -f $< $@ +intersection_tools.h: $(top_srcdir)/include/geom/intersection_tools.h + $(AM_V_GEN)rm -f $@ && $(LN_S) -f $< $@ + node.h: $(top_srcdir)/include/geom/node.h $(AM_V_GEN)rm -f $@ && $(LN_S) -f $< $@ diff --git a/src/libmesh_SOURCES b/src/libmesh_SOURCES index 2b2b05a2b7c..6e982d1678c 100644 --- a/src/libmesh_SOURCES +++ b/src/libmesh_SOURCES @@ -152,6 +152,7 @@ libmesh_SOURCES = \ src/geom/edge_edge4.C \ src/geom/edge_inf_edge2.C \ src/geom/elem.C \ + src/geom/elem_corner.C \ src/geom/elem_cutter.C \ src/geom/elem_quality.C \ src/geom/elem_refinement.C \ @@ -172,6 +173,7 @@ libmesh_SOURCES = \ src/geom/face_tri3_subdivision.C \ src/geom/face_tri6.C \ src/geom/face_tri7.C \ + src/geom/intersection_tools.C \ src/geom/node.C \ src/geom/node_elem.C \ src/geom/plane.C \ diff --git a/tests/Makefile.am b/tests/Makefile.am index e8e8e7d1a0c..8cc0290a91e 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -45,7 +45,9 @@ unit_tests_sources = \ fe/dual_shape_verification_test.C \ geom/bbox_test.C \ geom/edge_test.C \ + geom/elem_corner_test.C \ geom/elem_test.C \ + geom/intersection_tools_test.C \ geom/node_test.C \ geom/point_test.C \ geom/point_test.h \ diff --git a/tests/Makefile.in b/tests/Makefile.in index f298e558e57..b42e29d947f 100644 --- a/tests/Makefile.in +++ b/tests/Makefile.in @@ -206,7 +206,8 @@ am__unit_tests_dbg_SOURCES_DIST = driver.C libmesh_cppunit.h \ fe/fe_rational_map.C fe/fe_rational_test.C fe/fe_side_test.C \ fe/fe_szabab_test.C fe/fe_test.h fe/fe_xyz_test.C \ fe/dual_shape_verification_test.C geom/bbox_test.C \ - geom/edge_test.C geom/elem_test.C geom/node_test.C \ + geom/edge_test.C geom/elem_corner_test.C geom/elem_test.C \ + geom/intersection_tools_test.C geom/node_test.C \ geom/point_test.C geom/point_test.h geom/side_test.C \ geom/volume_test.C geom/which_node_am_i_test.C \ mesh/all_second_order.C mesh/all_tri.C mesh/distort.C \ @@ -293,7 +294,9 @@ am__objects_3 = unit_tests_dbg-driver.$(OBJEXT) \ fe/unit_tests_dbg-dual_shape_verification_test.$(OBJEXT) \ geom/unit_tests_dbg-bbox_test.$(OBJEXT) \ geom/unit_tests_dbg-edge_test.$(OBJEXT) \ + geom/unit_tests_dbg-elem_corner_test.$(OBJEXT) \ geom/unit_tests_dbg-elem_test.$(OBJEXT) \ + geom/unit_tests_dbg-intersection_tools_test.$(OBJEXT) \ geom/unit_tests_dbg-node_test.$(OBJEXT) \ geom/unit_tests_dbg-point_test.$(OBJEXT) \ geom/unit_tests_dbg-side_test.$(OBJEXT) \ @@ -395,7 +398,8 @@ am__unit_tests_devel_SOURCES_DIST = driver.C libmesh_cppunit.h \ fe/fe_rational_map.C fe/fe_rational_test.C fe/fe_side_test.C \ fe/fe_szabab_test.C fe/fe_test.h fe/fe_xyz_test.C \ fe/dual_shape_verification_test.C geom/bbox_test.C \ - geom/edge_test.C geom/elem_test.C geom/node_test.C \ + geom/edge_test.C geom/elem_corner_test.C geom/elem_test.C \ + geom/intersection_tools_test.C geom/node_test.C \ geom/point_test.C geom/point_test.h geom/side_test.C \ geom/volume_test.C geom/which_node_am_i_test.C \ mesh/all_second_order.C mesh/all_tri.C mesh/distort.C \ @@ -480,7 +484,9 @@ am__objects_5 = unit_tests_devel-driver.$(OBJEXT) \ fe/unit_tests_devel-dual_shape_verification_test.$(OBJEXT) \ geom/unit_tests_devel-bbox_test.$(OBJEXT) \ geom/unit_tests_devel-edge_test.$(OBJEXT) \ + geom/unit_tests_devel-elem_corner_test.$(OBJEXT) \ geom/unit_tests_devel-elem_test.$(OBJEXT) \ + geom/unit_tests_devel-intersection_tools_test.$(OBJEXT) \ geom/unit_tests_devel-node_test.$(OBJEXT) \ geom/unit_tests_devel-point_test.$(OBJEXT) \ geom/unit_tests_devel-side_test.$(OBJEXT) \ @@ -578,7 +584,8 @@ am__unit_tests_oprof_SOURCES_DIST = driver.C libmesh_cppunit.h \ fe/fe_rational_map.C fe/fe_rational_test.C fe/fe_side_test.C \ fe/fe_szabab_test.C fe/fe_test.h fe/fe_xyz_test.C \ fe/dual_shape_verification_test.C geom/bbox_test.C \ - geom/edge_test.C geom/elem_test.C geom/node_test.C \ + geom/edge_test.C geom/elem_corner_test.C geom/elem_test.C \ + geom/intersection_tools_test.C geom/node_test.C \ geom/point_test.C geom/point_test.h geom/side_test.C \ geom/volume_test.C geom/which_node_am_i_test.C \ mesh/all_second_order.C mesh/all_tri.C mesh/distort.C \ @@ -663,7 +670,9 @@ am__objects_7 = unit_tests_oprof-driver.$(OBJEXT) \ fe/unit_tests_oprof-dual_shape_verification_test.$(OBJEXT) \ geom/unit_tests_oprof-bbox_test.$(OBJEXT) \ geom/unit_tests_oprof-edge_test.$(OBJEXT) \ + geom/unit_tests_oprof-elem_corner_test.$(OBJEXT) \ geom/unit_tests_oprof-elem_test.$(OBJEXT) \ + geom/unit_tests_oprof-intersection_tools_test.$(OBJEXT) \ geom/unit_tests_oprof-node_test.$(OBJEXT) \ geom/unit_tests_oprof-point_test.$(OBJEXT) \ geom/unit_tests_oprof-side_test.$(OBJEXT) \ @@ -761,7 +770,8 @@ am__unit_tests_opt_SOURCES_DIST = driver.C libmesh_cppunit.h \ fe/fe_rational_map.C fe/fe_rational_test.C fe/fe_side_test.C \ fe/fe_szabab_test.C fe/fe_test.h fe/fe_xyz_test.C \ fe/dual_shape_verification_test.C geom/bbox_test.C \ - geom/edge_test.C geom/elem_test.C geom/node_test.C \ + geom/edge_test.C geom/elem_corner_test.C geom/elem_test.C \ + geom/intersection_tools_test.C geom/node_test.C \ geom/point_test.C geom/point_test.h geom/side_test.C \ geom/volume_test.C geom/which_node_am_i_test.C \ mesh/all_second_order.C mesh/all_tri.C mesh/distort.C \ @@ -846,7 +856,9 @@ am__objects_9 = unit_tests_opt-driver.$(OBJEXT) \ fe/unit_tests_opt-dual_shape_verification_test.$(OBJEXT) \ geom/unit_tests_opt-bbox_test.$(OBJEXT) \ geom/unit_tests_opt-edge_test.$(OBJEXT) \ + geom/unit_tests_opt-elem_corner_test.$(OBJEXT) \ geom/unit_tests_opt-elem_test.$(OBJEXT) \ + geom/unit_tests_opt-intersection_tools_test.$(OBJEXT) \ geom/unit_tests_opt-node_test.$(OBJEXT) \ geom/unit_tests_opt-point_test.$(OBJEXT) \ geom/unit_tests_opt-side_test.$(OBJEXT) \ @@ -944,7 +956,8 @@ am__unit_tests_prof_SOURCES_DIST = driver.C libmesh_cppunit.h \ fe/fe_rational_map.C fe/fe_rational_test.C fe/fe_side_test.C \ fe/fe_szabab_test.C fe/fe_test.h fe/fe_xyz_test.C \ fe/dual_shape_verification_test.C geom/bbox_test.C \ - geom/edge_test.C geom/elem_test.C geom/node_test.C \ + geom/edge_test.C geom/elem_corner_test.C geom/elem_test.C \ + geom/intersection_tools_test.C geom/node_test.C \ geom/point_test.C geom/point_test.h geom/side_test.C \ geom/volume_test.C geom/which_node_am_i_test.C \ mesh/all_second_order.C mesh/all_tri.C mesh/distort.C \ @@ -1029,7 +1042,9 @@ am__objects_11 = unit_tests_prof-driver.$(OBJEXT) \ fe/unit_tests_prof-dual_shape_verification_test.$(OBJEXT) \ geom/unit_tests_prof-bbox_test.$(OBJEXT) \ geom/unit_tests_prof-edge_test.$(OBJEXT) \ + geom/unit_tests_prof-elem_corner_test.$(OBJEXT) \ geom/unit_tests_prof-elem_test.$(OBJEXT) \ + geom/unit_tests_prof-intersection_tools_test.$(OBJEXT) \ geom/unit_tests_prof-node_test.$(OBJEXT) \ geom/unit_tests_prof-point_test.$(OBJEXT) \ geom/unit_tests_prof-side_test.$(OBJEXT) \ @@ -1246,7 +1261,9 @@ am__depfiles_remade = ./$(DEPDIR)/unit_tests_dbg-driver.Po \ fparser/$(DEPDIR)/unit_tests_prof-autodiff.Po \ geom/$(DEPDIR)/unit_tests_dbg-bbox_test.Po \ geom/$(DEPDIR)/unit_tests_dbg-edge_test.Po \ + geom/$(DEPDIR)/unit_tests_dbg-elem_corner_test.Po \ geom/$(DEPDIR)/unit_tests_dbg-elem_test.Po \ + geom/$(DEPDIR)/unit_tests_dbg-intersection_tools_test.Po \ geom/$(DEPDIR)/unit_tests_dbg-node_test.Po \ geom/$(DEPDIR)/unit_tests_dbg-point_test.Po \ geom/$(DEPDIR)/unit_tests_dbg-side_test.Po \ @@ -1254,7 +1271,9 @@ am__depfiles_remade = ./$(DEPDIR)/unit_tests_dbg-driver.Po \ geom/$(DEPDIR)/unit_tests_dbg-which_node_am_i_test.Po \ geom/$(DEPDIR)/unit_tests_devel-bbox_test.Po \ geom/$(DEPDIR)/unit_tests_devel-edge_test.Po \ + geom/$(DEPDIR)/unit_tests_devel-elem_corner_test.Po \ geom/$(DEPDIR)/unit_tests_devel-elem_test.Po \ + geom/$(DEPDIR)/unit_tests_devel-intersection_tools_test.Po \ geom/$(DEPDIR)/unit_tests_devel-node_test.Po \ geom/$(DEPDIR)/unit_tests_devel-point_test.Po \ geom/$(DEPDIR)/unit_tests_devel-side_test.Po \ @@ -1262,7 +1281,9 @@ am__depfiles_remade = ./$(DEPDIR)/unit_tests_dbg-driver.Po \ geom/$(DEPDIR)/unit_tests_devel-which_node_am_i_test.Po \ geom/$(DEPDIR)/unit_tests_oprof-bbox_test.Po \ geom/$(DEPDIR)/unit_tests_oprof-edge_test.Po \ + geom/$(DEPDIR)/unit_tests_oprof-elem_corner_test.Po \ geom/$(DEPDIR)/unit_tests_oprof-elem_test.Po \ + geom/$(DEPDIR)/unit_tests_oprof-intersection_tools_test.Po \ geom/$(DEPDIR)/unit_tests_oprof-node_test.Po \ geom/$(DEPDIR)/unit_tests_oprof-point_test.Po \ geom/$(DEPDIR)/unit_tests_oprof-side_test.Po \ @@ -1270,7 +1291,9 @@ am__depfiles_remade = ./$(DEPDIR)/unit_tests_dbg-driver.Po \ geom/$(DEPDIR)/unit_tests_oprof-which_node_am_i_test.Po \ geom/$(DEPDIR)/unit_tests_opt-bbox_test.Po \ geom/$(DEPDIR)/unit_tests_opt-edge_test.Po \ + geom/$(DEPDIR)/unit_tests_opt-elem_corner_test.Po \ geom/$(DEPDIR)/unit_tests_opt-elem_test.Po \ + geom/$(DEPDIR)/unit_tests_opt-intersection_tools_test.Po \ geom/$(DEPDIR)/unit_tests_opt-node_test.Po \ geom/$(DEPDIR)/unit_tests_opt-point_test.Po \ geom/$(DEPDIR)/unit_tests_opt-side_test.Po \ @@ -1278,7 +1301,9 @@ am__depfiles_remade = ./$(DEPDIR)/unit_tests_dbg-driver.Po \ geom/$(DEPDIR)/unit_tests_opt-which_node_am_i_test.Po \ geom/$(DEPDIR)/unit_tests_prof-bbox_test.Po \ geom/$(DEPDIR)/unit_tests_prof-edge_test.Po \ + geom/$(DEPDIR)/unit_tests_prof-elem_corner_test.Po \ geom/$(DEPDIR)/unit_tests_prof-elem_test.Po \ + geom/$(DEPDIR)/unit_tests_prof-intersection_tools_test.Po \ geom/$(DEPDIR)/unit_tests_prof-node_test.Po \ geom/$(DEPDIR)/unit_tests_prof-point_test.Po \ geom/$(DEPDIR)/unit_tests_prof-side_test.Po \ @@ -2106,7 +2131,8 @@ unit_tests_sources = driver.C libmesh_cppunit.h stream_redirector.h \ fe/fe_rational_map.C fe/fe_rational_test.C fe/fe_side_test.C \ fe/fe_szabab_test.C fe/fe_test.h fe/fe_xyz_test.C \ fe/dual_shape_verification_test.C geom/bbox_test.C \ - geom/edge_test.C geom/elem_test.C geom/node_test.C \ + geom/edge_test.C geom/elem_corner_test.C geom/elem_test.C \ + geom/intersection_tools_test.C geom/node_test.C \ geom/point_test.C geom/point_test.h geom/side_test.C \ geom/volume_test.C geom/which_node_am_i_test.C \ mesh/all_second_order.C mesh/all_tri.C mesh/distort.C \ @@ -2339,8 +2365,12 @@ geom/unit_tests_dbg-bbox_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_dbg-edge_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) +geom/unit_tests_dbg-elem_corner_test.$(OBJEXT): geom/$(am__dirstamp) \ + geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_dbg-elem_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) +geom/unit_tests_dbg-intersection_tools_test.$(OBJEXT): \ + geom/$(am__dirstamp) geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_dbg-node_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_dbg-point_test.$(OBJEXT): geom/$(am__dirstamp) \ @@ -2607,8 +2637,12 @@ geom/unit_tests_devel-bbox_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_devel-edge_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) +geom/unit_tests_devel-elem_corner_test.$(OBJEXT): \ + geom/$(am__dirstamp) geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_devel-elem_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) +geom/unit_tests_devel-intersection_tools_test.$(OBJEXT): \ + geom/$(am__dirstamp) geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_devel-node_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_devel-point_test.$(OBJEXT): geom/$(am__dirstamp) \ @@ -2821,8 +2855,12 @@ geom/unit_tests_oprof-bbox_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_oprof-edge_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) +geom/unit_tests_oprof-elem_corner_test.$(OBJEXT): \ + geom/$(am__dirstamp) geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_oprof-elem_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) +geom/unit_tests_oprof-intersection_tools_test.$(OBJEXT): \ + geom/$(am__dirstamp) geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_oprof-node_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_oprof-point_test.$(OBJEXT): geom/$(am__dirstamp) \ @@ -3035,8 +3073,12 @@ geom/unit_tests_opt-bbox_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_opt-edge_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) +geom/unit_tests_opt-elem_corner_test.$(OBJEXT): geom/$(am__dirstamp) \ + geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_opt-elem_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) +geom/unit_tests_opt-intersection_tools_test.$(OBJEXT): \ + geom/$(am__dirstamp) geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_opt-node_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_opt-point_test.$(OBJEXT): geom/$(am__dirstamp) \ @@ -3249,8 +3291,12 @@ geom/unit_tests_prof-bbox_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_prof-edge_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) +geom/unit_tests_prof-elem_corner_test.$(OBJEXT): geom/$(am__dirstamp) \ + geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_prof-elem_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) +geom/unit_tests_prof-intersection_tools_test.$(OBJEXT): \ + geom/$(am__dirstamp) geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_prof-node_test.$(OBJEXT): geom/$(am__dirstamp) \ geom/$(DEPDIR)/$(am__dirstamp) geom/unit_tests_prof-point_test.$(OBJEXT): geom/$(am__dirstamp) \ @@ -3553,7 +3599,9 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@fparser/$(DEPDIR)/unit_tests_prof-autodiff.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_dbg-bbox_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_dbg-edge_test.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_dbg-elem_corner_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_dbg-elem_test.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_dbg-intersection_tools_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_dbg-node_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_dbg-point_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_dbg-side_test.Po@am__quote@ # am--include-marker @@ -3561,7 +3609,9 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_dbg-which_node_am_i_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_devel-bbox_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_devel-edge_test.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_devel-elem_corner_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_devel-elem_test.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_devel-intersection_tools_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_devel-node_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_devel-point_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_devel-side_test.Po@am__quote@ # am--include-marker @@ -3569,7 +3619,9 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_devel-which_node_am_i_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_oprof-bbox_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_oprof-edge_test.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_oprof-elem_corner_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_oprof-elem_test.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_oprof-intersection_tools_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_oprof-node_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_oprof-point_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_oprof-side_test.Po@am__quote@ # am--include-marker @@ -3577,7 +3629,9 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_oprof-which_node_am_i_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_opt-bbox_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_opt-edge_test.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_opt-elem_corner_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_opt-elem_test.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_opt-intersection_tools_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_opt-node_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_opt-point_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_opt-side_test.Po@am__quote@ # am--include-marker @@ -3585,7 +3639,9 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_opt-which_node_am_i_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_prof-bbox_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_prof-edge_test.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_prof-elem_corner_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_prof-elem_test.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_prof-intersection_tools_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_prof-node_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_prof-point_test.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@geom/$(DEPDIR)/unit_tests_prof-side_test.Po@am__quote@ # am--include-marker @@ -4313,6 +4369,20 @@ geom/unit_tests_dbg-edge_test.obj: geom/edge_test.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_dbg_CPPFLAGS) $(CPPFLAGS) $(unit_tests_dbg_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_dbg-edge_test.obj `if test -f 'geom/edge_test.C'; then $(CYGPATH_W) 'geom/edge_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/edge_test.C'; fi` +geom/unit_tests_dbg-elem_corner_test.o: geom/elem_corner_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_dbg_CPPFLAGS) $(CPPFLAGS) $(unit_tests_dbg_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_dbg-elem_corner_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_dbg-elem_corner_test.Tpo -c -o geom/unit_tests_dbg-elem_corner_test.o `test -f 'geom/elem_corner_test.C' || echo '$(srcdir)/'`geom/elem_corner_test.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_dbg-elem_corner_test.Tpo geom/$(DEPDIR)/unit_tests_dbg-elem_corner_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/elem_corner_test.C' object='geom/unit_tests_dbg-elem_corner_test.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_dbg_CPPFLAGS) $(CPPFLAGS) $(unit_tests_dbg_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_dbg-elem_corner_test.o `test -f 'geom/elem_corner_test.C' || echo '$(srcdir)/'`geom/elem_corner_test.C + +geom/unit_tests_dbg-elem_corner_test.obj: geom/elem_corner_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_dbg_CPPFLAGS) $(CPPFLAGS) $(unit_tests_dbg_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_dbg-elem_corner_test.obj -MD -MP -MF geom/$(DEPDIR)/unit_tests_dbg-elem_corner_test.Tpo -c -o geom/unit_tests_dbg-elem_corner_test.obj `if test -f 'geom/elem_corner_test.C'; then $(CYGPATH_W) 'geom/elem_corner_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/elem_corner_test.C'; fi` +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_dbg-elem_corner_test.Tpo geom/$(DEPDIR)/unit_tests_dbg-elem_corner_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/elem_corner_test.C' object='geom/unit_tests_dbg-elem_corner_test.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_dbg_CPPFLAGS) $(CPPFLAGS) $(unit_tests_dbg_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_dbg-elem_corner_test.obj `if test -f 'geom/elem_corner_test.C'; then $(CYGPATH_W) 'geom/elem_corner_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/elem_corner_test.C'; fi` + geom/unit_tests_dbg-elem_test.o: geom/elem_test.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_dbg_CPPFLAGS) $(CPPFLAGS) $(unit_tests_dbg_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_dbg-elem_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_dbg-elem_test.Tpo -c -o geom/unit_tests_dbg-elem_test.o `test -f 'geom/elem_test.C' || echo '$(srcdir)/'`geom/elem_test.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_dbg-elem_test.Tpo geom/$(DEPDIR)/unit_tests_dbg-elem_test.Po @@ -4327,6 +4397,20 @@ geom/unit_tests_dbg-elem_test.obj: geom/elem_test.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_dbg_CPPFLAGS) $(CPPFLAGS) $(unit_tests_dbg_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_dbg-elem_test.obj `if test -f 'geom/elem_test.C'; then $(CYGPATH_W) 'geom/elem_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/elem_test.C'; fi` +geom/unit_tests_dbg-intersection_tools_test.o: geom/intersection_tools_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_dbg_CPPFLAGS) $(CPPFLAGS) $(unit_tests_dbg_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_dbg-intersection_tools_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_dbg-intersection_tools_test.Tpo -c -o geom/unit_tests_dbg-intersection_tools_test.o `test -f 'geom/intersection_tools_test.C' || echo '$(srcdir)/'`geom/intersection_tools_test.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_dbg-intersection_tools_test.Tpo geom/$(DEPDIR)/unit_tests_dbg-intersection_tools_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/intersection_tools_test.C' object='geom/unit_tests_dbg-intersection_tools_test.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_dbg_CPPFLAGS) $(CPPFLAGS) $(unit_tests_dbg_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_dbg-intersection_tools_test.o `test -f 'geom/intersection_tools_test.C' || echo '$(srcdir)/'`geom/intersection_tools_test.C + +geom/unit_tests_dbg-intersection_tools_test.obj: geom/intersection_tools_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_dbg_CPPFLAGS) $(CPPFLAGS) $(unit_tests_dbg_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_dbg-intersection_tools_test.obj -MD -MP -MF geom/$(DEPDIR)/unit_tests_dbg-intersection_tools_test.Tpo -c -o geom/unit_tests_dbg-intersection_tools_test.obj `if test -f 'geom/intersection_tools_test.C'; then $(CYGPATH_W) 'geom/intersection_tools_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/intersection_tools_test.C'; fi` +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_dbg-intersection_tools_test.Tpo geom/$(DEPDIR)/unit_tests_dbg-intersection_tools_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/intersection_tools_test.C' object='geom/unit_tests_dbg-intersection_tools_test.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_dbg_CPPFLAGS) $(CPPFLAGS) $(unit_tests_dbg_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_dbg-intersection_tools_test.obj `if test -f 'geom/intersection_tools_test.C'; then $(CYGPATH_W) 'geom/intersection_tools_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/intersection_tools_test.C'; fi` + geom/unit_tests_dbg-node_test.o: geom/node_test.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_dbg_CPPFLAGS) $(CPPFLAGS) $(unit_tests_dbg_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_dbg-node_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_dbg-node_test.Tpo -c -o geom/unit_tests_dbg-node_test.o `test -f 'geom/node_test.C' || echo '$(srcdir)/'`geom/node_test.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_dbg-node_test.Tpo geom/$(DEPDIR)/unit_tests_dbg-node_test.Po @@ -5741,6 +5825,20 @@ geom/unit_tests_devel-edge_test.obj: geom/edge_test.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_devel_CPPFLAGS) $(CPPFLAGS) $(unit_tests_devel_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_devel-edge_test.obj `if test -f 'geom/edge_test.C'; then $(CYGPATH_W) 'geom/edge_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/edge_test.C'; fi` +geom/unit_tests_devel-elem_corner_test.o: geom/elem_corner_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_devel_CPPFLAGS) $(CPPFLAGS) $(unit_tests_devel_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_devel-elem_corner_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_devel-elem_corner_test.Tpo -c -o geom/unit_tests_devel-elem_corner_test.o `test -f 'geom/elem_corner_test.C' || echo '$(srcdir)/'`geom/elem_corner_test.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_devel-elem_corner_test.Tpo geom/$(DEPDIR)/unit_tests_devel-elem_corner_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/elem_corner_test.C' object='geom/unit_tests_devel-elem_corner_test.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_devel_CPPFLAGS) $(CPPFLAGS) $(unit_tests_devel_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_devel-elem_corner_test.o `test -f 'geom/elem_corner_test.C' || echo '$(srcdir)/'`geom/elem_corner_test.C + +geom/unit_tests_devel-elem_corner_test.obj: geom/elem_corner_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_devel_CPPFLAGS) $(CPPFLAGS) $(unit_tests_devel_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_devel-elem_corner_test.obj -MD -MP -MF geom/$(DEPDIR)/unit_tests_devel-elem_corner_test.Tpo -c -o geom/unit_tests_devel-elem_corner_test.obj `if test -f 'geom/elem_corner_test.C'; then $(CYGPATH_W) 'geom/elem_corner_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/elem_corner_test.C'; fi` +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_devel-elem_corner_test.Tpo geom/$(DEPDIR)/unit_tests_devel-elem_corner_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/elem_corner_test.C' object='geom/unit_tests_devel-elem_corner_test.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_devel_CPPFLAGS) $(CPPFLAGS) $(unit_tests_devel_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_devel-elem_corner_test.obj `if test -f 'geom/elem_corner_test.C'; then $(CYGPATH_W) 'geom/elem_corner_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/elem_corner_test.C'; fi` + geom/unit_tests_devel-elem_test.o: geom/elem_test.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_devel_CPPFLAGS) $(CPPFLAGS) $(unit_tests_devel_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_devel-elem_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_devel-elem_test.Tpo -c -o geom/unit_tests_devel-elem_test.o `test -f 'geom/elem_test.C' || echo '$(srcdir)/'`geom/elem_test.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_devel-elem_test.Tpo geom/$(DEPDIR)/unit_tests_devel-elem_test.Po @@ -5755,6 +5853,20 @@ geom/unit_tests_devel-elem_test.obj: geom/elem_test.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_devel_CPPFLAGS) $(CPPFLAGS) $(unit_tests_devel_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_devel-elem_test.obj `if test -f 'geom/elem_test.C'; then $(CYGPATH_W) 'geom/elem_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/elem_test.C'; fi` +geom/unit_tests_devel-intersection_tools_test.o: geom/intersection_tools_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_devel_CPPFLAGS) $(CPPFLAGS) $(unit_tests_devel_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_devel-intersection_tools_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_devel-intersection_tools_test.Tpo -c -o geom/unit_tests_devel-intersection_tools_test.o `test -f 'geom/intersection_tools_test.C' || echo '$(srcdir)/'`geom/intersection_tools_test.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_devel-intersection_tools_test.Tpo geom/$(DEPDIR)/unit_tests_devel-intersection_tools_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/intersection_tools_test.C' object='geom/unit_tests_devel-intersection_tools_test.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_devel_CPPFLAGS) $(CPPFLAGS) $(unit_tests_devel_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_devel-intersection_tools_test.o `test -f 'geom/intersection_tools_test.C' || echo '$(srcdir)/'`geom/intersection_tools_test.C + +geom/unit_tests_devel-intersection_tools_test.obj: geom/intersection_tools_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_devel_CPPFLAGS) $(CPPFLAGS) $(unit_tests_devel_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_devel-intersection_tools_test.obj -MD -MP -MF geom/$(DEPDIR)/unit_tests_devel-intersection_tools_test.Tpo -c -o geom/unit_tests_devel-intersection_tools_test.obj `if test -f 'geom/intersection_tools_test.C'; then $(CYGPATH_W) 'geom/intersection_tools_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/intersection_tools_test.C'; fi` +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_devel-intersection_tools_test.Tpo geom/$(DEPDIR)/unit_tests_devel-intersection_tools_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/intersection_tools_test.C' object='geom/unit_tests_devel-intersection_tools_test.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_devel_CPPFLAGS) $(CPPFLAGS) $(unit_tests_devel_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_devel-intersection_tools_test.obj `if test -f 'geom/intersection_tools_test.C'; then $(CYGPATH_W) 'geom/intersection_tools_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/intersection_tools_test.C'; fi` + geom/unit_tests_devel-node_test.o: geom/node_test.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_devel_CPPFLAGS) $(CPPFLAGS) $(unit_tests_devel_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_devel-node_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_devel-node_test.Tpo -c -o geom/unit_tests_devel-node_test.o `test -f 'geom/node_test.C' || echo '$(srcdir)/'`geom/node_test.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_devel-node_test.Tpo geom/$(DEPDIR)/unit_tests_devel-node_test.Po @@ -7169,6 +7281,20 @@ geom/unit_tests_oprof-edge_test.obj: geom/edge_test.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_oprof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_oprof_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_oprof-edge_test.obj `if test -f 'geom/edge_test.C'; then $(CYGPATH_W) 'geom/edge_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/edge_test.C'; fi` +geom/unit_tests_oprof-elem_corner_test.o: geom/elem_corner_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_oprof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_oprof_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_oprof-elem_corner_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_oprof-elem_corner_test.Tpo -c -o geom/unit_tests_oprof-elem_corner_test.o `test -f 'geom/elem_corner_test.C' || echo '$(srcdir)/'`geom/elem_corner_test.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_oprof-elem_corner_test.Tpo geom/$(DEPDIR)/unit_tests_oprof-elem_corner_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/elem_corner_test.C' object='geom/unit_tests_oprof-elem_corner_test.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_oprof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_oprof_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_oprof-elem_corner_test.o `test -f 'geom/elem_corner_test.C' || echo '$(srcdir)/'`geom/elem_corner_test.C + +geom/unit_tests_oprof-elem_corner_test.obj: geom/elem_corner_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_oprof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_oprof_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_oprof-elem_corner_test.obj -MD -MP -MF geom/$(DEPDIR)/unit_tests_oprof-elem_corner_test.Tpo -c -o geom/unit_tests_oprof-elem_corner_test.obj `if test -f 'geom/elem_corner_test.C'; then $(CYGPATH_W) 'geom/elem_corner_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/elem_corner_test.C'; fi` +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_oprof-elem_corner_test.Tpo geom/$(DEPDIR)/unit_tests_oprof-elem_corner_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/elem_corner_test.C' object='geom/unit_tests_oprof-elem_corner_test.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_oprof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_oprof_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_oprof-elem_corner_test.obj `if test -f 'geom/elem_corner_test.C'; then $(CYGPATH_W) 'geom/elem_corner_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/elem_corner_test.C'; fi` + geom/unit_tests_oprof-elem_test.o: geom/elem_test.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_oprof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_oprof_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_oprof-elem_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_oprof-elem_test.Tpo -c -o geom/unit_tests_oprof-elem_test.o `test -f 'geom/elem_test.C' || echo '$(srcdir)/'`geom/elem_test.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_oprof-elem_test.Tpo geom/$(DEPDIR)/unit_tests_oprof-elem_test.Po @@ -7183,6 +7309,20 @@ geom/unit_tests_oprof-elem_test.obj: geom/elem_test.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_oprof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_oprof_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_oprof-elem_test.obj `if test -f 'geom/elem_test.C'; then $(CYGPATH_W) 'geom/elem_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/elem_test.C'; fi` +geom/unit_tests_oprof-intersection_tools_test.o: geom/intersection_tools_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_oprof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_oprof_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_oprof-intersection_tools_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_oprof-intersection_tools_test.Tpo -c -o geom/unit_tests_oprof-intersection_tools_test.o `test -f 'geom/intersection_tools_test.C' || echo '$(srcdir)/'`geom/intersection_tools_test.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_oprof-intersection_tools_test.Tpo geom/$(DEPDIR)/unit_tests_oprof-intersection_tools_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/intersection_tools_test.C' object='geom/unit_tests_oprof-intersection_tools_test.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_oprof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_oprof_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_oprof-intersection_tools_test.o `test -f 'geom/intersection_tools_test.C' || echo '$(srcdir)/'`geom/intersection_tools_test.C + +geom/unit_tests_oprof-intersection_tools_test.obj: geom/intersection_tools_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_oprof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_oprof_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_oprof-intersection_tools_test.obj -MD -MP -MF geom/$(DEPDIR)/unit_tests_oprof-intersection_tools_test.Tpo -c -o geom/unit_tests_oprof-intersection_tools_test.obj `if test -f 'geom/intersection_tools_test.C'; then $(CYGPATH_W) 'geom/intersection_tools_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/intersection_tools_test.C'; fi` +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_oprof-intersection_tools_test.Tpo geom/$(DEPDIR)/unit_tests_oprof-intersection_tools_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/intersection_tools_test.C' object='geom/unit_tests_oprof-intersection_tools_test.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_oprof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_oprof_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_oprof-intersection_tools_test.obj `if test -f 'geom/intersection_tools_test.C'; then $(CYGPATH_W) 'geom/intersection_tools_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/intersection_tools_test.C'; fi` + geom/unit_tests_oprof-node_test.o: geom/node_test.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_oprof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_oprof_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_oprof-node_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_oprof-node_test.Tpo -c -o geom/unit_tests_oprof-node_test.o `test -f 'geom/node_test.C' || echo '$(srcdir)/'`geom/node_test.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_oprof-node_test.Tpo geom/$(DEPDIR)/unit_tests_oprof-node_test.Po @@ -8597,6 +8737,20 @@ geom/unit_tests_opt-edge_test.obj: geom/edge_test.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_opt_CPPFLAGS) $(CPPFLAGS) $(unit_tests_opt_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_opt-edge_test.obj `if test -f 'geom/edge_test.C'; then $(CYGPATH_W) 'geom/edge_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/edge_test.C'; fi` +geom/unit_tests_opt-elem_corner_test.o: geom/elem_corner_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_opt_CPPFLAGS) $(CPPFLAGS) $(unit_tests_opt_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_opt-elem_corner_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_opt-elem_corner_test.Tpo -c -o geom/unit_tests_opt-elem_corner_test.o `test -f 'geom/elem_corner_test.C' || echo '$(srcdir)/'`geom/elem_corner_test.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_opt-elem_corner_test.Tpo geom/$(DEPDIR)/unit_tests_opt-elem_corner_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/elem_corner_test.C' object='geom/unit_tests_opt-elem_corner_test.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_opt_CPPFLAGS) $(CPPFLAGS) $(unit_tests_opt_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_opt-elem_corner_test.o `test -f 'geom/elem_corner_test.C' || echo '$(srcdir)/'`geom/elem_corner_test.C + +geom/unit_tests_opt-elem_corner_test.obj: geom/elem_corner_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_opt_CPPFLAGS) $(CPPFLAGS) $(unit_tests_opt_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_opt-elem_corner_test.obj -MD -MP -MF geom/$(DEPDIR)/unit_tests_opt-elem_corner_test.Tpo -c -o geom/unit_tests_opt-elem_corner_test.obj `if test -f 'geom/elem_corner_test.C'; then $(CYGPATH_W) 'geom/elem_corner_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/elem_corner_test.C'; fi` +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_opt-elem_corner_test.Tpo geom/$(DEPDIR)/unit_tests_opt-elem_corner_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/elem_corner_test.C' object='geom/unit_tests_opt-elem_corner_test.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_opt_CPPFLAGS) $(CPPFLAGS) $(unit_tests_opt_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_opt-elem_corner_test.obj `if test -f 'geom/elem_corner_test.C'; then $(CYGPATH_W) 'geom/elem_corner_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/elem_corner_test.C'; fi` + geom/unit_tests_opt-elem_test.o: geom/elem_test.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_opt_CPPFLAGS) $(CPPFLAGS) $(unit_tests_opt_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_opt-elem_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_opt-elem_test.Tpo -c -o geom/unit_tests_opt-elem_test.o `test -f 'geom/elem_test.C' || echo '$(srcdir)/'`geom/elem_test.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_opt-elem_test.Tpo geom/$(DEPDIR)/unit_tests_opt-elem_test.Po @@ -8611,6 +8765,20 @@ geom/unit_tests_opt-elem_test.obj: geom/elem_test.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_opt_CPPFLAGS) $(CPPFLAGS) $(unit_tests_opt_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_opt-elem_test.obj `if test -f 'geom/elem_test.C'; then $(CYGPATH_W) 'geom/elem_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/elem_test.C'; fi` +geom/unit_tests_opt-intersection_tools_test.o: geom/intersection_tools_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_opt_CPPFLAGS) $(CPPFLAGS) $(unit_tests_opt_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_opt-intersection_tools_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_opt-intersection_tools_test.Tpo -c -o geom/unit_tests_opt-intersection_tools_test.o `test -f 'geom/intersection_tools_test.C' || echo '$(srcdir)/'`geom/intersection_tools_test.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_opt-intersection_tools_test.Tpo geom/$(DEPDIR)/unit_tests_opt-intersection_tools_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/intersection_tools_test.C' object='geom/unit_tests_opt-intersection_tools_test.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_opt_CPPFLAGS) $(CPPFLAGS) $(unit_tests_opt_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_opt-intersection_tools_test.o `test -f 'geom/intersection_tools_test.C' || echo '$(srcdir)/'`geom/intersection_tools_test.C + +geom/unit_tests_opt-intersection_tools_test.obj: geom/intersection_tools_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_opt_CPPFLAGS) $(CPPFLAGS) $(unit_tests_opt_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_opt-intersection_tools_test.obj -MD -MP -MF geom/$(DEPDIR)/unit_tests_opt-intersection_tools_test.Tpo -c -o geom/unit_tests_opt-intersection_tools_test.obj `if test -f 'geom/intersection_tools_test.C'; then $(CYGPATH_W) 'geom/intersection_tools_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/intersection_tools_test.C'; fi` +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_opt-intersection_tools_test.Tpo geom/$(DEPDIR)/unit_tests_opt-intersection_tools_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/intersection_tools_test.C' object='geom/unit_tests_opt-intersection_tools_test.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_opt_CPPFLAGS) $(CPPFLAGS) $(unit_tests_opt_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_opt-intersection_tools_test.obj `if test -f 'geom/intersection_tools_test.C'; then $(CYGPATH_W) 'geom/intersection_tools_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/intersection_tools_test.C'; fi` + geom/unit_tests_opt-node_test.o: geom/node_test.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_opt_CPPFLAGS) $(CPPFLAGS) $(unit_tests_opt_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_opt-node_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_opt-node_test.Tpo -c -o geom/unit_tests_opt-node_test.o `test -f 'geom/node_test.C' || echo '$(srcdir)/'`geom/node_test.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_opt-node_test.Tpo geom/$(DEPDIR)/unit_tests_opt-node_test.Po @@ -10025,6 +10193,20 @@ geom/unit_tests_prof-edge_test.obj: geom/edge_test.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_prof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_prof_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_prof-edge_test.obj `if test -f 'geom/edge_test.C'; then $(CYGPATH_W) 'geom/edge_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/edge_test.C'; fi` +geom/unit_tests_prof-elem_corner_test.o: geom/elem_corner_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_prof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_prof_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_prof-elem_corner_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_prof-elem_corner_test.Tpo -c -o geom/unit_tests_prof-elem_corner_test.o `test -f 'geom/elem_corner_test.C' || echo '$(srcdir)/'`geom/elem_corner_test.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_prof-elem_corner_test.Tpo geom/$(DEPDIR)/unit_tests_prof-elem_corner_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/elem_corner_test.C' object='geom/unit_tests_prof-elem_corner_test.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_prof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_prof_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_prof-elem_corner_test.o `test -f 'geom/elem_corner_test.C' || echo '$(srcdir)/'`geom/elem_corner_test.C + +geom/unit_tests_prof-elem_corner_test.obj: geom/elem_corner_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_prof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_prof_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_prof-elem_corner_test.obj -MD -MP -MF geom/$(DEPDIR)/unit_tests_prof-elem_corner_test.Tpo -c -o geom/unit_tests_prof-elem_corner_test.obj `if test -f 'geom/elem_corner_test.C'; then $(CYGPATH_W) 'geom/elem_corner_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/elem_corner_test.C'; fi` +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_prof-elem_corner_test.Tpo geom/$(DEPDIR)/unit_tests_prof-elem_corner_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/elem_corner_test.C' object='geom/unit_tests_prof-elem_corner_test.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_prof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_prof_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_prof-elem_corner_test.obj `if test -f 'geom/elem_corner_test.C'; then $(CYGPATH_W) 'geom/elem_corner_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/elem_corner_test.C'; fi` + geom/unit_tests_prof-elem_test.o: geom/elem_test.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_prof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_prof_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_prof-elem_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_prof-elem_test.Tpo -c -o geom/unit_tests_prof-elem_test.o `test -f 'geom/elem_test.C' || echo '$(srcdir)/'`geom/elem_test.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_prof-elem_test.Tpo geom/$(DEPDIR)/unit_tests_prof-elem_test.Po @@ -10039,6 +10221,20 @@ geom/unit_tests_prof-elem_test.obj: geom/elem_test.C @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_prof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_prof_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_prof-elem_test.obj `if test -f 'geom/elem_test.C'; then $(CYGPATH_W) 'geom/elem_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/elem_test.C'; fi` +geom/unit_tests_prof-intersection_tools_test.o: geom/intersection_tools_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_prof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_prof_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_prof-intersection_tools_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_prof-intersection_tools_test.Tpo -c -o geom/unit_tests_prof-intersection_tools_test.o `test -f 'geom/intersection_tools_test.C' || echo '$(srcdir)/'`geom/intersection_tools_test.C +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_prof-intersection_tools_test.Tpo geom/$(DEPDIR)/unit_tests_prof-intersection_tools_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/intersection_tools_test.C' object='geom/unit_tests_prof-intersection_tools_test.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_prof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_prof_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_prof-intersection_tools_test.o `test -f 'geom/intersection_tools_test.C' || echo '$(srcdir)/'`geom/intersection_tools_test.C + +geom/unit_tests_prof-intersection_tools_test.obj: geom/intersection_tools_test.C +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_prof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_prof_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_prof-intersection_tools_test.obj -MD -MP -MF geom/$(DEPDIR)/unit_tests_prof-intersection_tools_test.Tpo -c -o geom/unit_tests_prof-intersection_tools_test.obj `if test -f 'geom/intersection_tools_test.C'; then $(CYGPATH_W) 'geom/intersection_tools_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/intersection_tools_test.C'; fi` +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_prof-intersection_tools_test.Tpo geom/$(DEPDIR)/unit_tests_prof-intersection_tools_test.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='geom/intersection_tools_test.C' object='geom/unit_tests_prof-intersection_tools_test.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_prof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_prof_CXXFLAGS) $(CXXFLAGS) -c -o geom/unit_tests_prof-intersection_tools_test.obj `if test -f 'geom/intersection_tools_test.C'; then $(CYGPATH_W) 'geom/intersection_tools_test.C'; else $(CYGPATH_W) '$(srcdir)/geom/intersection_tools_test.C'; fi` + geom/unit_tests_prof-node_test.o: geom/node_test.C @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(unit_tests_prof_CPPFLAGS) $(CPPFLAGS) $(unit_tests_prof_CXXFLAGS) $(CXXFLAGS) -MT geom/unit_tests_prof-node_test.o -MD -MP -MF geom/$(DEPDIR)/unit_tests_prof-node_test.Tpo -c -o geom/unit_tests_prof-node_test.o `test -f 'geom/node_test.C' || echo '$(srcdir)/'`geom/node_test.C @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) geom/$(DEPDIR)/unit_tests_prof-node_test.Tpo geom/$(DEPDIR)/unit_tests_prof-node_test.Po @@ -11596,7 +11792,9 @@ distclean: distclean-am -rm -f fparser/$(DEPDIR)/unit_tests_prof-autodiff.Po -rm -f geom/$(DEPDIR)/unit_tests_dbg-bbox_test.Po -rm -f geom/$(DEPDIR)/unit_tests_dbg-edge_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_dbg-elem_corner_test.Po -rm -f geom/$(DEPDIR)/unit_tests_dbg-elem_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_dbg-intersection_tools_test.Po -rm -f geom/$(DEPDIR)/unit_tests_dbg-node_test.Po -rm -f geom/$(DEPDIR)/unit_tests_dbg-point_test.Po -rm -f geom/$(DEPDIR)/unit_tests_dbg-side_test.Po @@ -11604,7 +11802,9 @@ distclean: distclean-am -rm -f geom/$(DEPDIR)/unit_tests_dbg-which_node_am_i_test.Po -rm -f geom/$(DEPDIR)/unit_tests_devel-bbox_test.Po -rm -f geom/$(DEPDIR)/unit_tests_devel-edge_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_devel-elem_corner_test.Po -rm -f geom/$(DEPDIR)/unit_tests_devel-elem_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_devel-intersection_tools_test.Po -rm -f geom/$(DEPDIR)/unit_tests_devel-node_test.Po -rm -f geom/$(DEPDIR)/unit_tests_devel-point_test.Po -rm -f geom/$(DEPDIR)/unit_tests_devel-side_test.Po @@ -11612,7 +11812,9 @@ distclean: distclean-am -rm -f geom/$(DEPDIR)/unit_tests_devel-which_node_am_i_test.Po -rm -f geom/$(DEPDIR)/unit_tests_oprof-bbox_test.Po -rm -f geom/$(DEPDIR)/unit_tests_oprof-edge_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_oprof-elem_corner_test.Po -rm -f geom/$(DEPDIR)/unit_tests_oprof-elem_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_oprof-intersection_tools_test.Po -rm -f geom/$(DEPDIR)/unit_tests_oprof-node_test.Po -rm -f geom/$(DEPDIR)/unit_tests_oprof-point_test.Po -rm -f geom/$(DEPDIR)/unit_tests_oprof-side_test.Po @@ -11620,7 +11822,9 @@ distclean: distclean-am -rm -f geom/$(DEPDIR)/unit_tests_oprof-which_node_am_i_test.Po -rm -f geom/$(DEPDIR)/unit_tests_opt-bbox_test.Po -rm -f geom/$(DEPDIR)/unit_tests_opt-edge_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_opt-elem_corner_test.Po -rm -f geom/$(DEPDIR)/unit_tests_opt-elem_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_opt-intersection_tools_test.Po -rm -f geom/$(DEPDIR)/unit_tests_opt-node_test.Po -rm -f geom/$(DEPDIR)/unit_tests_opt-point_test.Po -rm -f geom/$(DEPDIR)/unit_tests_opt-side_test.Po @@ -11628,7 +11832,9 @@ distclean: distclean-am -rm -f geom/$(DEPDIR)/unit_tests_opt-which_node_am_i_test.Po -rm -f geom/$(DEPDIR)/unit_tests_prof-bbox_test.Po -rm -f geom/$(DEPDIR)/unit_tests_prof-edge_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_prof-elem_corner_test.Po -rm -f geom/$(DEPDIR)/unit_tests_prof-elem_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_prof-intersection_tools_test.Po -rm -f geom/$(DEPDIR)/unit_tests_prof-node_test.Po -rm -f geom/$(DEPDIR)/unit_tests_prof-point_test.Po -rm -f geom/$(DEPDIR)/unit_tests_prof-side_test.Po @@ -12153,7 +12359,9 @@ maintainer-clean: maintainer-clean-am -rm -f fparser/$(DEPDIR)/unit_tests_prof-autodiff.Po -rm -f geom/$(DEPDIR)/unit_tests_dbg-bbox_test.Po -rm -f geom/$(DEPDIR)/unit_tests_dbg-edge_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_dbg-elem_corner_test.Po -rm -f geom/$(DEPDIR)/unit_tests_dbg-elem_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_dbg-intersection_tools_test.Po -rm -f geom/$(DEPDIR)/unit_tests_dbg-node_test.Po -rm -f geom/$(DEPDIR)/unit_tests_dbg-point_test.Po -rm -f geom/$(DEPDIR)/unit_tests_dbg-side_test.Po @@ -12161,7 +12369,9 @@ maintainer-clean: maintainer-clean-am -rm -f geom/$(DEPDIR)/unit_tests_dbg-which_node_am_i_test.Po -rm -f geom/$(DEPDIR)/unit_tests_devel-bbox_test.Po -rm -f geom/$(DEPDIR)/unit_tests_devel-edge_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_devel-elem_corner_test.Po -rm -f geom/$(DEPDIR)/unit_tests_devel-elem_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_devel-intersection_tools_test.Po -rm -f geom/$(DEPDIR)/unit_tests_devel-node_test.Po -rm -f geom/$(DEPDIR)/unit_tests_devel-point_test.Po -rm -f geom/$(DEPDIR)/unit_tests_devel-side_test.Po @@ -12169,7 +12379,9 @@ maintainer-clean: maintainer-clean-am -rm -f geom/$(DEPDIR)/unit_tests_devel-which_node_am_i_test.Po -rm -f geom/$(DEPDIR)/unit_tests_oprof-bbox_test.Po -rm -f geom/$(DEPDIR)/unit_tests_oprof-edge_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_oprof-elem_corner_test.Po -rm -f geom/$(DEPDIR)/unit_tests_oprof-elem_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_oprof-intersection_tools_test.Po -rm -f geom/$(DEPDIR)/unit_tests_oprof-node_test.Po -rm -f geom/$(DEPDIR)/unit_tests_oprof-point_test.Po -rm -f geom/$(DEPDIR)/unit_tests_oprof-side_test.Po @@ -12177,7 +12389,9 @@ maintainer-clean: maintainer-clean-am -rm -f geom/$(DEPDIR)/unit_tests_oprof-which_node_am_i_test.Po -rm -f geom/$(DEPDIR)/unit_tests_opt-bbox_test.Po -rm -f geom/$(DEPDIR)/unit_tests_opt-edge_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_opt-elem_corner_test.Po -rm -f geom/$(DEPDIR)/unit_tests_opt-elem_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_opt-intersection_tools_test.Po -rm -f geom/$(DEPDIR)/unit_tests_opt-node_test.Po -rm -f geom/$(DEPDIR)/unit_tests_opt-point_test.Po -rm -f geom/$(DEPDIR)/unit_tests_opt-side_test.Po @@ -12185,7 +12399,9 @@ maintainer-clean: maintainer-clean-am -rm -f geom/$(DEPDIR)/unit_tests_opt-which_node_am_i_test.Po -rm -f geom/$(DEPDIR)/unit_tests_prof-bbox_test.Po -rm -f geom/$(DEPDIR)/unit_tests_prof-edge_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_prof-elem_corner_test.Po -rm -f geom/$(DEPDIR)/unit_tests_prof-elem_test.Po + -rm -f geom/$(DEPDIR)/unit_tests_prof-intersection_tools_test.Po -rm -f geom/$(DEPDIR)/unit_tests_prof-node_test.Po -rm -f geom/$(DEPDIR)/unit_tests_prof-point_test.Po -rm -f geom/$(DEPDIR)/unit_tests_prof-side_test.Po From 08d51bb03fe02a2463ca2ce28eac8ef18e68ea6c Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Mon, 14 Nov 2022 14:45:02 -0700 Subject: [PATCH 22/30] Add IntersectionTools::within_edge --- include/geom/intersection_tools.h | 42 ++++++++ src/geom/intersection_tools.C | 126 ++++++++++++++++-------- tests/geom/intersection_tools_test.C | 139 ++++++++++++++++----------- 3 files changed, 214 insertions(+), 93 deletions(-) diff --git a/include/geom/intersection_tools.h b/include/geom/intersection_tools.h index 63c786605f2..3af1b3a72a2 100644 --- a/include/geom/intersection_tools.h +++ b/include/geom/intersection_tools.h @@ -69,6 +69,34 @@ bool collinear(const Point & p1, const Point & p3, const Real tol = TOLERANCE); +/** + * @returns Whether or not the edges on element \p element are + * individually collinear. +*/ +bool edges_are_collinear(const Elem & elem, const Real tol = TOLERANCE); + +/** + * \returns True if the given point is contained within an edge an element + * @param elem The element + * @param p The point + * @param corner To be filled with the edge/vertex that the point + * is within/at or, if any (must be initially invalid) + * @param linearize Whether or not to "linearize" the check, if this + * is set to false and edges are found to not be collinear, an error + * is thrown + * + * \p corner will be set to an "at vertex" state if the point is + * both within the edge _and_ at a vertex. + * + * This method is only implemented for three-dimensional, finite + * elements. +*/ +bool within_edge(const Elem & elem, + const Point & p, + ElemCorner & corner, + const bool linearize = false, + const Real tol = TOLERANCE); + /** * \returns True if the given point is contained within an edge * on the given side of an element @@ -94,6 +122,20 @@ bool within_edge_on_side(const Elem & elem, const bool linearize = false, const Real tol = TOLERANCE); +namespace detail +{ +/** + * Internal method for checking whether or not the point \p + * is within the edge defined by vertices \p v1 and \p v2 + * on element \p elem. +*/ +bool _within_edge(const Elem & elem, + const Point & p, + ElemCorner & corner, + const unsigned int v1, + const unsigned int v2, + const Real tol); +} // namespace detail } // namespace IntersectionTools } // namespace libMesh diff --git a/src/geom/intersection_tools.C b/src/geom/intersection_tools.C index 09a6684001f..f47f7429f6b 100644 --- a/src/geom/intersection_tools.C +++ b/src/geom/intersection_tools.C @@ -73,6 +73,27 @@ bool collinear(const Point & p1, return (std::abs(p2_p1 * p3_p2) / denom) > ((Real)1 - tol); } +bool edges_are_collinear(const Elem & elem, const Real tol) +{ + if (elem.default_order() < 2) + return true; + + for (const auto e : elem.edge_index_range()) + { + // we should expect at least 3 nodes/edges for our higher order elems + libmesh_assert_greater_equal(elem.n_nodes_on_edge(e), 3); + + const unsigned int * edge_nodes_map = elem.nodes_on_edge_ptr(e); + if (!collinear(elem.point(edge_nodes_map[0]), + elem.point(edge_nodes_map[1]), + elem.point(edge_nodes_map[2]), + tol)) + return false; + } + + return true; +} + bool within_edge_on_side(const Elem & elem, const Point & p, const unsigned short s, @@ -84,21 +105,10 @@ bool within_edge_on_side(const Elem & elem, libmesh_assert(corner.is_invalid()); libmesh_assert_equal_to(elem.dim(), 3); - // For higher order than linear without linearization, make sure - // that our edges are collinear - if (elem.default_order() > 1 && !linearize) - for (const auto e : elem.edge_index_range()) - { - // we should expect at least 3 nodes/edges for our higher order elems - libmesh_assert_greater_equal(elem.n_nodes_on_edge(e), 3); - - const unsigned int * edge_nodes_map = elem.nodes_on_edge_ptr(e); - if (!collinear(elem.point(edge_nodes_map[0]), - elem.point(edge_nodes_map[1]), - elem.point(edge_nodes_map[2]))) - libmesh_error_msg("Failed to use Cell::without_edge_on_side without linearization " - "because an edge was found that is not collinear."); - } + // Without linearization, make sure that our edges are collinear + if (!linearize && !edges_are_collinear(elem, tol)) + libmesh_error_msg("Failed to use Cell::without_edge_on_side without linearization " + "because an edge was found that is not collinear."); const auto vs = elem.n_vertices_on_side(s); const unsigned int * side_nodes_map = elem.nodes_on_side_ptr(s); @@ -109,35 +119,73 @@ bool within_edge_on_side(const Elem & elem, auto last_v = side_nodes_map[vs - 1]; for (const auto side_v : make_range(vs)) { - const auto other_v = side_nodes_map[side_v]; - const auto within_result = within_segment(elem.point(last_v), elem.point(other_v), p, tol); - if (within_result == NOT_WITHIN) - { - last_v = side_nodes_map[side_v]; - continue; - } - - if (within_result == BETWEEN) - { - corner.set_edge(last_v, other_v); - libmesh_assert(corner.build_edge(elem)->contains_point(p, tol)); - } - else if (within_result == AT_BEGINNING) - { - corner.set_vertex(last_v); - libmesh_assert(elem.point(last_v).relative_fuzzy_equals(p, tol)); - } - else - { - corner.set_vertex(other_v); - libmesh_assert(elem.point(other_v).relative_fuzzy_equals(p, tol)); - } - return true; + if (detail::_within_edge(elem, p, corner, last_v, side_nodes_map[side_v], tol)) + return true; + last_v = side_nodes_map[side_v]; + } + + return false; +} + +bool within_edge(const Elem & elem, + const Point & p, + ElemCorner & corner, + const bool linearize, + const Real tol) +{ + libmesh_assert(corner.is_invalid()); + + // Without linearization, make sure that our edges are collinear + if (!linearize && !edges_are_collinear(elem, tol)) + libmesh_error_msg("Failed to use Cell::without_edge without linearization " + "because an edge was found that is not collinear."); + + for (const auto e : elem.edge_index_range()) + { + const unsigned int * edge_nodes_map = elem.nodes_on_edge_ptr(e); + if (detail::_within_edge(elem, p, corner, edge_nodes_map[0], edge_nodes_map[1], tol)) + return true; } return false; } +namespace detail +{ +bool _within_edge(const Elem & elem, + const Point & p, + ElemCorner & corner, + const unsigned int v1, + const unsigned int v2, + const Real tol) +{ + libmesh_assert(corner.is_invalid()); + libmesh_assert_less(v1, elem.n_vertices()); + libmesh_assert_less(v2, elem.n_vertices()); + + const auto within_result = within_segment(elem.point(v1), elem.point(v2), p, tol); + if (within_result == NOT_WITHIN) + return false; + + if (within_result == BETWEEN) + { + corner.set_edge(v1, v2); + libmesh_assert(corner.build_edge(elem)->contains_point(p, tol)); + } + else if (within_result == AT_BEGINNING) + { + corner.set_vertex(v1); + libmesh_assert(elem.point(v1).relative_fuzzy_equals(p, tol)); + } + else + { + corner.set_vertex(v2); + libmesh_assert(elem.point(v2).relative_fuzzy_equals(p, tol)); + } + + return true; +} +} // namespace detail } // namespace libMesh::IntersectionTools diff --git a/tests/geom/intersection_tools_test.C b/tests/geom/intersection_tools_test.C index c0d2e833094..0df0bb57f38 100644 --- a/tests/geom/intersection_tools_test.C +++ b/tests/geom/intersection_tools_test.C @@ -117,80 +117,102 @@ public: elem_type); } - void test_within_edge_on_side() + void test_within_edge() { LOG_UNIT_TEST; - if (_mesh->mesh_dimension() != 3) - return; + const auto is_3d = _mesh->mesh_dimension() == 3; // check locations at every node for (const auto & elem : _mesh->active_local_element_ptr_range()) - for (const auto s : elem->side_index_range()) - for (const auto e : elem->edge_index_range()) - for (const auto n : elem->nodes_on_edge(e)) - { - ElemCorner corner; - const auto within = IntersectionTools::within_edge_on_side(*elem, - elem->point(n), - s, - corner); - - CPPUNIT_ASSERT_EQUAL(within, elem->is_node_on_side(n, s)); - if (elem->is_node_on_side(n, s)) + for (const auto e : elem->edge_index_range()) + for (const auto n : elem->nodes_on_edge(e)) + { + ElemCorner corner; + const auto within = IntersectionTools::within_edge(*elem, elem->point(n), corner); + CPPUNIT_ASSERT(within); + + if (is_3d) + for (const auto s : elem->side_index_range()) { - CPPUNIT_ASSERT_EQUAL(elem->is_vertex(n), corner.at_vertex(n)); - CPPUNIT_ASSERT_EQUAL(elem->is_vertex(n), !corner.at_edge(*elem, e)); + ElemCorner corner_on_side; + const auto within_on_side = IntersectionTools::within_edge_on_side(*elem, + elem->point(n), + s, + corner_on_side); + + const auto node_is_on_side = elem->is_node_on_side(n, s); + CPPUNIT_ASSERT_EQUAL(within_on_side, node_is_on_side); + if (node_is_on_side) + { + CPPUNIT_ASSERT_EQUAL(corner.at_vertex(n), corner_on_side.at_vertex(n)); + CPPUNIT_ASSERT_EQUAL(corner.at_edge(*elem, e), corner_on_side.at_edge(*elem, e)); + CPPUNIT_ASSERT_EQUAL(elem->is_vertex(n), corner_on_side.at_vertex(n)); + CPPUNIT_ASSERT_EQUAL(elem->is_vertex(n), !corner_on_side.at_edge(*elem, e)); + } } - } + } // cut edges into segments for (const auto & elem : _mesh->active_local_element_ptr_range()) for (const auto e : elem->edge_index_range()) - for (const auto s : elem->side_index_range()) - if (elem->is_edge_on_side(e, s)) - { - const auto nodes_on_edge = elem->nodes_on_edge(e); - const auto & p1 = elem->point(nodes_on_edge[0]); - const auto & p2 = elem->point(nodes_on_edge[1]); - const auto length_vec = p2 - p1; - const auto length = length_vec.norm(); - const auto p1_to_p2 = length_vec / length; - - int segments = 5; - Real dx = (Real)1 / segments * length; - for (const auto i : make_range(-1, segments + 1)) - { - const auto p = p1 + Real(i) * dx * p1_to_p2; - ElemCorner corner; - const auto within = IntersectionTools::within_edge_on_side(*elem, - p, - s, - corner); - - CPPUNIT_ASSERT_EQUAL(within, i >= 0 && i <= segments); - CPPUNIT_ASSERT_EQUAL(corner.at_vertex(nodes_on_edge[0]), i == 0); - CPPUNIT_ASSERT_EQUAL(corner.at_vertex(nodes_on_edge[1]), i == segments); - CPPUNIT_ASSERT_EQUAL(corner.at_edge(*elem, e), i > 0 && i < segments); - } - } + { + const auto nodes_on_edge = elem->nodes_on_edge(e); + const auto & p1 = elem->point(nodes_on_edge[0]); + const auto & p2 = elem->point(nodes_on_edge[1]); + const auto length_vec = p2 - p1; + const auto length = length_vec.norm(); + const auto p1_to_p2 = length_vec / length; + + int segments = 5; + Real dx = (Real)1 / segments * length; + for (const auto i : make_range(-1, segments + 1)) + { + const auto p = p1 + Real(i) * dx * p1_to_p2; + + ElemCorner corner; + const auto within = IntersectionTools::within_edge(*elem, p, corner); + CPPUNIT_ASSERT_EQUAL(within, i >= 0 && i <= segments); + + if (is_3d) + for (const auto s : elem->side_index_range()) + if (elem->is_edge_on_side(e, s)) + { + ElemCorner corner_on_side; + const auto within_on_side = IntersectionTools::within_edge_on_side(*elem, + p, + s, + corner_on_side); + + CPPUNIT_ASSERT_EQUAL(within_on_side, within); + CPPUNIT_ASSERT_EQUAL(corner_on_side.at_vertex(nodes_on_edge[0]), i == 0); + CPPUNIT_ASSERT_EQUAL(corner_on_side.at_vertex(nodes_on_edge[1]), i == segments); + CPPUNIT_ASSERT_EQUAL(corner_on_side.at_edge(*elem, e), i > 0 && i < segments); + } + } + } // check elem centroids for (const auto & elem : _mesh->active_local_element_ptr_range()) - for (const auto s : elem->side_index_range()) - { - ElemCorner corner; - CPPUNIT_ASSERT(!IntersectionTools::within_edge_on_side(*elem, - elem->vertex_average(), - s, - corner)); - } + { + const auto p = elem->vertex_average(); + + ElemCorner corner; + CPPUNIT_ASSERT(!IntersectionTools::within_edge(*elem, p, corner)); + + if (is_3d) + for (const auto s : elem->side_index_range()) + { + ElemCorner corner_on_side; + CPPUNIT_ASSERT(!IntersectionTools::within_edge_on_side(*elem, p, s, corner_on_side)); + } + } } }; #define MESHEDINTERSECTIONTOOLSTEST \ - CPPUNIT_TEST( test_within_edge_on_side ); + CPPUNIT_TEST( test_within_edge ); #define INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(elemtype) \ class MeshedIntersectionToolsTest_##elemtype : public MeshedIntersectionToolsTest { \ @@ -209,6 +231,15 @@ public: \ CPPUNIT_TEST_SUITE_REGISTRATION( MeshedIntersectionToolsTest_##elemtype ) +#if LIBMESH_DIM > 1 +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(TRI3); +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(TRI6); +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(TRI7); + +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(QUAD4); +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(QUAD8); +INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(QUAD9); +#endif // LIBMESH_DIM > 1 #if LIBMESH_DIM > 2 INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(TET4); From c0bc3c1f028c2b6ea2dcc8761b91de9dc035f8c1 Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Mon, 14 Nov 2022 14:47:42 -0700 Subject: [PATCH 23/30] Only test when quad is available --- tests/geom/elem_corner_test.C | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/geom/elem_corner_test.C b/tests/geom/elem_corner_test.C index 29e4eb33712..9992ec14414 100644 --- a/tests/geom/elem_corner_test.C +++ b/tests/geom/elem_corner_test.C @@ -92,12 +92,13 @@ public: CPPUNIT_ASSERT(at_quad_edge.is_valid(*quad, 0.5 * (quad->point(1) + quad->point(2)))); for (const auto e : quad->edge_index_range()) CPPUNIT_ASSERT_EQUAL(at_quad_edge.at_edge(*quad, e), e == 1); - } - auto quad_edge_elem = at_quad_edge.build_edge(*quad); + + auto quad_edge_elem = at_quad_edge.build_edge(*quad); CPPUNIT_ASSERT((quad_edge_elem->point(0).absolute_fuzzy_equals(quad->point(1)) && quad_edge_elem->point(1).absolute_fuzzy_equals(quad->point(2))) || ((quad_edge_elem->point(0).absolute_fuzzy_equals(quad->point(2)) && quad_edge_elem->point(1).absolute_fuzzy_equals(quad->point(1))))); + } #endif #if LIBMESH_DIM > 2 From 7c4df98f90a15801281dab81f8a1d3fbf22b1b18 Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Mon, 14 Nov 2022 14:50:12 -0700 Subject: [PATCH 24/30] Remove incorrect statement from doxygen --- include/geom/intersection_tools.h | 3 --- 1 file changed, 3 deletions(-) diff --git a/include/geom/intersection_tools.h b/include/geom/intersection_tools.h index 3af1b3a72a2..0c14aed7ab9 100644 --- a/include/geom/intersection_tools.h +++ b/include/geom/intersection_tools.h @@ -87,9 +87,6 @@ bool edges_are_collinear(const Elem & elem, const Real tol = TOLERANCE); * * \p corner will be set to an "at vertex" state if the point is * both within the edge _and_ at a vertex. - * - * This method is only implemented for three-dimensional, finite - * elements. */ bool within_edge(const Elem & elem, const Point & p, From 663c05fde95e3535997ef9edc2b275c5f8f09a9d Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Mon, 14 Nov 2022 15:36:52 -0700 Subject: [PATCH 25/30] Run the within_edge cases over a variety of scales --- tests/geom/intersection_tools_test.C | 188 ++++++++++++++------------- 1 file changed, 98 insertions(+), 90 deletions(-) diff --git a/tests/geom/intersection_tools_test.C b/tests/geom/intersection_tools_test.C index 0df0bb57f38..277819ffcdc 100644 --- a/tests/geom/intersection_tools_test.C +++ b/tests/geom/intersection_tools_test.C @@ -91,7 +91,7 @@ template class MeshedIntersectionToolsTest : public CppUnit::TestCase { private: - std::unique_ptr _mesh; + std::vector> _meshes; protected: std::string libmesh_suite_name; @@ -99,114 +99,122 @@ protected: public: void setUp() { - const Real minpos = 1.5, maxpos = 4.86; - const unsigned int N = 3; - - _mesh = std::make_unique(*TestCommWorld); - auto test_elem = Elem::build(elem_type); - - const unsigned int dim = test_elem->dim(); - const unsigned int use_y = dim > 1; - const unsigned int use_z = dim > 2; - - MeshTools::Generation::build_cube (*_mesh, - N, N*use_y, N*use_z, - minpos, maxpos, - minpos, use_y*maxpos, - minpos, use_z*maxpos, - elem_type); + const std::vector scales{1e-8, 1, 1e8}; + for (const auto scale : scales) + { + const Real minpos = scale * 1.5; + const Real maxpos = scale * 4.86; + const unsigned int N = 3; + + std::unique_ptr mesh = std::make_unique(*TestCommWorld); + auto test_elem = Elem::build(elem_type); + + const unsigned int dim = test_elem->dim(); + const unsigned int use_y = dim > 1; + const unsigned int use_z = dim > 2; + + MeshTools::Generation::build_cube (*mesh, + N, N*use_y, N*use_z, + minpos, maxpos, + minpos, use_y*maxpos, + minpos, use_z*maxpos, + elem_type); + + _meshes.emplace_back(std::move(mesh)); + } } void test_within_edge() { LOG_UNIT_TEST; - const auto is_3d = _mesh->mesh_dimension() == 3; - // check locations at every node - for (const auto & elem : _mesh->active_local_element_ptr_range()) - for (const auto e : elem->edge_index_range()) - for (const auto n : elem->nodes_on_edge(e)) - { - ElemCorner corner; - const auto within = IntersectionTools::within_edge(*elem, elem->point(n), corner); - CPPUNIT_ASSERT(within); - - if (is_3d) - for (const auto s : elem->side_index_range()) - { - ElemCorner corner_on_side; - const auto within_on_side = IntersectionTools::within_edge_on_side(*elem, - elem->point(n), - s, - corner_on_side); - - const auto node_is_on_side = elem->is_node_on_side(n, s); - CPPUNIT_ASSERT_EQUAL(within_on_side, node_is_on_side); - if (node_is_on_side) - { - CPPUNIT_ASSERT_EQUAL(corner.at_vertex(n), corner_on_side.at_vertex(n)); - CPPUNIT_ASSERT_EQUAL(corner.at_edge(*elem, e), corner_on_side.at_edge(*elem, e)); - CPPUNIT_ASSERT_EQUAL(elem->is_vertex(n), corner_on_side.at_vertex(n)); - CPPUNIT_ASSERT_EQUAL(elem->is_vertex(n), !corner_on_side.at_edge(*elem, e)); - } - } - } - - // cut edges into segments - for (const auto & elem : _mesh->active_local_element_ptr_range()) - for (const auto e : elem->edge_index_range()) - { - const auto nodes_on_edge = elem->nodes_on_edge(e); - const auto & p1 = elem->point(nodes_on_edge[0]); - const auto & p2 = elem->point(nodes_on_edge[1]); - const auto length_vec = p2 - p1; - const auto length = length_vec.norm(); - const auto p1_to_p2 = length_vec / length; - - int segments = 5; - Real dx = (Real)1 / segments * length; - for (const auto i : make_range(-1, segments + 1)) - { - const auto p = p1 + Real(i) * dx * p1_to_p2; - - ElemCorner corner; - const auto within = IntersectionTools::within_edge(*elem, p, corner); - CPPUNIT_ASSERT_EQUAL(within, i >= 0 && i <= segments); - - if (is_3d) - for (const auto s : elem->side_index_range()) - if (elem->is_edge_on_side(e, s)) + for (const auto & mesh : _meshes) + for (const auto & elem : mesh->active_local_element_ptr_range()) + for (const auto e : elem->edge_index_range()) + for (const auto n : elem->nodes_on_edge(e)) + { + ElemCorner corner; + const auto within = IntersectionTools::within_edge(*elem, elem->point(n), corner); + CPPUNIT_ASSERT(within); + + if (mesh->mesh_dimension() == 3) + for (const auto s : elem->side_index_range()) { ElemCorner corner_on_side; const auto within_on_side = IntersectionTools::within_edge_on_side(*elem, - p, + elem->point(n), s, corner_on_side); - CPPUNIT_ASSERT_EQUAL(within_on_side, within); - CPPUNIT_ASSERT_EQUAL(corner_on_side.at_vertex(nodes_on_edge[0]), i == 0); - CPPUNIT_ASSERT_EQUAL(corner_on_side.at_vertex(nodes_on_edge[1]), i == segments); - CPPUNIT_ASSERT_EQUAL(corner_on_side.at_edge(*elem, e), i > 0 && i < segments); + const auto node_is_on_side = elem->is_node_on_side(n, s); + CPPUNIT_ASSERT_EQUAL(within_on_side, node_is_on_side); + if (node_is_on_side) + { + CPPUNIT_ASSERT_EQUAL(corner.at_vertex(n), corner_on_side.at_vertex(n)); + CPPUNIT_ASSERT_EQUAL(corner.at_edge(*elem, e), corner_on_side.at_edge(*elem, e)); + CPPUNIT_ASSERT_EQUAL(elem->is_vertex(n), corner_on_side.at_vertex(n)); + CPPUNIT_ASSERT_EQUAL(elem->is_vertex(n), !corner_on_side.at_edge(*elem, e)); + } } + } + + // cut edges into segments + for (const auto & mesh : _meshes) + for (const auto & elem : mesh->active_local_element_ptr_range()) + for (const auto e : elem->edge_index_range()) + { + const auto nodes_on_edge = elem->nodes_on_edge(e); + const auto & p1 = elem->point(nodes_on_edge[0]); + const auto & p2 = elem->point(nodes_on_edge[1]); + const auto length_vec = p2 - p1; + const auto length = length_vec.norm(); + const auto p1_to_p2 = length_vec / length; + + int segments = 5; + Real dx = (Real)1 / segments * length; + for (const auto i : make_range(-1, segments + 1)) + { + const auto p = p1 + Real(i) * dx * p1_to_p2; + + ElemCorner corner; + const auto within = IntersectionTools::within_edge(*elem, p, corner); + CPPUNIT_ASSERT_EQUAL(within, i >= 0 && i <= segments); + + if (mesh->mesh_dimension() == 3) + for (const auto s : elem->side_index_range()) + if (elem->is_edge_on_side(e, s)) + { + ElemCorner corner_on_side; + const auto within_on_side = IntersectionTools::within_edge_on_side(*elem, + p, + s, + corner_on_side); + + CPPUNIT_ASSERT_EQUAL(within_on_side, within); + CPPUNIT_ASSERT_EQUAL(corner_on_side.at_vertex(nodes_on_edge[0]), i == 0); + CPPUNIT_ASSERT_EQUAL(corner_on_side.at_vertex(nodes_on_edge[1]), i == segments); + CPPUNIT_ASSERT_EQUAL(corner_on_side.at_edge(*elem, e), i > 0 && i < segments); + } + } } - } // check elem centroids - for (const auto & elem : _mesh->active_local_element_ptr_range()) - { - const auto p = elem->vertex_average(); + for (const auto & mesh : _meshes) + for (const auto & elem : mesh->active_local_element_ptr_range()) + { + const auto p = elem->vertex_average(); - ElemCorner corner; - CPPUNIT_ASSERT(!IntersectionTools::within_edge(*elem, p, corner)); + ElemCorner corner; + CPPUNIT_ASSERT(!IntersectionTools::within_edge(*elem, p, corner)); - if (is_3d) - for (const auto s : elem->side_index_range()) - { - ElemCorner corner_on_side; - CPPUNIT_ASSERT(!IntersectionTools::within_edge_on_side(*elem, p, s, corner_on_side)); - } - } + if (mesh->mesh_dimension() == 3) + for (const auto s : elem->side_index_range()) + { + ElemCorner corner_on_side; + CPPUNIT_ASSERT(!IntersectionTools::within_edge_on_side(*elem, p, s, corner_on_side)); + } + } } }; From f6f8ba3c5b1917fe3655f31357408ac0910fbf41 Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Mon, 14 Nov 2022 16:40:35 -0700 Subject: [PATCH 26/30] Run collinear tests over a variety of scales --- tests/geom/intersection_tools_test.C | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/tests/geom/intersection_tools_test.C b/tests/geom/intersection_tools_test.C index 277819ffcdc..b854d7183bd 100644 --- a/tests/geom/intersection_tools_test.C +++ b/tests/geom/intersection_tools_test.C @@ -63,12 +63,19 @@ public: const Point & p3, const bool collinear) { - CPPUNIT_ASSERT_EQUAL(IntersectionTools::collinear(p1, p2, p3), collinear); - CPPUNIT_ASSERT_EQUAL(IntersectionTools::collinear(p1, p3, p2), collinear); - CPPUNIT_ASSERT_EQUAL(IntersectionTools::collinear(p2, p1, p3), collinear); - CPPUNIT_ASSERT_EQUAL(IntersectionTools::collinear(p2, p3, p1), collinear); - CPPUNIT_ASSERT_EQUAL(IntersectionTools::collinear(p3, p1, p2), collinear); - CPPUNIT_ASSERT_EQUAL(IntersectionTools::collinear(p3, p2, p1), collinear); + const std::vector scales{1e-8, 1, 1e8}; + for (const auto scale : scales) + { + const auto p1s = scale * p1; + const auto p2s = scale * p2; + const auto p3s = scale * p3; + CPPUNIT_ASSERT_EQUAL(IntersectionTools::collinear(p1s, p2s, p3s), collinear); + CPPUNIT_ASSERT_EQUAL(IntersectionTools::collinear(p1s, p3s, p2s), collinear); + CPPUNIT_ASSERT_EQUAL(IntersectionTools::collinear(p2s, p1s, p3s), collinear); + CPPUNIT_ASSERT_EQUAL(IntersectionTools::collinear(p2s, p3s, p1s), collinear); + CPPUNIT_ASSERT_EQUAL(IntersectionTools::collinear(p3s, p1s, p2s), collinear); + CPPUNIT_ASSERT_EQUAL(IntersectionTools::collinear(p3s, p2s, p1s), collinear); + } }; // two of the same points From 6fe24054b9c5b8609e496d270e525c9a95b984e6 Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Mon, 14 Nov 2022 16:40:44 -0700 Subject: [PATCH 27/30] Run within_segment tests over a variety of scales --- tests/geom/intersection_tools_test.C | 49 +++++++++++++++------------- 1 file changed, 27 insertions(+), 22 deletions(-) diff --git a/tests/geom/intersection_tools_test.C b/tests/geom/intersection_tools_test.C index b854d7183bd..6bc05ebbda6 100644 --- a/tests/geom/intersection_tools_test.C +++ b/tests/geom/intersection_tools_test.C @@ -28,30 +28,35 @@ public: { LOG_UNIT_TEST; - const Point s1(1.0, 2.0, 3.0); - const Point s2(2.0, 3.0, 4.0); - const auto length_vec = s2 - s1; - const auto length = length_vec.norm(); - const auto s1_to_s2 = length_vec / length; - - int segments = 10; - Real dx = (Real)1 / segments * length; - for (const auto i : make_range(-1, segments + 1)) + const std::vector scales{1.5e-7, 1, 1.5e7}; + for (const auto scale : scales) { - const auto p = s1 + Real(i) * dx * s1_to_s2; - IntersectionTools::WithinSegmentResult within_result = IntersectionTools::WithinSegmentResult::NOT_WITHIN; - if (i == 0) - within_result = IntersectionTools::WithinSegmentResult::AT_BEGINNING; - else if (i > 0 && i < segments) - within_result = IntersectionTools::WithinSegmentResult::BETWEEN; - else if (i == segments) - within_result = IntersectionTools::WithinSegmentResult::AT_END; - - CPPUNIT_ASSERT_EQUAL(IntersectionTools::within_segment(s1, s2, p), within_result); - } + const auto s1 = scale * Point(1.0, 2.0, 3.0); + const auto s2 = scale * Point(2.0, 3.0, 4.0); - CPPUNIT_ASSERT_EQUAL(IntersectionTools::within_segment(s1, s2, Point(9.9, 5, 3)), - IntersectionTools::WithinSegmentResult::NOT_WITHIN); + const auto length_vec = s2 - s1; + const auto length = length_vec.norm(); + const auto s1_to_s2 = length_vec / length; + + int segments = 10; + Real dx = (Real)1 / segments * length; + for (const auto i : make_range(-1, segments + 1)) + { + const auto p = s1 + (Real)i * dx * s1_to_s2; + IntersectionTools::WithinSegmentResult within_result = IntersectionTools::WithinSegmentResult::NOT_WITHIN; + if (i == 0) + within_result = IntersectionTools::WithinSegmentResult::AT_BEGINNING; + else if (i > 0 && i < segments) + within_result = IntersectionTools::WithinSegmentResult::BETWEEN; + else if (i == segments) + within_result = IntersectionTools::WithinSegmentResult::AT_END; + + CPPUNIT_ASSERT_EQUAL(IntersectionTools::within_segment(s1, s2, p), within_result); + } + + CPPUNIT_ASSERT_EQUAL(IntersectionTools::within_segment(s1, s2, scale * Point(9.9, 5, 3)), + IntersectionTools::WithinSegmentResult::NOT_WITHIN); + } } void collinear() From 889ffe8f956ecbf8e8b9bdf0f66cf06f72587b10 Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Tue, 15 Nov 2022 08:03:54 -0700 Subject: [PATCH 28/30] Add IntersectionTools::at_vertex methods --- include/geom/intersection_tools.h | 24 +++++++++++++ src/geom/intersection_tools.C | 26 +++++++++++++++ tests/geom/intersection_tools_test.C | 50 ++++++++++++++++++++++++++-- 3 files changed, 98 insertions(+), 2 deletions(-) diff --git a/include/geom/intersection_tools.h b/include/geom/intersection_tools.h index 0c14aed7ab9..5e018f4c1c1 100644 --- a/include/geom/intersection_tools.h +++ b/include/geom/intersection_tools.h @@ -119,6 +119,30 @@ bool within_edge_on_side(const Elem & elem, const bool linearize = false, const Real tol = TOLERANCE); +/** + * \returns The index of the vertex that the given point is at + * on the given element, invalid otherwise + * @param elem The element + * @param p The point + * @param tol The relative tolerance used in point comparison +*/ +unsigned short at_vertex(const Elem & elem, + const Point & p, + const Real tol = TOLERANCE); + +/** + * \returns The index of the vertex that the given point is at + * on the given element on the given side, invalid otherwise + * @param elem The element + * @param p The point + * @param s The side + * @param tol The relative tolerance used in point comparison +*/ +unsigned short at_vertex_on_side(const Elem & elem, + const Point & p, + const unsigned short s, + const Real tol = TOLERANCE); + namespace detail { /** diff --git a/src/geom/intersection_tools.C b/src/geom/intersection_tools.C index f47f7429f6b..775433ba14b 100644 --- a/src/geom/intersection_tools.C +++ b/src/geom/intersection_tools.C @@ -150,6 +150,32 @@ bool within_edge(const Elem & elem, return false; } +unsigned short at_vertex(const Elem & elem, + const Point & p, + const Real tol) +{ + for (const auto v : elem.vertex_index_range()) + if (elem.point(v).relative_fuzzy_equals(p, tol)) + return v; + return Elem::invalid_vertex; +} + +unsigned short at_vertex_on_side(const Elem & elem, + const Point & p, + const unsigned short s, + const Real tol) +{ + libmesh_assert_less(s, elem.n_sides()); + const unsigned int * side_node_map = elem.nodes_on_side_ptr(s); + for (const auto i : make_range(elem.n_vertices_on_side(s))) + { + const auto v = side_node_map[i]; + if (elem.point(v).relative_fuzzy_equals(p, tol)) + return v; + } + return Elem::invalid_vertex; +} + namespace detail { bool _within_edge(const Elem & elem, diff --git a/tests/geom/intersection_tools_test.C b/tests/geom/intersection_tools_test.C index 6bc05ebbda6..b71995b4248 100644 --- a/tests/geom/intersection_tools_test.C +++ b/tests/geom/intersection_tools_test.C @@ -229,10 +229,56 @@ public: } } + void test_at_vertex() + { + LOG_UNIT_TEST; + + // check locations at every node + for (const auto & mesh : _meshes) + for (const auto & elem : mesh->active_local_element_ptr_range()) + for (const auto n : elem->node_index_range()) + { + const auto & p = elem->point(n); + const auto is_vertex = elem->is_vertex(n); + const auto at_vertex = IntersectionTools::at_vertex(*elem, p); + + if (is_vertex) + CPPUNIT_ASSERT_EQUAL(at_vertex, (unsigned short)n); + else + CPPUNIT_ASSERT_EQUAL(at_vertex, Elem::invalid_vertex); + + for (const auto s : elem->side_index_range()) + { + const auto at_vertex_on_side = IntersectionTools::at_vertex_on_side(*elem, p, s); + if (is_vertex && elem->is_node_on_side(n, s)) + CPPUNIT_ASSERT_EQUAL(at_vertex_on_side, at_vertex); + else + CPPUNIT_ASSERT_EQUAL(at_vertex_on_side, Elem::invalid_vertex); + } + } + + // check edge centroids + for (const auto & mesh : _meshes) + if (mesh->mesh_dimension() > 1) + for (const auto & elem : mesh->active_local_element_ptr_range()) + for (const auto e : elem->edge_index_range()) + { + const auto edge = elem->build_edge_ptr(e); + const auto at_vertex = IntersectionTools::at_vertex(*elem, edge->vertex_average()); + CPPUNIT_ASSERT_EQUAL(at_vertex, Elem::invalid_vertex); + } + + // check elem centroids + for (const auto & mesh : _meshes) + for (const auto & elem : mesh->active_local_element_ptr_range()) + CPPUNIT_ASSERT_EQUAL(IntersectionTools::at_vertex(*elem, elem->centroid()), Elem::invalid_vertex); + } + }; -#define MESHEDINTERSECTIONTOOLSTEST \ - CPPUNIT_TEST( test_within_edge ); +#define MESHEDINTERSECTIONTOOLSTEST \ + CPPUNIT_TEST( test_within_edge ); \ + CPPUNIT_TEST( test_at_vertex ); #define INSTANTIATE_MESHEDINTERSECTIONTOOLSTEST(elemtype) \ class MeshedIntersectionToolsTest_##elemtype : public MeshedIntersectionToolsTest { \ From f6ed4b6a2f5f1d4da7ef1b3bbec24aca138f38d2 Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Tue, 15 Nov 2022 08:04:31 -0700 Subject: [PATCH 29/30] Add tolerance to docstring --- include/geom/intersection_tools.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/geom/intersection_tools.h b/include/geom/intersection_tools.h index 5e018f4c1c1..2ccba1e93c7 100644 --- a/include/geom/intersection_tools.h +++ b/include/geom/intersection_tools.h @@ -84,6 +84,7 @@ bool edges_are_collinear(const Elem & elem, const Real tol = TOLERANCE); * @param linearize Whether or not to "linearize" the check, if this * is set to false and edges are found to not be collinear, an error * is thrown + * @param tol Relative tolerance to use in comparison * * \p corner will be set to an "at vertex" state if the point is * both within the edge _and_ at a vertex. @@ -105,6 +106,7 @@ bool within_edge(const Elem & elem, * @param linearize Whether or not to "linearize" the check, if this * is set to false and edges are found to not be collinear, an error * is thrown + * @param tol Relative tolerance to use in comparison * * \p corner will be set to an "at vertex" state if the point is * both within the edge _and_ at a vertex. From ae116d809755b357dce795ff29d533ab11188b0d Mon Sep 17 00:00:00 2001 From: Logan Harbour Date: Tue, 15 Nov 2022 08:19:22 -0700 Subject: [PATCH 30/30] Add unit testing for ElemExtrema print and << --- tests/geom/elem_corner_test.C | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/tests/geom/elem_corner_test.C b/tests/geom/elem_corner_test.C index 9992ec14414..c8e5fc917f9 100644 --- a/tests/geom/elem_corner_test.C +++ b/tests/geom/elem_corner_test.C @@ -29,7 +29,11 @@ public: CPPUNIT_ASSERT(!default_corner.at_corner()); CPPUNIT_ASSERT(!default_corner.at_vertex()); CPPUNIT_ASSERT(!default_corner.at_edge()); - CPPUNIT_ASSERT_EQUAL((std::string)"not at corner", default_corner.print()); + const std::string default_corner_string = "not at corner"; + std::stringstream default_corner_ss; + default_corner_ss << default_corner; + CPPUNIT_ASSERT_EQUAL(default_corner_string, default_corner.print()); + CPPUNIT_ASSERT_EQUAL(default_corner_string, default_corner_ss.str()); // EDGE elem for vertex testing Mesh mesh_1d (*TestCommWorld); @@ -50,6 +54,11 @@ public: CPPUNIT_ASSERT_EQUAL(at_edge_vertex.at_vertex(v), v == 1); CPPUNIT_ASSERT_EQUAL(at_edge_vertex.is_valid(*edge, edge->point(v)), v == 1); } + const std::string at_vertex_string = "at vertex 1"; + std::stringstream at_vertex_ss; + at_vertex_ss << at_edge_vertex; + CPPUNIT_ASSERT_EQUAL(at_vertex_string, at_edge_vertex.print()); + CPPUNIT_ASSERT_EQUAL(at_vertex_string, at_vertex_ss.str()); #if LIBMESH_DIM > 1 // QUAD elem for vertex testing @@ -99,6 +108,11 @@ public: ((quad_edge_elem->point(0).absolute_fuzzy_equals(quad->point(2)) && quad_edge_elem->point(1).absolute_fuzzy_equals(quad->point(1))))); } + const std::string at_edge_string = "at edge with vertices 1 and 2"; + std::stringstream at_edge_ss; + at_edge_ss << at_quad_edge; + CPPUNIT_ASSERT_EQUAL(at_edge_string, at_quad_edge.print()); + CPPUNIT_ASSERT_EQUAL(at_edge_string, at_edge_ss.str()); #endif #if LIBMESH_DIM > 2