|
| | CubicT ()=default |
| | CubicT (T_real const &a, T_real const &b, T_real const &c, T_real const &d) |
| void | setup (T_real const &a, T_real const &b, T_real const &c, T_real const &d) |
| integer | num_roots () const |
| integer | numRoots () const |
| | Alias of num_roots().
|
| bool | complex_root () const |
| bool | complexRoot () const |
| | Alias of complex_root().
|
| bool | double_root () const |
| bool | doubleRoot () const |
| | Alias of double_root().
|
| bool | triple_root () const |
| bool | tripleRoot () const |
| | Alias of triple_root().
|
| integer | get_real_roots (T_real r[]) const |
| integer | getRealRoots (T_real r[]) const |
| | Alias of get_real_roots().
|
| integer | get_positive_roots (T_real r[]) const |
| integer | getPositiveRoots (T_real r[]) const |
| | Alias of get_positive_roots().
|
| integer | get_negative_roots (T_real r[]) const |
| integer | getNegativeRoots (T_real r[]) const |
| | Alias of get_negative_roots().
|
| integer | get_roots_in_range (T_real const &a, T_real const &b, T_real r[]) const |
| integer | getRootsInRange (T_real const &a, T_real const &b, T_real r[]) const |
| | Alias of get_roots_in_range().
|
| integer | get_roots_in_open_range (T_real const &a, T_real const &b, T_real r[]) const |
| integer | getRootsInOpenRange (T_real const &a, T_real const &b, T_real r[]) const |
| | Alias of get_roots_in_open_range().
|
| T_real | real_root0 () const |
| T_real | real_root1 () const |
| T_real | real_root2 () const |
| | Return the third stored real root.
|
| T_complex | root0 () const |
| T_complex | root1 () const |
| T_complex | root2 () const |
| void | get_root0 (T_real &re, T_real &im) const |
| void | getRoot0 (T_real &re, T_real &im) const |
| | Alias of get_root0().
|
| void | get_root0 (T_complex &r) const |
| void | getRoot0 (T_complex &r) const |
| | Alias of get_root0().
|
| void | get_root1 (T_real &re, T_real &im) const |
| void | getRoot1 (T_real &re, T_real &im) const |
| | Alias of get_root1().
|
| void | get_root1 (T_complex &r) const |
| void | getRoot1 (T_complex &r) const |
| | Alias of get_root1().
|
| void | get_root2 (T_real &re, T_real &im) const |
| void | getRoot2 (T_real &re, T_real &im) const |
| | Alias of get_root2().
|
| void | get_root2 (T_complex &r) const |
| void | getRoot2 (T_complex &r) const |
| | Alias of get_root2().
|
| T_complex | root (integer const i) const |
| void | get_root (integer const i, T_real &re, T_real &im) const |
| T_real | eval (T_real const &x) const |
| T_complex | eval (T_complex const &x) const |
| void | eval (T_real const &x, T_real &p, T_real &dp) const |
| void | info (ostream_type &s) const |
| bool | check (ostream_type &s) const |
template<typename T_real, typename T_complex>
class PolynomialRoots::CubicT< T_real, T_complex >
Cubic polynomial class
Constructor
double a = 1;
double b = 2;
double c = 3;
double d = 3;
void setup(T_real const &a, T_real const &b, T_real const &c, T_real const &d)
Definition PolynomialRoots.hh:698
CubicT< real_type, real_complex > Cubic
Definition PolynomialRoots.hh:980
Get kind of solution
bool triple_root() const
Definition PolynomialRoots.hh:744
bool complex_root() const
Definition PolynomialRoots.hh:728
integer num_roots() const
Definition PolynomialRoots.hh:720
bool double_root() const
Definition PolynomialRoots.hh:736
Get real roots
double r_min = 0;
double r_max = 2;
double r[3];
int nroots;
integer getNegativeRoots(T_real r[]) const
Alias of get_negative_roots().
Definition PolynomialRoots.hh:780
integer getRootsInOpenRange(T_real const &a, T_real const &b, T_real r[]) const
Alias of get_roots_in_open_range().
Definition PolynomialRoots.hh:807
integer getRealRoots(T_real r[]) const
Alias of get_real_roots().
Definition PolynomialRoots.hh:758
integer getPositiveRoots(T_real r[]) const
Alias of get_positive_roots().
Definition PolynomialRoots.hh:769
integer getRootsInRange(T_real const &a, T_real const &b, T_real r[]) const
Alias of get_roots_in_range().
Definition PolynomialRoots.hh:793
Get roots
void getRoot2(T_real &re, T_real &im) const
Alias of get_root2().
Definition PolynomialRoots.hh:908
T_complex root0() const
Definition PolynomialRoots.hh:830
void getRoot0(T_real &re, T_real &im) const
Alias of get_root0().
Definition PolynomialRoots.hh:860
T_real real_root2() const
Return the third stored real root.
Definition PolynomialRoots.hh:825
void getRoot1(T_real &re, T_real &im) const
Alias of get_root1().
Definition PolynomialRoots.hh:888
T_complex root2() const
Definition PolynomialRoots.hh:840
T_real real_root1() const
Definition PolynomialRoots.hh:822
T_real real_root0() const
Definition PolynomialRoots.hh:816
T_complex root1() const
Definition PolynomialRoots.hh:835
Lightweight complex number type used by the standard-precision solvers.
Definition PolynomialRoots-complex.hxx:30
double real_type
Scalar type used by the standard-precision API.
Definition PolynomialRoots.hh:66
Evaluate polynomial
{double or complex} v, x;
T_real eval(T_real const &x) const
Definition PolynomialRoots.hh:954
Information
bool ok = p.
check( cout );
void info(ostream_type &s) const
Definition PolynomialRoots-2-Cubic.cc:538
bool check(ostream_type &s) const
Definition PolynomialRoots-2-Cubic.cc:578