Public Member Functions |
Static Public Member Functions |
Protected Member Functions |
Protected Attributes

towr::Spline Class Reference

A spline built from a sequence of cubic polynomials. More...

`#include <spline.h>`

Inheritance diagram for towr::Spline:

## Public Member Functions | |

const State | GetPoint (double t) const |

const State | GetPoint (int poly_id, double t_local) const |

VecTimes | GetPolyDurations () const |

int | GetPolynomialCount () const |

double | GetTotalTime () const |

Spline (const VecTimes &poly_durations, int n_dim) | |

virtual | ~Spline () |

## Static Public Member Functions | |

static int | GetSegmentID (double t_global, const VecTimes &durations) |

## Protected Member Functions | |

std::pair< int, double > | GetLocalTime (double t_global, const VecTimes &d) const |

How much time of the current segment has passed at t_global. | |

void | UpdatePolynomialCoeff () |

Updates the cubic-Hermite polynomial coefficients using the currently set nodes values and durations. | |

## Protected Attributes | |

VecPoly | cubic_polys_ |

the sequence of polynomials making up the spline. |

A spline built from a sequence of cubic polynomials.

This class is responsible for stitching together multiple individual polynomials into one spline.

towr::Spline::Spline | ( | const VecTimes & | poly_durations, |

int | n_dim |
||

) |

virtual towr::Spline::~Spline | ( | ) | ` [virtual]` |

std::pair< int, double > towr::Spline::GetLocalTime | ( | double | t_global, |

const VecTimes & | d |
||

) | const` [protected]` |

const State towr::Spline::GetPoint | ( | double | t | ) | const |

const State towr::Spline::GetPoint | ( | int | poly_id, |

double | t_local |
||

) | const |

**Parameters:**-
poly_id Polynomial id, 0 is first polynomial. t_local Time along the current polynomial.

**Returns:**- The position, velocity and acceleration of spline.

Spline::VecTimes towr::Spline::GetPolyDurations | ( | ) | const |

int towr::Spline::GetPolynomialCount | ( | ) | const |

int towr::Spline::GetSegmentID | ( | double | t_global, |

const VecTimes & | durations |
||

) | ` [static]` |

double towr::Spline::GetTotalTime | ( | ) | const |

void towr::Spline::UpdatePolynomialCoeff | ( | ) | ` [protected]` |

VecPoly towr::Spline::cubic_polys_` [protected]` |

The documentation for this class was generated from the following files: