![]() |
Open CASCADE Technology Reference Manual 8.0.0
|
Polynomial root finding algorithms. More...
Namespaces | |
| namespace | detail |
Data Structures | |
| struct | GeneralPolyResult |
| Result for general polynomial solver. More... | |
Functions | |
| MathUtils::PolyResult | Linear (double theA, double theB) |
| Solve linear equation: a*x + b = 0 Handles degenerate cases (a = 0). | |
| MathUtils::PolyResult | Quadratic (double theA, double theB, double theC) |
| Solve quadratic equation: a*x^2 + b*x + c = 0 Uses numerically stable formulas to avoid catastrophic cancellation. | |
| MathUtils::PolyResult | Cubic (double theA, double theB, double theC, double theD) |
| Solve cubic equation: a*x^3 + b*x^2 + c*x + d = 0 Uses Cardano's method with Vieta substitution and trigonometric solution. | |
| MathUtils::PolyResult | Quartic (double theA, double theB, double theC, double theD, double theE) |
| Solve quartic equation: a*x^4 + b*x^3 + c*x^2 + d*x + e = 0 Uses Ferrari's method with modern numerical enhancements. | |
| GeneralPolyResult | Laguerre (const double *theCoeffs, int theDegree, double theTol=1.0e-12) |
| Solve polynomial equation using Laguerre's method with deflation. Works for any degree up to THE_MAX_POLY_DEGREE. | |
| GeneralPolyResult | LaguerreN (const double *theCoeffs, size_t theSize, double theTol=1.0e-12) |
| Convenience function: solve polynomial given as array with specified size. | |
| MathUtils::PolyResult | Sextic (double theA, double theB, double theC, double theD, double theE, double theF, double theG) |
| Solve sextic (degree 6) polynomial: a*x^6 + b*x^5 + c*x^4 + d*x^3 + e*x^2 + f*x + g = 0. | |
| MathUtils::PolyResult | Quintic (double theA, double theB, double theC, double theD, double theE, double theF) |
| Solve quintic (degree 5) polynomial: a*x^5 + b*x^4 + c*x^3 + d*x^2 + e*x + f = 0. | |
| GeneralPolyResult | Octic (const double theCoeffs[9]) |
| Solve octic (degree 8) polynomial using Laguerre's method. Useful for Circle-Ellipse extrema after Weierstrass substitution. | |
Variables | |
| constexpr int | THE_MAX_POLY_DEGREE = 20 |
| Maximum polynomial degree supported by Laguerre solver. | |
Polynomial root finding algorithms.
Polynomial root finding algorithms using Laguerre's method.
|
inline |
Solve cubic equation: a*x^3 + b*x^2 + c*x + d = 0 Uses Cardano's method with Vieta substitution and trigonometric solution.
Algorithm:
| theA | coefficient of x^3 |
| theB | coefficient of x^2 |
| theC | coefficient of x |
| theD | constant term |
|
inline |
Solve polynomial equation using Laguerre's method with deflation. Works for any degree up to THE_MAX_POLY_DEGREE.
Algorithm:
| theCoeffs | coefficients array [a0, a1, a2, ..., an] for a0 + a1*x + ... + an*x^n |
| theDegree | polynomial degree |
| theTol | tolerance for convergence and real/complex discrimination |
|
inline |
Convenience function: solve polynomial given as array with specified size.
| theCoeffs | coefficients [a0, a1, ..., an] |
| theSize | size of coefficient array (degree + 1) |
| theTol | tolerance |
|
inline |
Solve linear equation: a*x + b = 0 Handles degenerate cases (a = 0).
| theA | coefficient of x |
| theB | constant term |
|
inline |
Solve octic (degree 8) polynomial using Laguerre's method. Useful for Circle-Ellipse extrema after Weierstrass substitution.
| theCoeffs | coefficients [a0, a1, ..., a8] where polynomial is a0 + a1*x + ... + a8*x^8 |
|
inline |
Solve quadratic equation: a*x^2 + b*x + c = 0 Uses numerically stable formulas to avoid catastrophic cancellation.
Algorithm:
| theA | coefficient of x^2 |
| theB | coefficient of x |
| theC | constant term |
|
inline |
Solve quartic equation: a*x^4 + b*x^3 + c*x^2 + d*x + e = 0 Uses Ferrari's method with modern numerical enhancements.
Algorithm:
| theA | coefficient of x^4 |
| theB | coefficient of x^3 |
| theC | coefficient of x^2 |
| theD | coefficient of x |
| theE | constant term |
|
inline |
Solve quintic (degree 5) polynomial: a*x^5 + b*x^4 + c*x^3 + d*x^2 + e*x + f = 0.
| theA | coefficient of x^5 |
| theB | coefficient of x^4 |
| theC | coefficient of x^3 |
| theD | coefficient of x^2 |
| theE | coefficient of x |
| theF | constant term |
|
inline |
Solve sextic (degree 6) polynomial: a*x^6 + b*x^5 + c*x^4 + d*x^3 + e*x^2 + f*x + g = 0.
| theA | coefficient of x^6 |
| theB | coefficient of x^5 |
| theC | coefficient of x^4 |
| theD | coefficient of x^3 |
| theE | coefficient of x^2 |
| theF | coefficient of x |
| theG | constant term |