zgegs.f.html
来自「famous linear algebra library (LAPACK) p」· HTML 代码 · 共 453 行 · 第 1/3 页
HTML
453 行
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>zgegs.f</title>
<meta name="generator" content="emacs 21.3.1; htmlfontify 0.20">
<style type="text/css"><!--
body { background: rgb(255, 255, 255); color: rgb(0, 0, 0); font-style: normal; font-weight: 500; font-stretch: normal; font-family: adobe-courier; font-size: 11pt; text-decoration: none; }
span.default { background: rgb(255, 255, 255); color: rgb(0, 0, 0); font-style: normal; font-weight: 500; font-stretch: normal; font-family: adobe-courier; font-size: 11pt; text-decoration: none; }
span.default a { background: rgb(255, 255, 255); color: rgb(0, 0, 0); font-style: normal; font-weight: 500; font-stretch: normal; font-family: adobe-courier; font-size: 11pt; text-decoration: underline; }
span.string { color: rgb(188, 143, 143); background: rgb(255, 255, 255); font-style: normal; font-weight: 500; font-stretch: normal; font-family: adobe-courier; font-size: 11pt; text-decoration: none; }
span.string a { color: rgb(188, 143, 143); background: rgb(255, 255, 255); font-style: normal; font-weight: 500; font-stretch: normal; font-family: adobe-courier; font-size: 11pt; text-decoration: underline; }
span.comment { color: rgb(178, 34, 34); background: rgb(255, 255, 255); font-style: normal; font-weight: 500; font-stretch: normal; font-family: adobe-courier; font-size: 11pt; text-decoration: none; }
span.comment a { color: rgb(178, 34, 34); background: rgb(255, 255, 255); font-style: normal; font-weight: 500; font-stretch: normal; font-family: adobe-courier; font-size: 11pt; text-decoration: underline; }
--></style>
</head>
<body>
<pre>
SUBROUTINE <a name="ZGEGS.1"></a><a href="zgegs.f.html#ZGEGS.1">ZGEGS</a>( JOBVSL, JOBVSR, N, A, LDA, B, LDB, ALPHA, BETA,
$ VSL, LDVSL, VSR, LDVSR, WORK, LWORK, RWORK,
$ INFO )
<span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> -- LAPACK driver routine (version 3.1) --
</span><span class="comment">*</span><span class="comment"> Univ. of Tennessee, Univ. of California Berkeley and NAG Ltd..
</span><span class="comment">*</span><span class="comment"> November 2006
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> .. Scalar Arguments ..
</span> CHARACTER JOBVSL, JOBVSR
INTEGER INFO, LDA, LDB, LDVSL, LDVSR, LWORK, N
<span class="comment">*</span><span class="comment"> ..
</span><span class="comment">*</span><span class="comment"> .. Array Arguments ..
</span> DOUBLE PRECISION RWORK( * )
COMPLEX*16 A( LDA, * ), ALPHA( * ), B( LDB, * ),
$ BETA( * ), VSL( LDVSL, * ), VSR( LDVSR, * ),
$ WORK( * )
<span class="comment">*</span><span class="comment"> ..
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> Purpose
</span><span class="comment">*</span><span class="comment"> =======
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> This routine is deprecated and has been replaced by routine <a name="ZGGES.23"></a><a href="zgges.f.html#ZGGES.1">ZGGES</a>.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> <a name="ZGEGS.25"></a><a href="zgegs.f.html#ZGEGS.1">ZGEGS</a> computes the eigenvalues, Schur form, and, optionally, the
</span><span class="comment">*</span><span class="comment"> left and or/right Schur vectors of a complex matrix pair (A,B).
</span><span class="comment">*</span><span class="comment"> Given two square matrices A and B, the generalized Schur
</span><span class="comment">*</span><span class="comment"> factorization has the form
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> A = Q*S*Z**H, B = Q*T*Z**H
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> where Q and Z are unitary matrices and S and T are upper triangular.
</span><span class="comment">*</span><span class="comment"> The columns of Q are the left Schur vectors
</span><span class="comment">*</span><span class="comment"> and the columns of Z are the right Schur vectors.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> If only the eigenvalues of (A,B) are needed, the driver routine
</span><span class="comment">*</span><span class="comment"> <a name="ZGEGV.37"></a><a href="zgegv.f.html#ZGEGV.1">ZGEGV</a> should be used instead. See <a name="ZGEGV.37"></a><a href="zgegv.f.html#ZGEGV.1">ZGEGV</a> for a description of the
</span><span class="comment">*</span><span class="comment"> eigenvalues of the generalized nonsymmetric eigenvalue problem
</span><span class="comment">*</span><span class="comment"> (GNEP).
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> Arguments
</span><span class="comment">*</span><span class="comment"> =========
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> JOBVSL (input) CHARACTER*1
</span><span class="comment">*</span><span class="comment"> = 'N': do not compute the left Schur vectors;
</span><span class="comment">*</span><span class="comment"> = 'V': compute the left Schur vectors (returned in VSL).
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> JOBVSR (input) CHARACTER*1
</span><span class="comment">*</span><span class="comment"> = 'N': do not compute the right Schur vectors;
</span><span class="comment">*</span><span class="comment"> = 'V': compute the right Schur vectors (returned in VSR).
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> N (input) INTEGER
</span><span class="comment">*</span><span class="comment"> The order of the matrices A, B, VSL, and VSR. N >= 0.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> A (input/output) COMPLEX*16 array, dimension (LDA, N)
</span><span class="comment">*</span><span class="comment"> On entry, the matrix A.
</span><span class="comment">*</span><span class="comment"> On exit, the upper triangular matrix S from the generalized
</span><span class="comment">*</span><span class="comment"> Schur factorization.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> LDA (input) INTEGER
</span><span class="comment">*</span><span class="comment"> The leading dimension of A. LDA >= max(1,N).
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> B (input/output) COMPLEX*16 array, dimension (LDB, N)
</span><span class="comment">*</span><span class="comment"> On entry, the matrix B.
</span><span class="comment">*</span><span class="comment"> On exit, the upper triangular matrix T from the generalized
</span><span class="comment">*</span><span class="comment"> Schur factorization.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> LDB (input) INTEGER
</span><span class="comment">*</span><span class="comment"> The leading dimension of B. LDB >= max(1,N).
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> ALPHA (output) COMPLEX*16 array, dimension (N)
</span><span class="comment">*</span><span class="comment"> The complex scalars alpha that define the eigenvalues of
</span><span class="comment">*</span><span class="comment"> GNEP. ALPHA(j) = S(j,j), the diagonal element of the Schur
</span><span class="comment">*</span><span class="comment"> form of A.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> BETA (output) COMPLEX*16 array, dimension (N)
</span><span class="comment">*</span><span class="comment"> The non-negative real scalars beta that define the
</span><span class="comment">*</span><span class="comment"> eigenvalues of GNEP. BETA(j) = T(j,j), the diagonal element
</span><span class="comment">*</span><span class="comment"> of the triangular factor T.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> Together, the quantities alpha = ALPHA(j) and beta = BETA(j)
</span><span class="comment">*</span><span class="comment"> represent the j-th eigenvalue of the matrix pair (A,B), in
</span><span class="comment">*</span><span class="comment"> one of the forms lambda = alpha/beta or mu = beta/alpha.
</span><span class="comment">*</span><span class="comment"> Since either lambda or mu may overflow, they should not,
</span><span class="comment">*</span><span class="comment"> in general, be computed.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> VSL (output) COMPLEX*16 array, dimension (LDVSL,N)
</span><span class="comment">*</span><span class="comment"> If JOBVSL = 'V', the matrix of left Schur vectors Q.
</span><span class="comment">*</span><span class="comment"> Not referenced if JOBVSL = 'N'.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> LDVSL (input) INTEGER
</span><span class="comment">*</span><span class="comment"> The leading dimension of the matrix VSL. LDVSL >= 1, and
</span><span class="comment">*</span><span class="comment"> if JOBVSL = 'V', LDVSL >= N.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> VSR (output) COMPLEX*16 array, dimension (LDVSR,N)
</span><span class="comment">*</span><span class="comment"> If JOBVSR = 'V', the matrix of right Schur vectors Z.
</span><span class="comment">*</span><span class="comment"> Not referenced if JOBVSR = 'N'.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> LDVSR (input) INTEGER
</span><span class="comment">*</span><span class="comment"> The leading dimension of the matrix VSR. LDVSR >= 1, and
</span><span class="comment">*</span><span class="comment"> if JOBVSR = 'V', LDVSR >= N.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> WORK (workspace/output) COMPLEX*16 array, dimension (MAX(1,LWORK))
</span><span class="comment">*</span><span class="comment"> On exit, if INFO = 0, WORK(1) returns the optimal LWORK.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> LWORK (input) INTEGER
</span><span class="comment">*</span><span class="comment"> The dimension of the array WORK. LWORK >= max(1,2*N).
</span><span class="comment">*</span><span class="comment"> For good performance, LWORK must generally be larger.
</span><span class="comment">*</span><span class="comment"> To compute the optimal value of LWORK, call <a name="ILAENV.110"></a><a href="hfy-index.html#ILAENV">ILAENV</a> to get
</span><span class="comment">*</span><span class="comment"> blocksizes (for <a name="ZGEQRF.111"></a><a href="zgeqrf.f.html#ZGEQRF.1">ZGEQRF</a>, <a name="ZUNMQR.111"></a><a href="zunmqr.f.html#ZUNMQR.1">ZUNMQR</a>, and <a name="CUNGQR.111"></a><a href="cungqr.f.html#CUNGQR.1">CUNGQR</a>.) Then compute:
</span><span class="comment">*</span><span class="comment"> NB -- MAX of the blocksizes for <a name="ZGEQRF.112"></a><a href="zgeqrf.f.html#ZGEQRF.1">ZGEQRF</a>, <a name="ZUNMQR.112"></a><a href="zunmqr.f.html#ZUNMQR.1">ZUNMQR</a>, and <a name="CUNGQR.112"></a><a href="cungqr.f.html#CUNGQR.1">CUNGQR</a>;
</span><span class="comment">*</span><span class="comment"> the optimal LWORK is N*(NB+1).
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> If LWORK = -1, then a workspace query is assumed; the routine
</span><span class="comment">*</span><span class="comment"> only calculates the optimal size of the WORK array, returns
</span><span class="comment">*</span><span class="comment"> this value as the first entry of the WORK array, and no error
</span><span class="comment">*</span><span class="comment"> message related to LWORK is issued by <a name="XERBLA.118"></a><a href="xerbla.f.html#XERBLA.1">XERBLA</a>.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> RWORK (workspace) DOUBLE PRECISION array, dimension (3*N)
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> INFO (output) INTEGER
</span><span class="comment">*</span><span class="comment"> = 0: successful exit
</span><span class="comment">*</span><span class="comment"> < 0: if INFO = -i, the i-th argument had an illegal value.
</span><span class="comment">*</span><span class="comment"> =1,...,N:
</span><span class="comment">*</span><span class="comment"> The QZ iteration failed. (A,B) are not in Schur
</span><span class="comment">*</span><span class="comment"> form, but ALPHA(j) and BETA(j) should be correct for
</span><span class="comment">*</span><span class="comment"> j=INFO+1,...,N.
</span><span class="comment">*</span><span class="comment"> > N: errors that usually indicate LAPACK problems:
</span><span class="comment">*</span><span class="comment"> =N+1: error return from <a name="ZGGBAL.130"></a><a href="zggbal.f.html#ZGGBAL.1">ZGGBAL</a>
</span><span class="comment">*</span><span class="comment"> =N+2: error return from <a name="ZGEQRF.131"></a><a href="zgeqrf.f.html#ZGEQRF.1">ZGEQRF</a>
</span><span class="comment">*</span><span class="comment"> =N+3: error return from <a name="ZUNMQR.132"></a><a href="zunmqr.f.html#ZUNMQR.1">ZUNMQR</a>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?