Skip to content
Snippets Groups Projects
Commit 0f650ca6 authored by Elias Pipping's avatar Elias Pipping Committed by Elias Pipping
Browse files

Count nodes

parent dd9fbdf8
Branches
No related tags found
No related merge requests found
...@@ -105,6 +105,7 @@ int main() { ...@@ -105,6 +105,7 @@ int main() {
size_t neumann_nodes = 0; size_t neumann_nodes = 0;
size_t bounding_nodes = 0; size_t bounding_nodes = 0;
size_t extremal_nodes = 0; size_t extremal_nodes = 0;
size_t overall_nodes = 0;
for (VertexLeafIterator it = leafView.begin<dim>(); for (VertexLeafIterator it = leafView.begin<dim>();
it != leafView.end<dim>(); ++it) { it != leafView.end<dim>(); ++it) {
Dune::GeometryType gt = it->type(); Dune::GeometryType gt = it->type();
...@@ -112,6 +113,7 @@ int main() { ...@@ -112,6 +113,7 @@ int main() {
SmallVector coordinates = it->geometry().corner(0); SmallVector coordinates = it->geometry().corner(0);
bool bounding(false); bool bounding(false);
bool extremal(true); bool extremal(true);
++overall_nodes;
for (int i = 0; i < dim; ++i) { for (int i = 0; i < dim; ++i) {
if (coordinates[i] == end_points[i] || coordinates[i] == 0) { if (coordinates[i] == end_points[i] || coordinates[i] == 0) {
bounding = true; bounding = true;
...@@ -152,6 +154,7 @@ int main() { ...@@ -152,6 +154,7 @@ int main() {
<< std::endl; << std::endl;
std::cout << "Number of bounding nodes: " << bounding_nodes << std::endl; std::cout << "Number of bounding nodes: " << bounding_nodes << std::endl;
std::cout << "Number of extremal nodes: " << extremal_nodes << std::endl; std::cout << "Number of extremal nodes: " << extremal_nodes << std::endl;
std::cout << "Number of nodes: " << overall_nodes << std::endl;
} }
// TODO: populate on S_F // TODO: populate on S_F
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment