28#ifndef _CLASSIC_FIELDS_VECTORMAP_HH_
29#define _CLASSIC_FIELDS_VECTORMAP_HH_
51 virtual void function(
const double* point,
double* value)
const = 0;
66 const std::vector< std::vector<double> >& point_vec,
67 std::vector< std::vector<double> >& value_vec
71 inline virtual bool checkPoint(
const std::vector<double>& point)
const;
74 inline virtual bool checkValue(
const std::vector<double>& value)
const;
96 return (point.size() == this->getPointDimension());
100 return (value.size() == this->getValueDimension());
110 (
const std::vector< std::vector<double> >& point_vec,
111 std::vector< std::vector<double> >& value_vec)
const {
112 for (
size_t i = value_vec.size(); i < point_vec.size(); i++) {
114 function(&point_vec[i][0], &value_vec[i][0]);
Base class for meshing routines.
Used to loop over some, or all, points in the mesh, as in stl Enables e.g.
virtual void getPosition(double *point) const
Return the position referenced by the iterator;.
VectorMap is an abstract class that defines mapping from one vector to another.
virtual bool checkPoint(const std::vector< double > &point) const
Return true if point.size() is the same as this->PointDimension()
virtual unsigned int getValueDimension() const =0
Return the dimension of the value (output)
virtual Mesh * getMesh() const
Return the mesh used by the vector map or nullptr if no mesh.
virtual VectorMap * clone() const =0
Clone() is like a copy constructor - but copies the child class.
virtual unsigned int getPointDimension() const =0
Return the dimension of the point (input)
virtual ~VectorMap()
Destructor.
virtual bool checkValue(const std::vector< double > &value) const
Return true if value.size() is the same as this->ValueDimension()
virtual void function(const double *point, double *value) const =0
Pure virtual function to fill the array value with data evaluated at point.
virtual void functionAppend(const std::vector< std::vector< double > > &point_vec, std::vector< std::vector< double > > &value_vec) const
Calculate F, appending output values to value_vec.