From: Martin Kronbichler Date: Wed, 13 Dec 2017 13:19:52 +0000 (+0100) Subject: Make write_gnuplot_dof_support_point_info more robust by lexicographic indices with... X-Git-Tag: v9.0.0-rc1~659^2~1 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d9dd8faf803cfc056e514bf10d5ea70f9ca60940;p=dealii.git Make write_gnuplot_dof_support_point_info more robust by lexicographic indices with roundoff tolerance. --- diff --git a/source/dofs/dof_tools.cc b/source/dofs/dof_tools.cc index 7ad39de9c3..727a99eb4c 100644 --- a/source/dofs/dof_tools.cc +++ b/source/dofs/dof_tools.cc @@ -59,10 +59,10 @@ namespace DoFTools * "less" than the other one. This can be used to use Point as a key in * std::map. * - * Comparison is done by comparing values in each dimension in ascending - * order (first x, then y, etc.). Note that comparisons are done without an - * epsilon, so points need to have identical floating point components to be - * considered equal. + * Comparison is done through an artificial downstream direction that + * tells directions apart through a factor of 1e-5. The final comparison + * is done without an epsilon, so points need to have identical floating + * point components to be considered equal. */ template struct ComparisonHelper @@ -75,13 +75,14 @@ namespace DoFTools bool operator() (const Point &lhs, const Point &rhs) const { + double downstream_size = 0; + double weight = 1.; for (unsigned int d=0; d