]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Dirty fix. 10218/head
authorLuca Heltai <luca.heltai@sissa.it>
Thu, 14 May 2020 20:57:21 +0000 (22:57 +0200)
committerMatthias Maier <tamiko@43-1.org>
Fri, 15 May 2020 00:27:18 +0000 (19:27 -0500)
source/grid/grid_tools.cc

index 5b41068c71979c4ad90067e671035440c20bc7d5..ce8fb651a4ca1c67e203306bfd3d6c8460be797b 100644 (file)
@@ -1724,9 +1724,13 @@ namespace GridTools
         // the user did not provide a hint_cell, and at the beginning of the
         // while loop we performed an actual global search on the mesh
         // vertices. Not finding the point then means the point is outside the
-        // domain.
-        AssertThrow(current_cell.state() == IteratorState::valid,
-                    ExcPointNotFound<spacedim>(p));
+        // domain, or that we've had problems with the algorithm above. Try as a
+        // last resort the other (simpler) algorithm.
+        if (current_cell.state() != IteratorState::valid)
+          return find_active_cell_around_point(mapping,
+                                               mesh,
+                                               p,
+                                               marked_vertices);
 
         current_cell = typename MeshType<dim, spacedim>::active_cell_iterator();
       }

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.