CPQR79(3)

SYNOPSIS
SUBROUTINE CPQR79 (NDEG, COEFF, ROOT, IERR, WORK)

NAME
cpqr79 - Find the zeros of a polynomial with complex coefficients.

LIBRARY
SLATEC

CATEGORY
F1A1B

TYPE
COMPLEX (RPQR79-S, CPQR79-C)

KEYWORDS
COMPLEX POLYNOMIAL, POLYNOMIAL ROOTS, POLYNOMIAL ZEROS

AUTHOR
Vandevender, W. H., (SNLA)

DESCRIPTION
Abstract This routine computes all zeros of a polynomial of degree NDEG with complex coefficients by computing the eigenvalues of the companion matrix. Description of Parameters The user must dimension all arrays appearing in the call list COEFF(NDEG+1), ROOT(NDEG), WORK(2*NDEG*(NDEG+1)) --Input-- NDEG degree of polynomial COEFF COMPLEX coefficients in descending order. i.e., P(Z)= COEFF(1)*(Z**NDEG) + COEFF(NDEG)*Z + COEFF(NDEG+1) WORK REAL work array of dimension at least 2*NDEG*(NDEG+1) --Output-- ROOT COMPLEX vector of roots IERR Output Error Code - Normal Code 0 means the roots were computed. - Abnormal Codes 1 more than 30 QR iterations on some eigenvalue of the companion matrix 2 COEFF(1)=0.0 3 NDEG is invalid (less than or equal to 0)

REFERENCES
(NONE)

ROUTINES CALLED
COMQR, XERMSG

REVISION HISTORY (YYMMDD)
791201 DATE WRITTEN
890531 Changed all specific intrinsics to generic. (WRB)
890531 REVISION DATE from Version 3.2
891214 Prologue converted to Version 4.0 format. (BAB)
900315 CALLs to XERROR changed to CALLs to XERMSG. (THJ)
900326 Removed duplicate information from DESCRIPTION section. (WRB)
911010 Code reworked and simplified. (RWC and WRB)