functionnumberOfRoots
Determine number of roots of polynomial
Information
Syntax
result = Polynomial.numberOfRoots(p);
Description
Calculate number of roots of a polynomial p.
Example
import Modelica_LinearSystems2.Math.Polynomial; x = Polynomial.x(); p1 = -6*x^2 + 4*x -3; Polynomial.numberOfRoots(p1); // = 2
See also
Inputs
| Type | Name | Default | Description |
|---|---|---|---|
| Polynomial | p | Polynomial |
Outputs
| Type | Name | Default | Description |
|---|---|---|---|
| Integer | result | Number of roots of p |