|
libcrn
3.9.5
A document image processing library
|
Polynomial regression. More...
#include <CRNPolynomialRegression.h>
Inheritance diagram for crn::PolynomialRegression:
Collaboration diagram for crn::PolynomialRegression:Public Types | |
| enum | Extrapolation { Extrapolation::LINEAR, Extrapolation::POLY } |
| Extrapolation modes. More... | |
Public Member Functions | |
| template<typename Iter > | |
| PolynomialRegression (Iter beg, Iter en, size_t dim) | |
| Constructor from a list of points. More... | |
| PolynomialRegression (const PolynomialRegression &)=default | |
| PolynomialRegression (PolynomialRegression &&)=default | |
| PolynomialRegression & | operator= (const PolynomialRegression &)=default |
| PolynomialRegression & | operator= (PolynomialRegression &&)=default |
| virtual | ~PolynomialRegression () override |
| void | SetExtrapolationMode (Extrapolation ex) noexcept |
| Sets the behaviour for points before the first control point and after the last control point. More... | |
| void | TranslateY (int increment) |
| Translates the polynomial. More... | |
| virtual double | operator[] (double x) const override |
| Gets ordinate at x (double) More... | |
| size_t | GetDimension () const noexcept |
| Returns the dimension of the polynomial. More... | |
| const std::vector < crn::Point2DDouble > & | GetData () const noexcept |
| Access to the sorted control point. More... | |
| const std::vector< double > & | GetCoefficients () const noexcept |
| Access to the coefficients of the polynomial. More... | |
Public Member Functions inherited from crn::Cartesian2DFunction | |
| virtual | ~Cartesian2DFunction () override |
| virtual int | operator[] (int x) const |
| Gets ordinate at x. More... | |
Public Member Functions inherited from crn::Object | |
| virtual | ~Object ()=default |
Polynomial regression.
Creates a polynomial function representing a cloud of points.
Definition at line 40 of file CRNPolynomialRegression.h.
|
strong |
|
inline |
Constructor from a list of points.
| crn::ExceptionDomain | the order of the polynomial is null |
| crn::ExceptionDimension | not enough samples |
| [in] | beg | the first element |
| [in] | en | the element after the last |
| [in] | dim | the dimension of the regression polynomial |
Definition at line 53 of file CRNPolynomialRegression.h.
|
default |
|
default |
|
inlineoverridevirtual |
Definition at line 72 of file CRNPolynomialRegression.h.
|
inlinenoexcept |
Access to the coefficients of the polynomial.
Definition at line 90 of file CRNPolynomialRegression.h.
|
inlinenoexcept |
Access to the sorted control point.
Definition at line 88 of file CRNPolynomialRegression.h.
|
inlinenoexcept |
Returns the dimension of the polynomial.
Definition at line 86 of file CRNPolynomialRegression.h.
|
default |
|
default |
|
overridevirtual |
Gets ordinate at x (double)
Implements crn::Cartesian2DFunction.
Definition at line 70 of file CRNPolynomialRegression.cpp.
|
inlinenoexcept |
Sets the behaviour for points before the first control point and after the last control point.
Definition at line 75 of file CRNPolynomialRegression.h.
| void PolynomialRegression::TranslateY | ( | int | increment | ) |
Translates the polynomial.
Translates the polynomial
| [in] | increment | the vertical shift |
Definition at line 31 of file CRNPolynomialRegression.cpp.
1.8.6