dgebd2.f.html
来自「famous linear algebra library (LAPACK) p」· HTML 代码 · 共 264 行 · 第 1/2 页
HTML
264 行
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>dgebd2.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="DGEBD2.1"></a><a href="dgebd2.f.html#DGEBD2.1">DGEBD2</a>( M, N, A, LDA, D, E, TAUQ, TAUP, WORK, INFO )
<span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> -- LAPACK 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> INTEGER INFO, LDA, M, N
<span class="comment">*</span><span class="comment"> ..
</span><span class="comment">*</span><span class="comment"> .. Array Arguments ..
</span> DOUBLE PRECISION A( LDA, * ), D( * ), E( * ), TAUP( * ),
$ TAUQ( * ), 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"> <a name="DGEBD2.18"></a><a href="dgebd2.f.html#DGEBD2.1">DGEBD2</a> reduces a real general m by n matrix A to upper or lower
</span><span class="comment">*</span><span class="comment"> bidiagonal form B by an orthogonal transformation: Q' * A * P = B.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> If m >= n, B is upper bidiagonal; if m < n, B is lower bidiagonal.
</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"> M (input) INTEGER
</span><span class="comment">*</span><span class="comment"> The number of rows in the matrix A. M >= 0.
</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 number of columns in the matrix A. N >= 0.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> A (input/output) DOUBLE PRECISION array, dimension (LDA,N)
</span><span class="comment">*</span><span class="comment"> On entry, the m by n general matrix to be reduced.
</span><span class="comment">*</span><span class="comment"> On exit,
</span><span class="comment">*</span><span class="comment"> if m >= n, the diagonal and the first superdiagonal are
</span><span class="comment">*</span><span class="comment"> overwritten with the upper bidiagonal matrix B; the
</span><span class="comment">*</span><span class="comment"> elements below the diagonal, with the array TAUQ, represent
</span><span class="comment">*</span><span class="comment"> the orthogonal matrix Q as a product of elementary
</span><span class="comment">*</span><span class="comment"> reflectors, and the elements above the first superdiagonal,
</span><span class="comment">*</span><span class="comment"> with the array TAUP, represent the orthogonal matrix P as
</span><span class="comment">*</span><span class="comment"> a product of elementary reflectors;
</span><span class="comment">*</span><span class="comment"> if m < n, the diagonal and the first subdiagonal are
</span><span class="comment">*</span><span class="comment"> overwritten with the lower bidiagonal matrix B; the
</span><span class="comment">*</span><span class="comment"> elements below the first subdiagonal, with the array TAUQ,
</span><span class="comment">*</span><span class="comment"> represent the orthogonal matrix Q as a product of
</span><span class="comment">*</span><span class="comment"> elementary reflectors, and the elements above the diagonal,
</span><span class="comment">*</span><span class="comment"> with the array TAUP, represent the orthogonal matrix P as
</span><span class="comment">*</span><span class="comment"> a product of elementary reflectors.
</span><span class="comment">*</span><span class="comment"> See Further Details.
</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 the array A. LDA >= max(1,M).
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> D (output) DOUBLE PRECISION array, dimension (min(M,N))
</span><span class="comment">*</span><span class="comment"> The diagonal elements of the bidiagonal matrix B:
</span><span class="comment">*</span><span class="comment"> D(i) = A(i,i).
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> E (output) DOUBLE PRECISION array, dimension (min(M,N)-1)
</span><span class="comment">*</span><span class="comment"> The off-diagonal elements of the bidiagonal matrix B:
</span><span class="comment">*</span><span class="comment"> if m >= n, E(i) = A(i,i+1) for i = 1,2,...,n-1;
</span><span class="comment">*</span><span class="comment"> if m < n, E(i) = A(i+1,i) for i = 1,2,...,m-1.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> TAUQ (output) DOUBLE PRECISION array dimension (min(M,N))
</span><span class="comment">*</span><span class="comment"> The scalar factors of the elementary reflectors which
</span><span class="comment">*</span><span class="comment"> represent the orthogonal matrix Q. See Further Details.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> TAUP (output) DOUBLE PRECISION array, dimension (min(M,N))
</span><span class="comment">*</span><span class="comment"> The scalar factors of the elementary reflectors which
</span><span class="comment">*</span><span class="comment"> represent the orthogonal matrix P. See Further Details.
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> WORK (workspace) DOUBLE PRECISION array, dimension (max(M,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">
</span><span class="comment">*</span><span class="comment"> Further Details
</span><span class="comment">*</span><span class="comment"> ===============
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> The matrices Q and P are represented as products of elementary
</span><span class="comment">*</span><span class="comment"> reflectors:
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> If m >= n,
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> Q = H(1) H(2) . . . H(n) and P = G(1) G(2) . . . G(n-1)
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> Each H(i) and G(i) has the form:
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> H(i) = I - tauq * v * v' and G(i) = I - taup * u * u'
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> where tauq and taup are real scalars, and v and u are real vectors;
</span><span class="comment">*</span><span class="comment"> v(1:i-1) = 0, v(i) = 1, and v(i+1:m) is stored on exit in A(i+1:m,i);
</span><span class="comment">*</span><span class="comment"> u(1:i) = 0, u(i+1) = 1, and u(i+2:n) is stored on exit in A(i,i+2:n);
</span><span class="comment">*</span><span class="comment"> tauq is stored in TAUQ(i) and taup in TAUP(i).
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> If m < n,
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> Q = H(1) H(2) . . . H(m-1) and P = G(1) G(2) . . . G(m)
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> Each H(i) and G(i) has the form:
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> H(i) = I - tauq * v * v' and G(i) = I - taup * u * u'
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> where tauq and taup are real scalars, and v and u are real vectors;
</span><span class="comment">*</span><span class="comment"> v(1:i) = 0, v(i+1) = 1, and v(i+2:m) is stored on exit in A(i+2:m,i);
</span><span class="comment">*</span><span class="comment"> u(1:i-1) = 0, u(i) = 1, and u(i+1:n) is stored on exit in A(i,i+1:n);
</span><span class="comment">*</span><span class="comment"> tauq is stored in TAUQ(i) and taup in TAUP(i).
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> The contents of A on exit are illustrated by the following examples:
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> m = 6 and n = 5 (m > n): m = 5 and n = 6 (m < n):
</span><span class="comment">*</span><span class="comment">
</span><span class="comment">*</span><span class="comment"> ( d e u1 u1 u1 ) ( d u1 u1 u1 u1 u1 )
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?