28 #include "../../../datatype/AbstractData.h" 29 #include "../../../datatype/SimpleData.h" 30 #include "../../../geometry/Point.h" 34 #include "../coverage/PointCoverage.h" 42 std::vector<double>
di;
43 std::vector<double> vi;
50 double distance = point.
distance(&l);
53 d = 1/(distance * distance);
63 for(
unsigned int i = 0; i< di.size(); ++i)
65 double wi = di[i]/sumdi;
69 return std::unique_ptr<te::dt::AbstractData>(
new te::dt::Double(result));
A concrete class to represent a point coverage.
PointCoverageIterator end() const
It returns an iterator that points to the end of the time series.
virtual double distance(const Geometry *const rhs) const _NOEXCEPT_OP(false)
It returns the shortest distance between any two points in the two geometry objects.
std::unique_ptr< te::dt::AbstractData > estimate(const PointCoverage &cv, unsigned int p, const te::gm::Point &l)
It estimates a value at a given non-observed location, in a PointCoverage.
This file contains an inverse distance weighted (IDW) interpolationan function for PointCoverage...
IDWInterpolator()
Constructor.
A class to traverse the observations of a PointCoverage.
A point with x and y coordinate values.
virtual ~IDWInterpolator()
Virtual destructor.
static te::dt::DateTime d(2010, 8, 9, 15, 58, 39)
static te::dt::Date di(2010, 06, 10)
double getDouble(int i) const
It returns the i-th attribute value as a double pointed by the internal cursor.
PointCoverageIterator begin() const
It returns an iterator that points to the first observation of the point coverage.
SimpleData< double, DOUBLE_TYPE > Double
te::gm::Point & getLocation() const
It returns the location pointed by the internal cursor.