![]() |
UNIVERS
15.3
UNIVERS base processing software API
|
#include <u_smooth_cubic_spline1d.hpp>
Classes | |
| struct | Coeffs |
Public Member Functions | |
| SmoothCubicSpline1d () | |
| SmoothCubicSpline1d (const U2dWPoints &nodes, double alpha) | |
| virtual | ~SmoothCubicSpline1d () |
| virtual double | operator() (double x) const |
| virtual void | approximate (const U2dWPoints &nodes, double alpha) |
| virtual bool | ready () const |
| virtual void | addNode (const U2dWPoint &, int) |
| virtual bool | removeNode (size_t) |
Protected Types | |
| typedef std::vector< Coeffs > | CoeffsAr |
Protected Member Functions | |
| double | Am (size_t i, size_t j, const U2dWPoints &nodes) const |
| double | Hm (size_t i, size_t j, const std::vector< double > &delta_vec) const |
| double | Km (size_t i, size_t j, const U2dWPoints &nodes) const |
| double | bv (size_t i, const U2dWPoints &nodes) const |
| bool | calc_coeffs (const U2dWPoints &nodes, double alpha, CoeffsAr &coeffs) |
| double | get_s (double x) const |
Protected Attributes | |
| CoeffsAr | m_coeffs |
| U2dBox | m_bound |
| bool | m_ready |
Calculates 1D smooth spline with weights for provided nodes. Number of nodes should be > 3, with different x-coordinates
|
protected |
Spline coefficients
| SmoothCubicSpline1d::SmoothCubicSpline1d | ( | ) |
Empty curve
| SmoothCubicSpline1d::SmoothCubicSpline1d | ( | const U2dWPoints & | nodes, |
| double | alpha | ||
| ) |
Construct curve width provided nodes
|
virtual |
Destructor.
|
inlinevirtual |
Add new point to the curve at index = id. If id < 0 or out of range then add new last point.
Implements UCurve1d< U2dWPoint >.
|
virtual |
General approximation method
|
protected |
Calculate spline coefficients
|
inlineprotected |
Calculates spline on corresponded segment
|
virtual |
Get curve value for provided argument
Implements UCurve1d< U2dWPoint >.
|
inlinevirtual |
True if spline constructed and object is ready to approximate
Implements UCurve1d< U2dWPoint >.
|
inlinevirtual |
Remove node with provided id. Return false on error.
Implements UCurve1d< U2dWPoint >.
|
protected |
Is object ready
|
protected |
Curve boundaries (z-coordinate is only form boundaries points)
1.8.5