]> https://gitweb.dealii.org/ - dealii.git/commitdiff
fix assert for 2d mesh 12532/head
authorJiaqi Zhang <jiaqi2@clemson.edu>
Thu, 1 Jul 2021 14:48:55 +0000 (14:48 +0000)
committerJiaqi Zhang <jiaqi2@clemson.edu>
Thu, 1 Jul 2021 14:48:55 +0000 (14:48 +0000)
source/grid/grid_in.cc

index a49a6af20f91649e7b02e20d008d1f4a0a097d71..71268f7b1e002d87a2d73d29177a57a96b7997f8 100644 (file)
@@ -2173,7 +2173,7 @@ GridIn<dim, spacedim>::read_msh(const std::string &fname)
 #  ifdef DEBUG
         // Make sure the embedded dimension is right
         for (unsigned int d = spacedim; d < 3; ++d)
-          Assert(coord[i * 3 + d] == 0,
+          Assert(std::abs(coord[i * 3 + d]) < 1e-10,
                  ExcMessage("The grid you are reading contains nodes that are "
                             "nonzero in the coordinate with index " +
                             std::to_string(d) +

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.