Class LaguerreSolver.ComplexSolver
java.lang.Object
org.apache.commons.math3.analysis.solvers.LaguerreSolver.ComplexSolver
- Enclosing class:
LaguerreSolver
Class for searching all (complex) roots.
- Since:
- 1.2
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanCheck whether the given complex root is actually a real zero in the given interval, within the solver tolerance level.Find a complex root for the polynomial with the given coefficients, starting from the given initial value.Complex[]Find all complex roots for the polynomial with the given coefficients, starting from the given initial value.
-
Constructor Details
-
ComplexSolver
private ComplexSolver()
-
-
Method Details
-
isRoot
Check whether the given complex root is actually a real zero in the given interval, within the solver tolerance level.- Parameters:
min- Lower bound for the interval.max- Upper bound for the interval.z- Complex root.- Returns:
trueif z is a real zero.
-
solveAll
public Complex[] solveAll(Complex[] coefficients, Complex initial) throws NullArgumentException, NoDataException, TooManyEvaluationsException Find all complex roots for the polynomial with the given coefficients, starting from the given initial value.- Parameters:
coefficients- Polynomial coefficients.initial- Start value.- Returns:
- the point at which the function value is zero.
- Throws:
TooManyEvaluationsException- if the maximum number of evaluations is exceeded.NullArgumentException- if thecoefficientsisnull.NoDataException- if thecoefficientsarray is empty.
-
solve
public Complex solve(Complex[] coefficients, Complex initial) throws NullArgumentException, NoDataException, TooManyEvaluationsException Find a complex root for the polynomial with the given coefficients, starting from the given initial value.- Parameters:
coefficients- Polynomial coefficients.initial- Start value.- Returns:
- the point at which the function value is zero.
- Throws:
TooManyEvaluationsException- if the maximum number of evaluations is exceeded.NullArgumentException- if thecoefficientsisnull.NoDataException- if thecoefficientsarray is empty.
-