From: Martin Kronbichler Date: Thu, 2 Nov 2017 12:57:39 +0000 (+0100) Subject: Implement ChartManifold::get_intermediate_point. X-Git-Tag: v9.0.0-rc1~834^2~2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e9e63d0b6db7b0c60b4707ed2f14247bd73e4ff8;p=dealii.git Implement ChartManifold::get_intermediate_point. --- diff --git a/include/deal.II/grid/manifold.h b/include/deal.II/grid/manifold.h index b2942a514d..02dd9a4214 100644 --- a/include/deal.II/grid/manifold.h +++ b/include/deal.II/grid/manifold.h @@ -930,6 +930,16 @@ public: */ virtual ~ChartManifold () = default; + /** + * Refer to the general documentation of this class and the documentation of + * the base class for more information. + */ + virtual + Point + get_intermediate_point (const Point &p1, + const Point &p2, + const double w) const override; + /** * Refer to the general documentation of this class and the documentation of * the base class for more information. diff --git a/source/grid/manifold.cc b/source/grid/manifold.cc index 5175500f25..5940478ad5 100644 --- a/source/grid/manifold.cc +++ b/source/grid/manifold.cc @@ -693,6 +693,21 @@ ChartManifold::ChartManifold (const Tensor<1,chartdim> &p +template +Point +ChartManifold:: +get_intermediate_point (const Point &p1, + const Point &p2, + const double w) const +{ + const std::array, 2> points({{p1, p2}}); + const std::array weights({{1.-w, w}}); + return get_new_point(make_array_view(points.begin(), points.end()), + make_array_view(weights.begin(), weights.end())); +} + + + template Point ChartManifold::