# naginterfaces.library.zeros.quartic_​complex¶

naginterfaces.library.zeros.quartic_complex(e, a, b, c, d)[source]

quartic_complex determines the roots of a quartic equation with complex coefficients.

For full information please refer to the NAG Library document for c02an

https://www.nag.com/numeric/nl/nagdoc_27.3/flhtml/c02/c02anf.html

Parameters
ecomplex

, the coefficient of .

acomplex

, the coefficient of .

bcomplex

, the coefficient of .

ccomplex

, the coefficient of .

dcomplex

, the constant coefficient.

Returns
zerocomplex, ndarray, shape

contains the th root.

errestfloat, ndarray, shape

contains an approximate error estimate for the th root.

Raises
NagValueError
(errno )

On entry, .

Constraint:

(errno )

The companion matrix cannot be formed without overflow.

(errno )

Failure to converge in lapackeig.zhseqr.

Notes

No equivalent traditional C interface for this routine exists in the NAG Library.

quartic_complex attempts to find the roots of the quartic equation

where , , , and are complex coefficients with . The roots are located by finding the eigenvalues of the associated (upper Hessenberg) companion matrix given by

The eigenvalues are obtained by a call to lapackeig.zhseqr. Further details can be found in Further Comments.

To obtain the roots of a cubic equation, cubic_complex() can be used.

References

Golub, G H and Van Loan, C F, 1996, Matrix Computations, (3rd Edition), Johns Hopkins University Press, Baltimore