public class CubicRoot extends Object implements PolyRootSolver
Constructor and Description |
---|
CubicRoot() |
Modifier and Type | Method and Description |
---|---|
List<Number> |
solve(Polynomial polynomial)
Solve \(ax^3 + bx^2 + cx + d = 0\).
|
public List<Number> solve(Polynomial polynomial)
solve
in interface PolyRootSolver
polynomial
- a cubic equation to be solvedIllegalArgumentException
- if the polynomial degree is not 3Copyright © 2010-2020 NM FinTech Ltd.. All Rights Reserved.