14 this->reserve(obj.size());
20 this->reserve(obj.size());
26 if(end_step == 0) end_step =
size() - 1;
29 if(start_step >= end_step)
throw GeoAlgoException(
"Cannot have start step >= end step!");
34 if(
size()<2)
return 0;
37 for(
size_t i=start_step; i<end_step; ++i)
39 length += (*
this)[i]._Dist_((*
this)[i+1]);
46 if(
size()<2)
return false;
49 for(
size_t i=0; i<
size()-1; ++i) {
51 length += (*this)[i]._Dist_((*
this)[i+1]);
53 if(length > ref)
return true;
61 if (!(
size() && obj == (*rbegin())))
62 std::vector<geoalgo::Point_t>::push_back(obj);
68 if( (*(this->
begin())).
size() != obj.size() ) {
70 std::ostringstream
msg;
71 msg <<
"<<" << __FUNCTION__ <<
">>"
73 << (*(this->
begin())).size() <<
" != " << obj.size() << std::endl;
80 if(!
size() || !(obj.size()))
return;
84 std::ostringstream
msg;
85 msg <<
"<<" << __FUNCTION__ <<
">>"
87 << (*(this->
begin())).size() <<
" != " << (*obj.begin()).
size() << std::endl;
96 std::ostringstream
msg;
97 msg <<
"<<" << __FUNCTION__ <<
">>"
98 <<
" length=" <<
size() <<
" is too short to find a direction @ index=" << i << std::endl;
106 return ((*
this)[i+1] - (*
this)[i]);
double std(const std::vector< short > &wf, const double ped_mean, size_t start, size_t nsample)
void compat(const Point_t &obj) const
Dimensionality check function w/ Trajectory.
std::size_t size(FixedBins< T, C > const &) noexcept
Trajectory(size_t npoints=0, size_t ndimension=0)
Default ctor to specify # points and dimension of each point.
void push_back(const Point_t &obj)
push_back overrie w/ dimensionality check
auto vector(Vector const &v)
Returns a manipulator which will print the specified array.
auto begin(FixedBins< T, C > const &) noexcept
double Length(size_t start_step=0, size_t end_step=0) const
The summed-length along all trajectory points.
Vector Dir(size_t i=0) const
The direction at a specified trajectory point.
bool IsLonger(double) const
Check if the trajectory is longer than specified value.
Vector _Dir_(size_t i) const
Returns a direction vector at a specified trajectory point w/o size check.