From: michael Date: Mon, 17 May 2021 07:58:33 +0000 (+0200) Subject: Added a function Field::getFieldValues X-Git-Tag: V9_7_0~10 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=3652faf5ff1c9520d8383c1f6bfd5f636835e2b1;p=tools%2Fsolverlab.git Added a function Field::getFieldValues --- diff --git a/CDMATH/mesh/inc/Field.hxx b/CDMATH/mesh/inc/Field.hxx index 70cfc80..bc4ff85 100755 --- a/CDMATH/mesh/inc/Field.hxx +++ b/CDMATH/mesh/inc/Field.hxx @@ -257,6 +257,8 @@ class Field void setTime ( double time, int iter ); + std::vector< double > getFieldValues(int compo=0) const ; + Vector getValuesOnComponent(int compo) const ; Vector getValuesOnAllComponents(int elem) const ; diff --git a/CDMATH/mesh/src/Field.cxx b/CDMATH/mesh/src/Field.cxx index 2934d6a..b7a4e94 100755 --- a/CDMATH/mesh/src/Field.cxx +++ b/CDMATH/mesh/src/Field.cxx @@ -1108,6 +1108,15 @@ Field::getValuesOnComponent(int compo) const return v; } +std::vector< double > +Field::getFieldValues(int compo) const +{ + std::vector< double > v(getNumberOfElements()); + for(int i=0;i