|
C3D Toolkit
Kernel - 118069, Vision - 2.16.7.1844
|
Cubic Hermite function. More...
#include <func_cubic_function.h>
Inheritance diagram for MbCubicFunction:
Collaboration diagram for MbCubicFunction:Public Member Functions | |
| MbCubicFunction (const SArray< double > &values, bool cls) | |
| Constructor by points and an attribute of closedness. | |
| MbCubicFunction (const SArray< double > &values, const SArray< double > ¶ms, bool cls) | |
| Constructor by points, parameters and an attribute of closedness. | |
| MbCubicFunction (const SArray< double > &values, const SArray< double > &firsts, const SArray< double > ¶ms, bool cls) | |
| Constructor by points, derivatives, parameters and an attribute of closedness. | |
| MbCubicFunction (double value1, double value2) | |
| Constructor by two points. | |
| MbCubicFunction (double value1, double derive1, double t1, double value2, double derive2, double t2) | |
| Constructor by two points. | |
| void | Init (const SArray< double > &values, const SArray< double > ¶ms, bool cls) |
| Initialization by points, parameters and an attribute of closedness. | |
| bool | InitMonotonic (const SArray< double > &values, const SArray< double > ¶ms, bool valClosed, VERSION vers=Math::DefaultMathVersion()) |
| Monotone spline initialization. | |
| bool | Init (bool mono, bool cls, const SArray< double > ¶ms, const SArray< double > &values, const SArray< double > *ders, VERSION vers=Math::DefaultMathVersion()) |
| Function initialization. More... | |
| MbeFunctionType | IsA () const override |
| A type of element. | |
| MbFunction & | Duplicate () const override |
| Create a copy of the element. | |
| bool | IsSame (const MbFunction &other, double accuracy=LENGTH_EPSILON) const override |
| Determine whether objects are equal. | |
| bool | SetEqual (const MbFunction &) override |
| Make equal. | |
| void | GetProperties (MbProperties &) override |
| Get properties of the object. | |
| void | SetProperties (const MbProperties &) override |
| Set properties of the object. | |
| double | GetTMax () const override |
| Get the maximum value of parameter. | |
| double | GetTMin () const override |
| Get the minimum value of parameter. | |
| bool | IsClosed () const override |
| Get the closeness of a function. | |
| void | SetClosed (bool cl) override |
| Set the closeness of a function. | |
| double | Value (double &t) const override |
| The value of function for a given t. | |
| double | FirstDer (double &t) const override |
| The first derivative with respect to t. | |
| double | SecondDer (double &t) const override |
| The second derivative with respect to t. | |
| double | ThirdDer (double &t) const override |
| The third derivative with respect to t. | |
| double | _Value (double t) const override |
| The value of extended function for a given t. | |
| double | _FirstDer (double t) const override |
| The first derivative of extended function with respect to t. | |
| double | _SecondDer (double t) const override |
| The second derivative of extended function with respect to t. | |
| double | _ThirdDer (double t) const override |
| The third derivative of extended function with respect to t. | |
| void | Explore (double &t, bool ext, double &val, double &fir, double *sec, double *thr) const override |
| Calculate value and derivatives of object for given parameter. More... | |
| void | Inverse (MbRegTransform *iReg=nullptr) override |
| Change direction. | |
| double | Step (double t, double sag) const override |
| Calculate a step by the sag for a given parameter t. | |
| double | DeviationStep (double t, double angle) const override |
| Calculate a step by the angular deviation for a given parameter t. | |
| double | MinValue (double &t) const override |
| The minimum value of function. | |
| double | MaxValue (double &t) const override |
| The maximum value of function. | |
| double | MidValue () const override |
| The middle value of function. | |
| bool | IsGood () const override |
| Correctness of function. | |
| bool | IsConst () const override |
| Whether the function is constant. | |
| bool | IsLine () const override |
| Whether the function is linear. | |
| void | SetOffsetFunc (double off, double scale) override |
| Shift a function. | |
| bool | SetLimitParam (double newTMin, double newTMax) override |
| Set the range of parameter. | |
| void | SetLimitValue (size_t n, double newValue) override |
| Set the value at the end (1 - at start point, 2 - at end point). | |
| double | GetLimitValue (size_t n) const override |
| Get the value at the end (1 - at start point, 2 - at end point). | |
| void | SetLimitDerive (size_t n, double newValue, double dt) override |
| Set the value of derivative at the end (1 - at start point, 2 - at end point). | |
| double | GetLimitDerive (size_t n) const override |
| Get the value of derivative at the end (1 - at start point, 2 - at end point). | |
| bool | InsertValue (double t, double newValue) override |
| Set the value for the parameter t. | |
| MbFunction * | Trimmed (double t1, double t2, int sense) const override |
| Create a function in part of the function between the parameters t1 and t2 choosing the direction. | |
| MbFunction * | BreakFunction (double t, bool beg) override |
| Function break by the parameter t, and cut off part of the function: begs == true - save the initial half, beg == false - save the final half. | |
| MbFunction * | Break (double t1, double t2) const |
| Select a part of a function. | |
| size_t | GetParamsCount () const |
| Get count of parameters. | |
| void | GetTList (SArray< double > ¶ms) const |
| Get parameters tList. | |
| void | GetValueList (SArray< double > &vals) const |
| Get array of control values. | |
Public Member Functions inherited from MbFunction | |
| bool | IsZero (double t, double accuracy=METRIC_REGION) const |
| The presence of a null function value. | |
| double | GetTMid () const |
| Return the middle of parametric range. | |
| double | GetParamLength () const |
| The parametric length. | |
| bool | IsParamOn (double t, double eps) const |
| Whether the parameter belongs to the function domain. | |
| void | PrepareWrite () const |
| Prepare for writing the registered object. | |
| virtual bool | IsSimilar (const MbFunction &) const |
| Determine whether objects are similar. | |
| virtual bool | IsPeriodic () const |
| Periodicity of a closed curve. | |
| MbeNewtonResult | ArgumentNewton (double value, bool ext, double funcEpsilon, size_t iterLimit, double &t) const |
| bool | CuttingFunction (SArray< double > ¶ms, bool beginSafe, double eps, RPArray< MbFunction > &cutted) |
| Function break by the parameters: begs == true - save the initial half, beg == false - save the final half. | |
| virtual void | GetCharacteristicParams (std::vector< double > &tSpecific, double t1, double t2) const |
| Get the parameters of special behaviour on the interval from t1 to t2 (for cos it is Pi*n). | |
| virtual void | BreakPoints (std::vector< double > &vBreaks, double precision=ANGLE_REGION) const |
| \ ru Определение точек излома функции. The determination of function smoothness break points. | |
Public Member Functions inherited from MbRefItem | |
| virtual MbeRefType | RefType () const |
| Registration type (for copying, duplication). | |
| void | AddRegistrator (MbRegDuplicate *reg) const |
| Add the register. | |
| void | RemoveRegistrator (MbRegDuplicate *reg) const |
| Remove the register. | |
| refcount_t | GetUseCount () const |
| Get count of references (get count of owners of an object). | |
| refcount_t | AddRef () const |
| Increase count of references by one. | |
| refcount_t | DecRef () const |
| Decrease count of references by one. | |
| refcount_t | Release () const |
| Decrease count of references by one and if count of references became zero, then remove itself. | |
Public Member Functions inherited from TapeBase | |
| TapeBase (RegistrableRec regs=noRegistrable) | |
| Constructor. | |
| TapeBase (const TapeBase &) | |
| Copy-constructor. | |
| virtual | ~TapeBase () |
| Destructor. | |
| RegistrableRec | GetRegistrable () const |
| Whether the stream class is registrable. | |
| void | SetRegistrable (RegistrableRec regs=registrable) const |
| Set the state of registration of the stream class. | |
| virtual const char * | GetPureName (const VersionContainer &) const |
| Get the class name. | |
| virtual bool | IsFamilyRegistrable () const |
| Whether the object belongs to a registrable family. | |
Protected Attributes | |
| SArray< double > | valueList |
| The control points. | |
| SArray< double > | firstList |
| The derivatives in control points. | |
| SArray< double > | tList |
| The values of parameters on a function which is modeled by a cubic spline. | |
| bool | monotonic |
| The sign of monotonicity of a set of values. | |
| bool | closed |
| For a non-monotonic set of values, the sign of closeness to the initial value. For a monotonic set of values, the sign of periodicity of a monotonic set of values. | |
| ptrdiff_t | uppIndex |
| The number of intervals (a number of points - 1). | |
Protected Attributes inherited from MbFunction | |
| MbeFuncVersion | version |
| Version. | |
Additional Inherited Members | |
Protected Member Functions inherited from MbRefItem | |
| MbRefItem () | |
| Constructor without parameters. | |
Cubic Hermite function.
Cubic Hermite function.
| bool MbCubicFunction::Init | ( | bool | mono, |
| bool | cls, | ||
| const SArray< double > & | params, | ||
| const SArray< double > & | values, | ||
| const SArray< double > * | ders, | ||
| VERSION | vers = Math::DefaultMathVersion() |
||
| ) |
Function initialization.
Initialization of cubic spline based on a set of parameters.
| [in] | mono | - Is the set of values monotone. |
| [in] | cls | - Sign of closeness of a function (on both monotone and non-monotone data sets). |
| [in] | params | - Set of parameters (must be monotonically increasing). |
| [in] | values | - Set of values (should be monotonous for mono=true). |
| [in] | ders | - Set of derivatives at nodes (may be missing). |
|
overridevirtual |
Calculate value and derivatives of object for given parameter.
Values of point and derivatives are calculated on parameter area and on extended axis.
| [in] | t | - Parameter. |
| [in] | ext | - On parameters area (false), on extended axis (true). |
| [out] | val | - Value. |
| [out] | fir | - Derivative with respect to t. |
| [out] | sec | - Second derivative with respect to t, if not nullptr. |
| [out] | thr | - Third derivative with respect to t, if not nullptr. |
Reimplemented from MbFunction.