Mercurial > octave-nkf
annotate libcruft/arpack/src/dseupd.f @ 12274:9f5d2ef078e8 release-3-4-x
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Fri, 28 Jan 2011 14:04:33 -0500 |
parents | |
children | 126d8fe48a12 |
rev | line source |
---|---|
12274
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
1 c\BeginDoc |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
2 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
3 c\Name: dseupd |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
4 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
5 c\Description: |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
6 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
7 c This subroutine returns the converged approximations to eigenvalues |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
8 c of A*z = lambda*B*z and (optionally): |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
9 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
10 c (1) the corresponding approximate eigenvectors, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
11 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
12 c (2) an orthonormal (Lanczos) basis for the associated approximate |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
13 c invariant subspace, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
14 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
15 c (3) Both. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
16 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
17 c There is negligible additional cost to obtain eigenvectors. An orthonormal |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
18 c (Lanczos) basis is always computed. There is an additional storage cost |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
19 c of n*nev if both are requested (in this case a separate array Z must be |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
20 c supplied). |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
21 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
22 c These quantities are obtained from the Lanczos factorization computed |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
23 c by DSAUPD for the linear operator OP prescribed by the MODE selection |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
24 c (see IPARAM(7) in DSAUPD documentation.) DSAUPD must be called before |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
25 c this routine is called. These approximate eigenvalues and vectors are |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
26 c commonly called Ritz values and Ritz vectors respectively. They are |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
27 c referred to as such in the comments that follow. The computed orthonormal |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
28 c basis for the invariant subspace corresponding to these Ritz values is |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
29 c referred to as a Lanczos basis. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
30 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
31 c See documentation in the header of the subroutine DSAUPD for a definition |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
32 c of OP as well as other terms and the relation of computed Ritz values |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
33 c and vectors of OP with respect to the given problem A*z = lambda*B*z. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
34 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
35 c The approximate eigenvalues of the original problem are returned in |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
36 c ascending algebraic order. The user may elect to call this routine |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
37 c once for each desired Ritz vector and store it peripherally if desired. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
38 c There is also the option of computing a selected set of these vectors |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
39 c with a single call. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
40 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
41 c\Usage: |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
42 c call dseupd |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
43 c ( RVEC, HOWMNY, SELECT, D, Z, LDZ, SIGMA, BMAT, N, WHICH, NEV, TOL, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
44 c RESID, NCV, V, LDV, IPARAM, IPNTR, WORKD, WORKL, LWORKL, INFO ) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
45 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
46 c RVEC LOGICAL (INPUT) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
47 c Specifies whether Ritz vectors corresponding to the Ritz value |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
48 c approximations to the eigenproblem A*z = lambda*B*z are computed. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
49 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
50 c RVEC = .FALSE. Compute Ritz values only. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
51 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
52 c RVEC = .TRUE. Compute Ritz vectors. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
53 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
54 c HOWMNY Character*1 (INPUT) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
55 c Specifies how many Ritz vectors are wanted and the form of Z |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
56 c the matrix of Ritz vectors. See remark 1 below. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
57 c = 'A': compute NEV Ritz vectors; |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
58 c = 'S': compute some of the Ritz vectors, specified |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
59 c by the logical array SELECT. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
60 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
61 c SELECT Logical array of dimension NCV. (INPUT/WORKSPACE) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
62 c If HOWMNY = 'S', SELECT specifies the Ritz vectors to be |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
63 c computed. To select the Ritz vector corresponding to a |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
64 c Ritz value D(j), SELECT(j) must be set to .TRUE.. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
65 c If HOWMNY = 'A' , SELECT is used as a workspace for |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
66 c reordering the Ritz values. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
67 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
68 c D Double precision array of dimension NEV. (OUTPUT) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
69 c On exit, D contains the Ritz value approximations to the |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
70 c eigenvalues of A*z = lambda*B*z. The values are returned |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
71 c in ascending order. If IPARAM(7) = 3,4,5 then D represents |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
72 c the Ritz values of OP computed by dsaupd transformed to |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
73 c those of the original eigensystem A*z = lambda*B*z. If |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
74 c IPARAM(7) = 1,2 then the Ritz values of OP are the same |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
75 c as the those of A*z = lambda*B*z. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
76 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
77 c Z Double precision N by NEV array if HOWMNY = 'A'. (OUTPUT) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
78 c On exit, Z contains the B-orthonormal Ritz vectors of the |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
79 c eigensystem A*z = lambda*B*z corresponding to the Ritz |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
80 c value approximations. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
81 c If RVEC = .FALSE. then Z is not referenced. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
82 c NOTE: The array Z may be set equal to first NEV columns of the |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
83 c Arnoldi/Lanczos basis array V computed by DSAUPD . |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
84 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
85 c LDZ Integer. (INPUT) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
86 c The leading dimension of the array Z. If Ritz vectors are |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
87 c desired, then LDZ .ge. max( 1, N ). In any case, LDZ .ge. 1. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
88 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
89 c SIGMA Double precision (INPUT) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
90 c If IPARAM(7) = 3,4,5 represents the shift. Not referenced if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
91 c IPARAM(7) = 1 or 2. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
92 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
93 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
94 c **** The remaining arguments MUST be the same as for the **** |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
95 c **** call to DSAUPD that was just completed. **** |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
96 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
97 c NOTE: The remaining arguments |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
98 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
99 c BMAT, N, WHICH, NEV, TOL, RESID, NCV, V, LDV, IPARAM, IPNTR, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
100 c WORKD, WORKL, LWORKL, INFO |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
101 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
102 c must be passed directly to DSEUPD following the last call |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
103 c to DSAUPD . These arguments MUST NOT BE MODIFIED between |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
104 c the the last call to DSAUPD and the call to DSEUPD . |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
105 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
106 c Two of these parameters (WORKL, INFO) are also output parameters: |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
107 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
108 c WORKL Double precision work array of length LWORKL. (OUTPUT/WORKSPACE) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
109 c WORKL(1:4*ncv) contains information obtained in |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
110 c dsaupd . They are not changed by dseupd . |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
111 c WORKL(4*ncv+1:ncv*ncv+8*ncv) holds the |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
112 c untransformed Ritz values, the computed error estimates, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
113 c and the associated eigenvector matrix of H. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
114 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
115 c Note: IPNTR(8:10) contains the pointer into WORKL for addresses |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
116 c of the above information computed by dseupd . |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
117 c ------------------------------------------------------------- |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
118 c IPNTR(8): pointer to the NCV RITZ values of the original system. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
119 c IPNTR(9): pointer to the NCV corresponding error bounds. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
120 c IPNTR(10): pointer to the NCV by NCV matrix of eigenvectors |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
121 c of the tridiagonal matrix T. Only referenced by |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
122 c dseupd if RVEC = .TRUE. See Remarks. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
123 c ------------------------------------------------------------- |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
124 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
125 c INFO Integer. (OUTPUT) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
126 c Error flag on output. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
127 c = 0: Normal exit. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
128 c = -1: N must be positive. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
129 c = -2: NEV must be positive. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
130 c = -3: NCV must be greater than NEV and less than or equal to N. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
131 c = -5: WHICH must be one of 'LM', 'SM', 'LA', 'SA' or 'BE'. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
132 c = -6: BMAT must be one of 'I' or 'G'. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
133 c = -7: Length of private work WORKL array is not sufficient. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
134 c = -8: Error return from trid. eigenvalue calculation; |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
135 c Information error from LAPACK routine dsteqr . |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
136 c = -9: Starting vector is zero. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
137 c = -10: IPARAM(7) must be 1,2,3,4,5. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
138 c = -11: IPARAM(7) = 1 and BMAT = 'G' are incompatible. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
139 c = -12: NEV and WHICH = 'BE' are incompatible. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
140 c = -14: DSAUPD did not find any eigenvalues to sufficient |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
141 c accuracy. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
142 c = -15: HOWMNY must be one of 'A' or 'S' if RVEC = .true. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
143 c = -16: HOWMNY = 'S' not yet implemented |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
144 c = -17: DSEUPD got a different count of the number of converged |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
145 c Ritz values than DSAUPD got. This indicates the user |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
146 c probably made an error in passing data from DSAUPD to |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
147 c DSEUPD or that the data was modified before entering |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
148 c DSEUPD . |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
149 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
150 c\BeginLib |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
151 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
152 c\References: |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
153 c 1. D.C. Sorensen, "Implicit Application of Polynomial Filters in |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
154 c a k-Step Arnoldi Method", SIAM J. Matr. Anal. Apps., 13 (1992), |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
155 c pp 357-385. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
156 c 2. R.B. Lehoucq, "Analysis and Implementation of an Implicitly |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
157 c Restarted Arnoldi Iteration", Rice University Technical Report |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
158 c TR95-13, Department of Computational and Applied Mathematics. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
159 c 3. B.N. Parlett, "The Symmetric Eigenvalue Problem". Prentice-Hall, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
160 c 1980. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
161 c 4. B.N. Parlett, B. Nour-Omid, "Towards a Black Box Lanczos Program", |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
162 c Computer Physics Communications, 53 (1989), pp 169-179. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
163 c 5. B. Nour-Omid, B.N. Parlett, T. Ericson, P.S. Jensen, "How to |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
164 c Implement the Spectral Transformation", Math. Comp., 48 (1987), |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
165 c pp 663-673. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
166 c 6. R.G. Grimes, J.G. Lewis and H.D. Simon, "A Shifted Block Lanczos |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
167 c Algorithm for Solving Sparse Symmetric Generalized Eigenproblems", |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
168 c SIAM J. Matr. Anal. Apps., January (1993). |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
169 c 7. L. Reichel, W.B. Gragg, "Algorithm 686: FORTRAN Subroutines |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
170 c for Updating the QR decomposition", ACM TOMS, December 1990, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
171 c Volume 16 Number 4, pp 369-377. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
172 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
173 c\Remarks |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
174 c 1. The converged Ritz values are always returned in increasing |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
175 c (algebraic) order. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
176 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
177 c 2. Currently only HOWMNY = 'A' is implemented. It is included at this |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
178 c stage for the user who wants to incorporate it. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
179 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
180 c\Routines called: |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
181 c dsesrt ARPACK routine that sorts an array X, and applies the |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
182 c corresponding permutation to a matrix A. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
183 c dsortr dsortr ARPACK sorting routine. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
184 c ivout ARPACK utility routine that prints integers. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
185 c dvout ARPACK utility routine that prints vectors. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
186 c dgeqr2 LAPACK routine that computes the QR factorization of |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
187 c a matrix. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
188 c dlacpy LAPACK matrix copy routine. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
189 c dlamch LAPACK routine that determines machine constants. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
190 c dorm2r LAPACK routine that applies an orthogonal matrix in |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
191 c factored form. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
192 c dsteqr LAPACK routine that computes eigenvalues and eigenvectors |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
193 c of a tridiagonal matrix. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
194 c dger Level 2 BLAS rank one update to a matrix. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
195 c dcopy Level 1 BLAS that copies one vector to another . |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
196 c dnrm2 Level 1 BLAS that computes the norm of a vector. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
197 c dscal Level 1 BLAS that scales a vector. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
198 c dswap Level 1 BLAS that swaps the contents of two vectors. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
199 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
200 c\Authors |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
201 c Danny Sorensen Phuong Vu |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
202 c Richard Lehoucq CRPC / Rice University |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
203 c Chao Yang Houston, Texas |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
204 c Dept. of Computational & |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
205 c Applied Mathematics |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
206 c Rice University |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
207 c Houston, Texas |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
208 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
209 c\Revision history: |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
210 c 12/15/93: Version ' 2.1' |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
211 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
212 c\SCCS Information: @(#) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
213 c FILE: seupd.F SID: 2.11 DATE OF SID: 04/10/01 RELEASE: 2 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
214 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
215 c\EndLib |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
216 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
217 c----------------------------------------------------------------------- |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
218 subroutine dseupd (rvec , howmny, select, d , |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
219 & z , ldz , sigma , bmat , |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
220 & n , which , nev , tol , |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
221 & resid , ncv , v , ldv , |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
222 & iparam, ipntr , workd , workl, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
223 & lworkl, info ) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
224 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
225 c %----------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
226 c | Include files for debugging and timing information | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
227 c %----------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
228 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
229 include 'debug.h' |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
230 include 'stat.h' |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
231 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
232 c %------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
233 c | Scalar Arguments | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
234 c %------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
235 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
236 character bmat, howmny, which*2 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
237 logical rvec |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
238 integer info, ldz, ldv, lworkl, n, ncv, nev |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
239 Double precision |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
240 & sigma, tol |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
241 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
242 c %-----------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
243 c | Array Arguments | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
244 c %-----------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
245 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
246 integer iparam(7), ipntr(11) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
247 logical select(ncv) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
248 Double precision |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
249 & d(nev) , resid(n) , v(ldv,ncv), |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
250 & z(ldz, nev), workd(2*n), workl(lworkl) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
251 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
252 c %------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
253 c | Parameters | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
254 c %------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
255 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
256 Double precision |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
257 & one, zero |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
258 parameter (one = 1.0D+0 , zero = 0.0D+0 ) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
259 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
260 c %---------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
261 c | Local Scalars | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
262 c %---------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
263 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
264 character type*6 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
265 integer bounds , ierr , ih , ihb , ihd , |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
266 & iq , iw , j , k , ldh , |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
267 & ldq , mode , msglvl, nconv , next , |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
268 & ritz , irz , ibd , np , ishift, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
269 & leftptr, rghtptr, numcnv, jj |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
270 Double precision |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
271 & bnorm2 , rnorm, temp, temp1, eps23 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
272 logical reord |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
273 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
274 c %----------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
275 c | External Subroutines | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
276 c %----------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
277 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
278 external dcopy , dger , dgeqr2 , dlacpy , dorm2r , dscal , |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
279 & dsesrt , dsteqr , dswap , dvout , ivout , dsortr |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
280 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
281 c %--------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
282 c | External Functions | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
283 c %--------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
284 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
285 Double precision |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
286 & dnrm2 , dlamch |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
287 external dnrm2 , dlamch |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
288 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
289 c %---------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
290 c | Intrinsic Functions | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
291 c %---------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
292 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
293 intrinsic min |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
294 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
295 c %-----------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
296 c | Executable Statements | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
297 c %-----------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
298 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
299 c %------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
300 c | Set default parameters | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
301 c %------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
302 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
303 msglvl = mseupd |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
304 mode = iparam(7) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
305 nconv = iparam(5) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
306 info = 0 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
307 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
308 c %--------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
309 c | Quick return | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
310 c %--------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
311 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
312 if (nconv .eq. 0) go to 9000 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
313 ierr = 0 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
314 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
315 if (nconv .le. 0) ierr = -14 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
316 if (n .le. 0) ierr = -1 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
317 if (nev .le. 0) ierr = -2 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
318 if (ncv .le. nev .or. ncv .gt. n) ierr = -3 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
319 if (which .ne. 'LM' .and. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
320 & which .ne. 'SM' .and. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
321 & which .ne. 'LA' .and. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
322 & which .ne. 'SA' .and. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
323 & which .ne. 'BE') ierr = -5 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
324 if (bmat .ne. 'I' .and. bmat .ne. 'G') ierr = -6 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
325 if ( (howmny .ne. 'A' .and. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
326 & howmny .ne. 'P' .and. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
327 & howmny .ne. 'S') .and. rvec ) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
328 & ierr = -15 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
329 if (rvec .and. howmny .eq. 'S') ierr = -16 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
330 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
331 if (rvec .and. lworkl .lt. ncv**2+8*ncv) ierr = -7 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
332 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
333 if (mode .eq. 1 .or. mode .eq. 2) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
334 type = 'REGULR' |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
335 else if (mode .eq. 3 ) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
336 type = 'SHIFTI' |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
337 else if (mode .eq. 4 ) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
338 type = 'BUCKLE' |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
339 else if (mode .eq. 5 ) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
340 type = 'CAYLEY' |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
341 else |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
342 ierr = -10 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
343 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
344 if (mode .eq. 1 .and. bmat .eq. 'G') ierr = -11 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
345 if (nev .eq. 1 .and. which .eq. 'BE') ierr = -12 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
346 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
347 c %------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
348 c | Error Exit | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
349 c %------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
350 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
351 if (ierr .ne. 0) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
352 info = ierr |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
353 go to 9000 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
354 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
355 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
356 c %-------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
357 c | Pointer into WORKL for address of H, RITZ, BOUNDS, Q | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
358 c | etc... and the remaining workspace. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
359 c | Also update pointer to be used on output. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
360 c | Memory is laid out as follows: | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
361 c | workl(1:2*ncv) := generated tridiagonal matrix H | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
362 c | The subdiagonal is stored in workl(2:ncv). | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
363 c | The dead spot is workl(1) but upon exiting | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
364 c | dsaupd stores the B-norm of the last residual | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
365 c | vector in workl(1). We use this !!! | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
366 c | workl(2*ncv+1:2*ncv+ncv) := ritz values | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
367 c | The wanted values are in the first NCONV spots. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
368 c | workl(3*ncv+1:3*ncv+ncv) := computed Ritz estimates | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
369 c | The wanted values are in the first NCONV spots. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
370 c | NOTE: workl(1:4*ncv) is set by dsaupd and is not | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
371 c | modified by dseupd . | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
372 c %-------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
373 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
374 c %-------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
375 c | The following is used and set by dseupd . | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
376 c | workl(4*ncv+1:4*ncv+ncv) := used as workspace during | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
377 c | computation of the eigenvectors of H. Stores | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
378 c | the diagonal of H. Upon EXIT contains the NCV | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
379 c | Ritz values of the original system. The first | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
380 c | NCONV spots have the wanted values. If MODE = | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
381 c | 1 or 2 then will equal workl(2*ncv+1:3*ncv). | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
382 c | workl(5*ncv+1:5*ncv+ncv) := used as workspace during | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
383 c | computation of the eigenvectors of H. Stores | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
384 c | the subdiagonal of H. Upon EXIT contains the | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
385 c | NCV corresponding Ritz estimates of the | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
386 c | original system. The first NCONV spots have the | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
387 c | wanted values. If MODE = 1,2 then will equal | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
388 c | workl(3*ncv+1:4*ncv). | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
389 c | workl(6*ncv+1:6*ncv+ncv*ncv) := orthogonal Q that is | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
390 c | the eigenvector matrix for H as returned by | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
391 c | dsteqr . Not referenced if RVEC = .False. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
392 c | Ordering follows that of workl(4*ncv+1:5*ncv) | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
393 c | workl(6*ncv+ncv*ncv+1:6*ncv+ncv*ncv+2*ncv) := | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
394 c | Workspace. Needed by dsteqr and by dseupd . | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
395 c | GRAND total of NCV*(NCV+8) locations. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
396 c %-------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
397 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
398 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
399 ih = ipntr(5) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
400 ritz = ipntr(6) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
401 bounds = ipntr(7) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
402 ldh = ncv |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
403 ldq = ncv |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
404 ihd = bounds + ldh |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
405 ihb = ihd + ldh |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
406 iq = ihb + ldh |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
407 iw = iq + ldh*ncv |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
408 next = iw + 2*ncv |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
409 ipntr(4) = next |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
410 ipntr(8) = ihd |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
411 ipntr(9) = ihb |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
412 ipntr(10) = iq |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
413 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
414 c %----------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
415 c | irz points to the Ritz values computed | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
416 c | by _seigt before exiting _saup2. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
417 c | ibd points to the Ritz estimates | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
418 c | computed by _seigt before exiting | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
419 c | _saup2. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
420 c %----------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
421 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
422 irz = ipntr(11)+ncv |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
423 ibd = irz+ncv |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
424 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
425 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
426 c %---------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
427 c | Set machine dependent constant. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
428 c %---------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
429 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
430 eps23 = dlamch ('Epsilon-Machine') |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
431 eps23 = eps23**(2.0D+0 / 3.0D+0 ) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
432 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
433 c %---------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
434 c | RNORM is B-norm of the RESID(1:N). | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
435 c | BNORM2 is the 2 norm of B*RESID(1:N). | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
436 c | Upon exit of dsaupd WORKD(1:N) has | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
437 c | B*RESID(1:N). | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
438 c %---------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
439 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
440 rnorm = workl(ih) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
441 if (bmat .eq. 'I') then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
442 bnorm2 = rnorm |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
443 else if (bmat .eq. 'G') then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
444 bnorm2 = dnrm2 (n, workd, 1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
445 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
446 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
447 if (msglvl .gt. 2) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
448 call dvout (logfil, ncv, workl(irz), ndigit, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
449 & '_seupd: Ritz values passed in from _SAUPD.') |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
450 call dvout (logfil, ncv, workl(ibd), ndigit, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
451 & '_seupd: Ritz estimates passed in from _SAUPD.') |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
452 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
453 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
454 if (rvec) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
455 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
456 reord = .false. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
457 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
458 c %---------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
459 c | Use the temporary bounds array to store indices | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
460 c | These will be used to mark the select array later | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
461 c %---------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
462 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
463 do 10 j = 1,ncv |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
464 workl(bounds+j-1) = j |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
465 select(j) = .false. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
466 10 continue |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
467 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
468 c %-------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
469 c | Select the wanted Ritz values. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
470 c | Sort the Ritz values so that the | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
471 c | wanted ones appear at the tailing | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
472 c | NEV positions of workl(irr) and | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
473 c | workl(iri). Move the corresponding | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
474 c | error estimates in workl(bound) | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
475 c | accordingly. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
476 c %-------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
477 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
478 np = ncv - nev |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
479 ishift = 0 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
480 call dsgets (ishift, which , nev , |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
481 & np , workl(irz) , workl(bounds), |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
482 & workl) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
483 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
484 if (msglvl .gt. 2) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
485 call dvout (logfil, ncv, workl(irz), ndigit, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
486 & '_seupd: Ritz values after calling _SGETS.') |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
487 call dvout (logfil, ncv, workl(bounds), ndigit, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
488 & '_seupd: Ritz value indices after calling _SGETS.') |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
489 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
490 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
491 c %-----------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
492 c | Record indices of the converged wanted Ritz values | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
493 c | Mark the select array for possible reordering | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
494 c %-----------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
495 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
496 numcnv = 0 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
497 do 11 j = 1,ncv |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
498 temp1 = max(eps23, abs(workl(irz+ncv-j)) ) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
499 jj = workl(bounds + ncv - j) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
500 if (numcnv .lt. nconv .and. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
501 & workl(ibd+jj-1) .le. tol*temp1) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
502 select(jj) = .true. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
503 numcnv = numcnv + 1 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
504 if (jj .gt. nev) reord = .true. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
505 endif |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
506 11 continue |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
507 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
508 c %-----------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
509 c | Check the count (numcnv) of converged Ritz values with | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
510 c | the number (nconv) reported by _saupd. If these two | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
511 c | are different then there has probably been an error | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
512 c | caused by incorrect passing of the _saupd data. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
513 c %-----------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
514 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
515 if (msglvl .gt. 2) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
516 call ivout(logfil, 1, numcnv, ndigit, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
517 & '_seupd: Number of specified eigenvalues') |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
518 call ivout(logfil, 1, nconv, ndigit, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
519 & '_seupd: Number of "converged" eigenvalues') |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
520 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
521 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
522 if (numcnv .ne. nconv) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
523 info = -17 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
524 go to 9000 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
525 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
526 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
527 c %-----------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
528 c | Call LAPACK routine _steqr to compute the eigenvalues and | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
529 c | eigenvectors of the final symmetric tridiagonal matrix H. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
530 c | Initialize the eigenvector matrix Q to the identity. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
531 c %-----------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
532 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
533 call dcopy (ncv-1, workl(ih+1), 1, workl(ihb), 1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
534 call dcopy (ncv, workl(ih+ldh), 1, workl(ihd), 1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
535 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
536 call dsteqr ('Identity', ncv, workl(ihd), workl(ihb), |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
537 & workl(iq) , ldq, workl(iw), ierr) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
538 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
539 if (ierr .ne. 0) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
540 info = -8 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
541 go to 9000 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
542 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
543 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
544 if (msglvl .gt. 1) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
545 call dcopy (ncv, workl(iq+ncv-1), ldq, workl(iw), 1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
546 call dvout (logfil, ncv, workl(ihd), ndigit, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
547 & '_seupd: NCV Ritz values of the final H matrix') |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
548 call dvout (logfil, ncv, workl(iw), ndigit, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
549 & '_seupd: last row of the eigenvector matrix for H') |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
550 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
551 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
552 if (reord) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
553 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
554 c %---------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
555 c | Reordered the eigenvalues and eigenvectors | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
556 c | computed by _steqr so that the "converged" | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
557 c | eigenvalues appear in the first NCONV | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
558 c | positions of workl(ihd), and the associated | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
559 c | eigenvectors appear in the first NCONV | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
560 c | columns. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
561 c %---------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
562 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
563 leftptr = 1 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
564 rghtptr = ncv |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
565 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
566 if (ncv .eq. 1) go to 30 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
567 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
568 20 if (select(leftptr)) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
569 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
570 c %-------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
571 c | Search, from the left, for the first Ritz | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
572 c | value that has not converged. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
573 c %-------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
574 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
575 leftptr = leftptr + 1 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
576 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
577 else if ( .not. select(rghtptr)) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
578 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
579 c %----------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
580 c | Search, from the right, the first Ritz value | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
581 c | that has converged. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
582 c %----------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
583 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
584 rghtptr = rghtptr - 1 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
585 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
586 else |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
587 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
588 c %----------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
589 c | Swap the Ritz value on the left that has not | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
590 c | converged with the Ritz value on the right | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
591 c | that has converged. Swap the associated | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
592 c | eigenvector of the tridiagonal matrix H as | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
593 c | well. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
594 c %----------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
595 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
596 temp = workl(ihd+leftptr-1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
597 workl(ihd+leftptr-1) = workl(ihd+rghtptr-1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
598 workl(ihd+rghtptr-1) = temp |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
599 call dcopy (ncv, workl(iq+ncv*(leftptr-1)), 1, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
600 & workl(iw), 1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
601 call dcopy (ncv, workl(iq+ncv*(rghtptr-1)), 1, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
602 & workl(iq+ncv*(leftptr-1)), 1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
603 call dcopy (ncv, workl(iw), 1, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
604 & workl(iq+ncv*(rghtptr-1)), 1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
605 leftptr = leftptr + 1 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
606 rghtptr = rghtptr - 1 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
607 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
608 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
609 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
610 if (leftptr .lt. rghtptr) go to 20 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
611 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
612 30 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
613 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
614 if (msglvl .gt. 2) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
615 call dvout (logfil, ncv, workl(ihd), ndigit, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
616 & '_seupd: The eigenvalues of H--reordered') |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
617 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
618 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
619 c %----------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
620 c | Load the converged Ritz values into D. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
621 c %----------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
622 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
623 call dcopy (nconv, workl(ihd), 1, d, 1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
624 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
625 else |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
626 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
627 c %-----------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
628 c | Ritz vectors not required. Load Ritz values into D. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
629 c %-----------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
630 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
631 call dcopy (nconv, workl(ritz), 1, d, 1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
632 call dcopy (ncv, workl(ritz), 1, workl(ihd), 1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
633 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
634 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
635 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
636 c %------------------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
637 c | Transform the Ritz values and possibly vectors and corresponding | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
638 c | Ritz estimates of OP to those of A*x=lambda*B*x. The Ritz values | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
639 c | (and corresponding data) are returned in ascending order. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
640 c %------------------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
641 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
642 if (type .eq. 'REGULR') then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
643 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
644 c %---------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
645 c | Ascending sort of wanted Ritz values, vectors and error | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
646 c | bounds. Not necessary if only Ritz values are desired. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
647 c %---------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
648 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
649 if (rvec) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
650 call dsesrt ('LA', rvec , nconv, d, ncv, workl(iq), ldq) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
651 else |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
652 call dcopy (ncv, workl(bounds), 1, workl(ihb), 1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
653 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
654 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
655 else |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
656 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
657 c %-------------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
658 c | * Make a copy of all the Ritz values. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
659 c | * Transform the Ritz values back to the original system. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
660 c | For TYPE = 'SHIFTI' the transformation is | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
661 c | lambda = 1/theta + sigma | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
662 c | For TYPE = 'BUCKLE' the transformation is | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
663 c | lambda = sigma * theta / ( theta - 1 ) | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
664 c | For TYPE = 'CAYLEY' the transformation is | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
665 c | lambda = sigma * (theta + 1) / (theta - 1 ) | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
666 c | where the theta are the Ritz values returned by dsaupd . | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
667 c | NOTES: | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
668 c | *The Ritz vectors are not affected by the transformation. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
669 c | They are only reordered. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
670 c %-------------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
671 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
672 call dcopy (ncv, workl(ihd), 1, workl(iw), 1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
673 if (type .eq. 'SHIFTI') then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
674 do 40 k=1, ncv |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
675 workl(ihd+k-1) = one / workl(ihd+k-1) + sigma |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
676 40 continue |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
677 else if (type .eq. 'BUCKLE') then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
678 do 50 k=1, ncv |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
679 workl(ihd+k-1) = sigma * workl(ihd+k-1) / |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
680 & (workl(ihd+k-1) - one) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
681 50 continue |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
682 else if (type .eq. 'CAYLEY') then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
683 do 60 k=1, ncv |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
684 workl(ihd+k-1) = sigma * (workl(ihd+k-1) + one) / |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
685 & (workl(ihd+k-1) - one) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
686 60 continue |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
687 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
688 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
689 c %-------------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
690 c | * Store the wanted NCONV lambda values into D. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
691 c | * Sort the NCONV wanted lambda in WORKL(IHD:IHD+NCONV-1) | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
692 c | into ascending order and apply sort to the NCONV theta | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
693 c | values in the transformed system. We will need this to | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
694 c | compute Ritz estimates in the original system. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
695 c | * Finally sort the lambda`s into ascending order and apply | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
696 c | to Ritz vectors if wanted. Else just sort lambda`s into | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
697 c | ascending order. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
698 c | NOTES: | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
699 c | *workl(iw:iw+ncv-1) contain the theta ordered so that they | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
700 c | match the ordering of the lambda. We`ll use them again for | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
701 c | Ritz vector purification. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
702 c %-------------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
703 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
704 call dcopy (nconv, workl(ihd), 1, d, 1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
705 call dsortr ('LA', .true., nconv, workl(ihd), workl(iw)) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
706 if (rvec) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
707 call dsesrt ('LA', rvec , nconv, d, ncv, workl(iq), ldq) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
708 else |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
709 call dcopy (ncv, workl(bounds), 1, workl(ihb), 1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
710 call dscal (ncv, bnorm2/rnorm, workl(ihb), 1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
711 call dsortr ('LA', .true., nconv, d, workl(ihb)) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
712 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
713 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
714 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
715 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
716 c %------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
717 c | Compute the Ritz vectors. Transform the wanted | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
718 c | eigenvectors of the symmetric tridiagonal H by | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
719 c | the Lanczos basis matrix V. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
720 c %------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
721 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
722 if (rvec .and. howmny .eq. 'A') then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
723 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
724 c %----------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
725 c | Compute the QR factorization of the matrix representing | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
726 c | the wanted invariant subspace located in the first NCONV | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
727 c | columns of workl(iq,ldq). | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
728 c %----------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
729 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
730 call dgeqr2 (ncv, nconv , workl(iq) , |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
731 & ldq, workl(iw+ncv), workl(ihb), |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
732 & ierr) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
733 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
734 c %--------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
735 c | * Postmultiply V by Q. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
736 c | * Copy the first NCONV columns of VQ into Z. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
737 c | The N by NCONV matrix Z is now a matrix representation | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
738 c | of the approximate invariant subspace associated with | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
739 c | the Ritz values in workl(ihd). | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
740 c %--------------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
741 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
742 call dorm2r ('Right', 'Notranspose', n , |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
743 & ncv , nconv , workl(iq), |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
744 & ldq , workl(iw+ncv), v , |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
745 & ldv , workd(n+1) , ierr) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
746 call dlacpy ('All', n, nconv, v, ldv, z, ldz) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
747 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
748 c %-----------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
749 c | In order to compute the Ritz estimates for the Ritz | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
750 c | values in both systems, need the last row of the | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
751 c | eigenvector matrix. Remember, it`s in factored form | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
752 c %-----------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
753 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
754 do 65 j = 1, ncv-1 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
755 workl(ihb+j-1) = zero |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
756 65 continue |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
757 workl(ihb+ncv-1) = one |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
758 call dorm2r ('Left', 'Transpose' , ncv , |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
759 & 1 , nconv , workl(iq) , |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
760 & ldq , workl(iw+ncv), workl(ihb), |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
761 & ncv , temp , ierr) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
762 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
763 else if (rvec .and. howmny .eq. 'S') then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
764 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
765 c Not yet implemented. See remark 2 above. |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
766 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
767 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
768 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
769 if (type .eq. 'REGULR' .and. rvec) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
770 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
771 do 70 j=1, ncv |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
772 workl(ihb+j-1) = rnorm * abs( workl(ihb+j-1) ) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
773 70 continue |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
774 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
775 else if (type .ne. 'REGULR' .and. rvec) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
776 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
777 c %-------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
778 c | * Determine Ritz estimates of the theta. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
779 c | If RVEC = .true. then compute Ritz estimates | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
780 c | of the theta. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
781 c | If RVEC = .false. then copy Ritz estimates | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
782 c | as computed by dsaupd . | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
783 c | * Determine Ritz estimates of the lambda. | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
784 c %-------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
785 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
786 call dscal (ncv, bnorm2, workl(ihb), 1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
787 if (type .eq. 'SHIFTI') then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
788 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
789 do 80 k=1, ncv |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
790 workl(ihb+k-1) = abs( workl(ihb+k-1) ) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
791 & / workl(iw+k-1)**2 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
792 80 continue |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
793 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
794 else if (type .eq. 'BUCKLE') then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
795 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
796 do 90 k=1, ncv |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
797 workl(ihb+k-1) = sigma * abs( workl(ihb+k-1) ) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
798 & / (workl(iw+k-1)-one )**2 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
799 90 continue |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
800 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
801 else if (type .eq. 'CAYLEY') then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
802 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
803 do 100 k=1, ncv |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
804 workl(ihb+k-1) = abs( workl(ihb+k-1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
805 & / workl(iw+k-1)*(workl(iw+k-1)-one) ) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
806 100 continue |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
807 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
808 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
809 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
810 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
811 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
812 if (type .ne. 'REGULR' .and. msglvl .gt. 1) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
813 call dvout (logfil, nconv, d, ndigit, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
814 & '_seupd: Untransformed converged Ritz values') |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
815 call dvout (logfil, nconv, workl(ihb), ndigit, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
816 & '_seupd: Ritz estimates of the untransformed Ritz values') |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
817 else if (msglvl .gt. 1) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
818 call dvout (logfil, nconv, d, ndigit, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
819 & '_seupd: Converged Ritz values') |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
820 call dvout (logfil, nconv, workl(ihb), ndigit, |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
821 & '_seupd: Associated Ritz estimates') |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
822 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
823 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
824 c %-------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
825 c | Ritz vector purification step. Formally perform | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
826 c | one of inverse subspace iteration. Only used | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
827 c | for MODE = 3,4,5. See reference 7 | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
828 c %-------------------------------------------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
829 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
830 if (rvec .and. (type .eq. 'SHIFTI' .or. type .eq. 'CAYLEY')) then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
831 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
832 do 110 k=0, nconv-1 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
833 workl(iw+k) = workl(iq+k*ldq+ncv-1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
834 & / workl(iw+k) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
835 110 continue |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
836 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
837 else if (rvec .and. type .eq. 'BUCKLE') then |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
838 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
839 do 120 k=0, nconv-1 |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
840 workl(iw+k) = workl(iq+k*ldq+ncv-1) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
841 & / (workl(iw+k)-one) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
842 120 continue |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
843 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
844 end if |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
845 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
846 if (type .ne. 'REGULR') |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
847 & call dger (n, nconv, one, resid, 1, workl(iw), 1, z, ldz) |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
848 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
849 9000 continue |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
850 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
851 return |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
852 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
853 c %---------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
854 c | End of dseupd | |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
855 c %---------------% |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
856 c |
9f5d2ef078e8
import ARPACK sources to libcruft from Debian package libarpack2 2.1+parpack96.dfsg-3+b1
John W. Eaton <jwe@octave.org>
parents:
diff
changeset
|
857 end |