From 1f4e0ca6298f790edcf3348714d6e2cda74c9a13 Mon Sep 17 00:00:00 2001
From: Norihiro Watanabe <norihiro.watanabe@ufz.de>
Date: Wed, 28 Jan 2015 13:28:09 +0100
Subject: [PATCH] correct documentation

---
 MeshLib/Elements/Cell.cpp          | 4 ++++
 MeshLib/Elements/CellRule.cpp      | 4 ++++
 MeshLib/Elements/Element.h         | 1 +
 MeshLib/Elements/HexRule8.h        | 2 +-
 MeshLib/Elements/LineRule2.h       | 2 +-
 MeshLib/Elements/PrismRule6.h      | 2 +-
 MeshLib/Elements/PyramidRule5.h    | 2 +-
 MeshLib/Elements/QuadRule4.h       | 2 +-
 MeshLib/Elements/TemplateElement.h | 2 +-
 MeshLib/Elements/TetRule4.h        | 2 +-
 MeshLib/Elements/TriRule3.h        | 2 +-
 11 files changed, 17 insertions(+), 8 deletions(-)

diff --git a/MeshLib/Elements/Cell.cpp b/MeshLib/Elements/Cell.cpp
index b1f86db40f5..02f4d763249 100644
--- a/MeshLib/Elements/Cell.cpp
+++ b/MeshLib/Elements/Cell.cpp
@@ -35,6 +35,10 @@ bool Cell::testElementNodeOrder() const
 	for (unsigned j=0; j<nFaces; ++j)
 	{
 		MeshLib::Face const*const face (dynamic_cast<const MeshLib::Face*>(this->getFace(j)));
+		// Node 1 is checked below because that way all nodes are used for the test
+		// at some point, while for node 0 at least one node in every element
+		// type would be used for checking twice and one wouldn't be checked at
+		// all. (based on the definition of the _face_nodes variable)
 		const MeshLib::Node x (*(face->getNode(1)));
 		const MathLib::Vector3 cx (c, x);
 		const double s = MathLib::scalarProduct(face->getSurfaceNormal(), cx);
diff --git a/MeshLib/Elements/CellRule.cpp b/MeshLib/Elements/CellRule.cpp
index 9fa8ea6ba90..b90792e3714 100644
--- a/MeshLib/Elements/CellRule.cpp
+++ b/MeshLib/Elements/CellRule.cpp
@@ -28,6 +28,10 @@ bool CellRule::testElementNodeOrder(const Element* e)
 	for (unsigned j=0; j<nFaces; ++j)
 	{
 		MeshLib::Face const*const face (dynamic_cast<const MeshLib::Face*>(e->getFace(j)));
+		// Node 1 is checked below because that way all nodes are used for the test
+		// at some point, while for node 0 at least one node in every element
+		// type would be used for checking twice and one wouldn't be checked at
+		// all. (based on the definition of the _face_nodes variable)
 		const MeshLib::Node x (*(face->getNode(1)));
 		const MathLib::Vector3 cx (c, x);
 		const double s = MathLib::scalarProduct(face->getSurfaceNormal(), cx);
diff --git a/MeshLib/Elements/Element.h b/MeshLib/Elements/Element.h
index 6f8c856e039..2303b9d81c0 100644
--- a/MeshLib/Elements/Element.h
+++ b/MeshLib/Elements/Element.h
@@ -225,6 +225,7 @@ protected:
 
 	Node** _nodes;
 	std::size_t _id;
+	/// Content corresponds to length for 1D, area for 2D, and volume for 3D elements
 	double _content;
 	/**
 	 * this is an index for external additional information like materials
diff --git a/MeshLib/Elements/HexRule8.h b/MeshLib/Elements/HexRule8.h
index 80169dc8953..afa16dc8a7a 100644
--- a/MeshLib/Elements/HexRule8.h
+++ b/MeshLib/Elements/HexRule8.h
@@ -84,7 +84,7 @@ public:
 
 	/**
 	 * Checks if a point is inside the element.
-	 * @param pnt a 3D GeoLib::Point object
+	 * @param pnt a 3D MathLib::Point3D object
 	 * @param eps tolerance for numerical algorithm used or computing the property
 	 * @return true if the point is not outside the element, false otherwise
 	 */
diff --git a/MeshLib/Elements/LineRule2.h b/MeshLib/Elements/LineRule2.h
index 6dc8ec0241c..a24b78f836c 100644
--- a/MeshLib/Elements/LineRule2.h
+++ b/MeshLib/Elements/LineRule2.h
@@ -64,7 +64,7 @@ public:
 
 	/**
 	 * Checks if a point is inside the element.
-	 * @param pnt a 3D GeoLib::Point object
+	 * @param pnt a 3D MathLib::Point3d object
 	 * @param eps tolerance for numerical algorithm used or computing the property
 	 * @return true if the point is not outside the element, false otherwise
 	 */
diff --git a/MeshLib/Elements/PrismRule6.h b/MeshLib/Elements/PrismRule6.h
index f533939681f..7ba50dc0bf1 100644
--- a/MeshLib/Elements/PrismRule6.h
+++ b/MeshLib/Elements/PrismRule6.h
@@ -85,7 +85,7 @@ public:
 
 	/**
 	 * Checks if a point is inside the element.
-	 * @param pnt a 3D GeoLib::Point object
+	 * @param pnt a 3D MathLib::Point3d object
 	 * @param eps tolerance for numerical algorithm used or computing the property
 	 * @return true if the point is not outside the element, false otherwise
 	 */
diff --git a/MeshLib/Elements/PyramidRule5.h b/MeshLib/Elements/PyramidRule5.h
index 069bdec6105..3ad691fa79f 100644
--- a/MeshLib/Elements/PyramidRule5.h
+++ b/MeshLib/Elements/PyramidRule5.h
@@ -84,7 +84,7 @@ public:
 
 	/**
 	 * Checks if a point is inside the element.
-	 * @param pnt a 3D GeoLib::Point object
+	 * @param pnt a 3D MathLib::Point3d object
 	 * @param eps tolerance for numerical algorithm used or computing the property
 	 * @return true if the point is not outside the element, false otherwise
 	 */
diff --git a/MeshLib/Elements/QuadRule4.h b/MeshLib/Elements/QuadRule4.h
index 57386880994..5bc9b16c977 100644
--- a/MeshLib/Elements/QuadRule4.h
+++ b/MeshLib/Elements/QuadRule4.h
@@ -66,7 +66,7 @@ public:
 
 	/**
 	 * Checks if a point is inside the element.
-	 * @param pnt a 3D GeoLib::Point object
+	 * @param pnt a 3D MathLib::Point3d object
 	 * @param eps tolerance for numerical algorithm used or computing the property
 	 * @return true if the point is not outside the element, false otherwise
 	 */
diff --git a/MeshLib/Elements/TemplateElement.h b/MeshLib/Elements/TemplateElement.h
index ed16bf2ab98..9826bdbd8f9 100644
--- a/MeshLib/Elements/TemplateElement.h
+++ b/MeshLib/Elements/TemplateElement.h
@@ -109,7 +109,7 @@ public:
 
 	/**
 	 * Checks if a point is inside the element.
-	 * @param pnt a 3D GeoLib::Point object
+	 * @param pnt a 3D MathLib::Point3d object
 	 * @param eps tolerance for numerical algorithm used or computing the property
 	 * @return true if the point is not outside the element, false otherwise
 	 */
diff --git a/MeshLib/Elements/TetRule4.h b/MeshLib/Elements/TetRule4.h
index 4e94b3a09da..eeb3b56c5c4 100644
--- a/MeshLib/Elements/TetRule4.h
+++ b/MeshLib/Elements/TetRule4.h
@@ -79,7 +79,7 @@ public:
 
 	/**
 	 * Checks if a point is inside the element.
-	 * @param pnt a 3D GeoLib::Point object
+	 * @param pnt a 3D MathLib::Point3d object
 	 * @param eps tolerance for numerical algorithm used or computing the property
 	 * @return true if the point is not outside the element, false otherwise
 	 */
diff --git a/MeshLib/Elements/TriRule3.h b/MeshLib/Elements/TriRule3.h
index 1352c6d0aaf..23aa1c0aab0 100644
--- a/MeshLib/Elements/TriRule3.h
+++ b/MeshLib/Elements/TriRule3.h
@@ -67,7 +67,7 @@ public:
 
 	/**
 	 * Checks if a point is inside the element.
-	 * @param pnt a 3D GeoLib::Point object
+	 * @param pnt a 3D MathLib::Point3d object
 	 * @param eps tolerance for numerical algorithm used or computing the property
 	 * @return true if the point is not outside the element, false otherwise
 	 */
-- 
GitLab