Skip to content

Commit ecaf399

Browse files
authored
Merge pull request #572 from jip/fix
Fix some typos in code and comments
2 parents effe175 + 8b992fb commit ecaf399

120 files changed

Lines changed: 334 additions & 323 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

SRC/zhetf2_rk.f

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -417,7 +417,7 @@ SUBROUTINE ZHETF2_RK( UPLO, N, A, LDA, E, IPIV, INFO )
417417
*
418418
* Case(2)
419419
* Equivalent to testing for
420-
* ABS( REAL( W( IMAX,KW-1 ) ) ).GE.ALPHA*ROWMAX
420+
* ABS( DBLE( W( IMAX,KW-1 ) ) ).GE.ALPHA*ROWMAX
421421
* (used to handle NaN and Inf)
422422
*
423423
IF( .NOT.( ABS( DBLE( A( IMAX, IMAX ) ) )
@@ -770,7 +770,7 @@ SUBROUTINE ZHETF2_RK( UPLO, N, A, LDA, E, IPIV, INFO )
770770
*
771771
* Case(2)
772772
* Equivalent to testing for
773-
* ABS( REAL( W( IMAX,KW-1 ) ) ).GE.ALPHA*ROWMAX
773+
* ABS( DBLE( W( IMAX,KW-1 ) ) ).GE.ALPHA*ROWMAX
774774
* (used to handle NaN and Inf)
775775
*
776776
IF( .NOT.( ABS( DBLE( A( IMAX, IMAX ) ) )

SRC/zhetf2_rook.f

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -357,7 +357,7 @@ SUBROUTINE ZHETF2_ROOK( UPLO, N, A, LDA, IPIV, INFO )
357357
*
358358
* Case(2)
359359
* Equivalent to testing for
360-
* ABS( REAL( W( IMAX,KW-1 ) ) ).GE.ALPHA*ROWMAX
360+
* ABS( DBLE( W( IMAX,KW-1 ) ) ).GE.ALPHA*ROWMAX
361361
* (used to handle NaN and Inf)
362362
*
363363
IF( .NOT.( ABS( DBLE( A( IMAX, IMAX ) ) )
@@ -669,7 +669,7 @@ SUBROUTINE ZHETF2_ROOK( UPLO, N, A, LDA, IPIV, INFO )
669669
*
670670
* Case(2)
671671
* Equivalent to testing for
672-
* ABS( REAL( W( IMAX,KW-1 ) ) ).GE.ALPHA*ROWMAX
672+
* ABS( DBLE( W( IMAX,KW-1 ) ) ).GE.ALPHA*ROWMAX
673673
* (used to handle NaN and Inf)
674674
*
675675
IF( .NOT.( ABS( DBLE( A( IMAX, IMAX ) ) )

SRC/zlahef_rk.f

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -460,7 +460,7 @@ SUBROUTINE ZLAHEF_RK( UPLO, N, NB, KB, A, LDA, E, IPIV, W, LDW,
460460
*
461461
* Case(2)
462462
* Equivalent to testing for
463-
* ABS( REAL( W( IMAX,KW-1 ) ) ).GE.ALPHA*ROWMAX
463+
* ABS( DBLE( W( IMAX,KW-1 ) ) ).GE.ALPHA*ROWMAX
464464
* (used to handle NaN and Inf)
465465
*
466466
IF( .NOT.( ABS( DBLE( W( IMAX,KW-1 ) ) )
@@ -599,7 +599,7 @@ SUBROUTINE ZLAHEF_RK( UPLO, N, NB, KB, A, LDA, E, IPIV, W, LDW,
599599
* A(1:k-1,k) := U(1:k-1,k) = W(1:k-1,kw)/D(k,k)
600600
*
601601
* (NOTE: No need to use for Hermitian matrix
602-
* A( K, K ) = REAL( W( K, K) ) to separately copy diagonal
602+
* A( K, K ) = DBLE( W( K, K) ) to separately copy diagonal
603603
* element D(k,k) from W (potentially saves only one load))
604604
CALL ZCOPY( K, W( 1, KW ), 1, A( 1, K ), 1 )
605605
IF( K.GT.1 ) THEN
@@ -912,7 +912,7 @@ SUBROUTINE ZLAHEF_RK( UPLO, N, NB, KB, A, LDA, E, IPIV, W, LDW,
912912
*
913913
* Case(2)
914914
* Equivalent to testing for
915-
* ABS( REAL( W( IMAX,K+1 ) ) ).GE.ALPHA*ROWMAX
915+
* ABS( DBLE( W( IMAX,K+1 ) ) ).GE.ALPHA*ROWMAX
916916
* (used to handle NaN and Inf)
917917
*
918918
IF( .NOT.( ABS( DBLE( W( IMAX,K+1 ) ) )
@@ -1042,7 +1042,7 @@ SUBROUTINE ZLAHEF_RK( UPLO, N, NB, KB, A, LDA, E, IPIV, W, LDW,
10421042
* A(k+1:N,k) := L(k+1:N,k) = W(k+1:N,k)/D(k,k)
10431043
*
10441044
* (NOTE: No need to use for Hermitian matrix
1045-
* A( K, K ) = REAL( W( K, K) ) to separately copy diagonal
1045+
* A( K, K ) = DBLE( W( K, K) ) to separately copy diagonal
10461046
* element D(k,k) from W (potentially saves only one load))
10471047
CALL ZCOPY( N-K+1, W( K, K ), 1, A( K, K ), 1 )
10481048
IF( K.LT.N ) THEN

SRC/zlahef_rook.f

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,7 @@ SUBROUTINE ZLAHEF_ROOK( UPLO, N, NB, KB, A, LDA, IPIV, W, LDW,
370370
*
371371
* Case(2)
372372
* Equivalent to testing for
373-
* ABS( REAL( W( IMAX,KW-1 ) ) ).GE.ALPHA*ROWMAX
373+
* ABS( DBLE( W( IMAX,KW-1 ) ) ).GE.ALPHA*ROWMAX
374374
* (used to handle NaN and Inf)
375375
*
376376
IF( .NOT.( ABS( DBLE( W( IMAX,KW-1 ) ) )
@@ -509,7 +509,7 @@ SUBROUTINE ZLAHEF_ROOK( UPLO, N, NB, KB, A, LDA, IPIV, W, LDW,
509509
* A(1:k-1,k) := U(1:k-1,k) = W(1:k-1,kw)/D(k,k)
510510
*
511511
* (NOTE: No need to use for Hermitian matrix
512-
* A( K, K ) = REAL( W( K, K) ) to separately copy diagonal
512+
* A( K, K ) = DBLE( W( K, K) ) to separately copy diagonal
513513
* element D(k,k) from W (potentially saves only one load))
514514
CALL ZCOPY( K, W( 1, KW ), 1, A( 1, K ), 1 )
515515
IF( K.GT.1 ) THEN
@@ -833,7 +833,7 @@ SUBROUTINE ZLAHEF_ROOK( UPLO, N, NB, KB, A, LDA, IPIV, W, LDW,
833833
*
834834
* Case(2)
835835
* Equivalent to testing for
836-
* ABS( REAL( W( IMAX,K+1 ) ) ).GE.ALPHA*ROWMAX
836+
* ABS( DBLE( W( IMAX,K+1 ) ) ).GE.ALPHA*ROWMAX
837837
* (used to handle NaN and Inf)
838838
*
839839
IF( .NOT.( ABS( DBLE( W( IMAX,K+1 ) ) )
@@ -963,7 +963,7 @@ SUBROUTINE ZLAHEF_ROOK( UPLO, N, NB, KB, A, LDA, IPIV, W, LDW,
963963
* A(k+1:N,k) := L(k+1:N,k) = W(k+1:N,k)/D(k,k)
964964
*
965965
* (NOTE: No need to use for Hermitian matrix
966-
* A( K, K ) = REAL( W( K, K) ) to separately copy diagonal
966+
* A( K, K ) = DBLE( W( K, K) ) to separately copy diagonal
967967
* element D(k,k) from W (potentially saves only one load))
968968
CALL ZCOPY( N-K+1, W( K, K ), 1, A( K, K ), 1 )
969969
IF( K.LT.N ) THEN

SRC/ztrevc3.f

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -286,13 +286,13 @@ SUBROUTINE ZTREVC3( SIDE, HOWMNY, SELECT, N, T, LDT, VL, LDVL, VR,
286286
$ ZGEMM, DLABAD, ZLASET, ZLACPY
287287
* ..
288288
* .. Intrinsic Functions ..
289-
INTRINSIC ABS, DBLE, DCMPLX, CONJG, AIMAG, MAX
289+
INTRINSIC ABS, DBLE, DCMPLX, CONJG, DIMAG, MAX
290290
* ..
291291
* .. Statement Functions ..
292292
DOUBLE PRECISION CABS1
293293
* ..
294294
* .. Statement Function definitions ..
295-
CABS1( CDUM ) = ABS( DBLE( CDUM ) ) + ABS( AIMAG( CDUM ) )
295+
CABS1( CDUM ) = ABS( DBLE( CDUM ) ) + ABS( DIMAG( CDUM ) )
296296
* ..
297297
* .. Executable Statements ..
298298
*

TESTING/EIG/cbdt01.f

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,13 @@
2828
*> \verbatim
2929
*>
3030
*> CBDT01 reconstructs a general matrix A from its bidiagonal form
31-
*> A = Q * B * P'
32-
*> where Q (m by min(m,n)) and P' (min(m,n) by n) are unitary
31+
*> A = Q * B * P**H
32+
*> where Q (m by min(m,n)) and P**H (min(m,n) by n) are unitary
3333
*> matrices and B is bidiagonal.
3434
*>
3535
*> The test ratio to test the reduction is
36-
*> RESID = norm( A - Q * B * PT ) / ( n * norm(A) * EPS )
37-
*> where PT = P' and EPS is the machine precision.
36+
*> RESID = norm(A - Q * B * P**H) / ( n * norm(A) * EPS )
37+
*> where EPS is the machine precision.
3838
*> \endverbatim
3939
*
4040
* Arguments:
@@ -49,7 +49,7 @@
4949
*> \param[in] N
5050
*> \verbatim
5151
*> N is INTEGER
52-
*> The number of columns of the matrices A and P'.
52+
*> The number of columns of the matrices A and P**H.
5353
*> \endverbatim
5454
*>
5555
*> \param[in] KD
@@ -78,7 +78,7 @@
7878
*> \verbatim
7979
*> Q is COMPLEX array, dimension (LDQ,N)
8080
*> The m by min(m,n) unitary matrix Q in the reduction
81-
*> A = Q * B * P'.
81+
*> A = Q * B * P**H.
8282
*> \endverbatim
8383
*>
8484
*> \param[in] LDQ
@@ -103,8 +103,8 @@
103103
*> \param[in] PT
104104
*> \verbatim
105105
*> PT is COMPLEX array, dimension (LDPT,N)
106-
*> The min(m,n) by n unitary matrix P' in the reduction
107-
*> A = Q * B * P'.
106+
*> The min(m,n) by n unitary matrix P**H in the reduction
107+
*> A = Q * B * P**H.
108108
*> \endverbatim
109109
*>
110110
*> \param[in] LDPT
@@ -127,7 +127,8 @@
127127
*> \param[out] RESID
128128
*> \verbatim
129129
*> RESID is REAL
130-
*> The test ratio: norm(A - Q * B * P') / ( n * norm(A) * EPS )
130+
*> The test ratio:
131+
*> norm(A - Q * B * P**H) / ( n * norm(A) * EPS )
131132
*> \endverbatim
132133
*
133134
* Authors:
@@ -187,7 +188,7 @@ SUBROUTINE CBDT01( M, N, KD, A, LDA, Q, LDQ, D, E, PT, LDPT, WORK,
187188
RETURN
188189
END IF
189190
*
190-
* Compute A - Q * B * P' one column at a time.
191+
* Compute A - Q * B * P**H one column at a time.
191192
*
192193
RESID = ZERO
193194
IF( KD.NE.0 ) THEN
@@ -265,7 +266,7 @@ SUBROUTINE CBDT01( M, N, KD, A, LDA, Q, LDQ, D, E, PT, LDPT, WORK,
265266
END IF
266267
END IF
267268
*
268-
* Compute norm(A - Q * B * P') / ( n * norm(A) * EPS )
269+
* Compute norm(A - Q * B * P**H) / ( n * norm(A) * EPS )
269270
*
270271
ANORM = CLANGE( '1', M, N, A, LDA, RWORK )
271272
EPS = SLAMCH( 'Precision' )

TESTING/EIG/cbdt02.f

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,10 @@
2727
*>
2828
*> \verbatim
2929
*>
30-
*> CBDT02 tests the change of basis C = U' * B by computing the residual
30+
*> CBDT02 tests the change of basis C = U**H * B by computing the
31+
*> residual
3132
*>
32-
*> RESID = norm( B - U * C ) / ( max(m,n) * norm(B) * EPS ),
33+
*> RESID = norm(B - U * C) / ( max(m,n) * norm(B) * EPS ),
3334
*>
3435
*> where B and C are M by N matrices, U is an M by M orthogonal matrix,
3536
*> and EPS is the machine precision.
@@ -66,7 +67,7 @@
6667
*> \param[in] C
6768
*> \verbatim
6869
*> C is COMPLEX array, dimension (LDC,N)
69-
*> The m by n matrix C, assumed to contain U' * B.
70+
*> The m by n matrix C, assumed to contain U**H * B.
7071
*> \endverbatim
7172
*>
7273
*> \param[in] LDC
@@ -100,7 +101,7 @@
100101
*> \param[out] RESID
101102
*> \verbatim
102103
*> RESID is REAL
103-
*> RESID = norm( B - U * C ) / ( max(m,n) * norm(B) * EPS ),
104+
*> RESID = norm(B - U * C) / ( max(m,n) * norm(B) * EPS ),
104105
*> \endverbatim
105106
*
106107
* Authors:
@@ -161,7 +162,7 @@ SUBROUTINE CBDT02( M, N, B, LDB, C, LDC, U, LDU, WORK, RWORK,
161162
REALMN = REAL( MAX( M, N ) )
162163
EPS = SLAMCH( 'Precision' )
163164
*
164-
* Compute norm( B - U * C )
165+
* Compute norm(B - U * C)
165166
*
166167
DO 10 J = 1, N
167168
CALL CCOPY( M, B( 1, J ), 1, WORK, 1 )

TESTING/EIG/clarhs.f

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,8 @@
2929
*>
3030
*> CLARHS chooses a set of NRHS random solution vectors and sets
3131
*> up the right hand sides for the linear system
32-
*> op( A ) * X = B,
33-
*> where op( A ) may be A, A**T (transpose of A), or A**H (conjugate
34-
*> transpose of A).
32+
*> op(A) * X = B,
33+
*> where op(A) = A, A**T or A**H, depending on TRANS.
3534
*> \endverbatim
3635
*
3736
* Arguments:
@@ -85,9 +84,9 @@
8584
*> TRANS is CHARACTER*1
8685
*> Used only if A is nonsymmetric; specifies the operation
8786
*> applied to the matrix A.
88-
*> = 'N': B := A * X
89-
*> = 'T': B := A**T * X
90-
*> = 'C': B := A**H * X
87+
*> = 'N': B := A * X (No transpose)
88+
*> = 'T': B := A**T * X (Transpose)
89+
*> = 'C': B := A**H * X (Conjugate transpose)
9190
*> \endverbatim
9291
*>
9392
*> \param[in] M
@@ -313,7 +312,7 @@ SUBROUTINE CLARHS( PATH, XTYPE, UPLO, TRANS, M, N, KL, KU, NRHS,
313312
10 CONTINUE
314313
END IF
315314
*
316-
* Multiply X by op( A ) using an appropriate
315+
* Multiply X by op(A) using an appropriate
317316
* matrix multiply routine.
318317
*
319318
IF( LSAMEN( 2, C2, 'GE' ) .OR. LSAMEN( 2, C2, 'QR' ) .OR.

TESTING/EIG/dbdt01.f

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,13 @@
2727
*> \verbatim
2828
*>
2929
*> DBDT01 reconstructs a general matrix A from its bidiagonal form
30-
*> A = Q * B * P'
31-
*> where Q (m by min(m,n)) and P' (min(m,n) by n) are orthogonal
30+
*> A = Q * B * P**T
31+
*> where Q (m by min(m,n)) and P**T (min(m,n) by n) are orthogonal
3232
*> matrices and B is bidiagonal.
3333
*>
3434
*> The test ratio to test the reduction is
35-
*> RESID = norm( A - Q * B * PT ) / ( n * norm(A) * EPS )
36-
*> where PT = P' and EPS is the machine precision.
35+
*> RESID = norm(A - Q * B * P**T) / ( n * norm(A) * EPS )
36+
*> where EPS is the machine precision.
3737
*> \endverbatim
3838
*
3939
* Arguments:
@@ -48,7 +48,7 @@
4848
*> \param[in] N
4949
*> \verbatim
5050
*> N is INTEGER
51-
*> The number of columns of the matrices A and P'.
51+
*> The number of columns of the matrices A and P**T.
5252
*> \endverbatim
5353
*>
5454
*> \param[in] KD
@@ -77,7 +77,7 @@
7777
*> \verbatim
7878
*> Q is DOUBLE PRECISION array, dimension (LDQ,N)
7979
*> The m by min(m,n) orthogonal matrix Q in the reduction
80-
*> A = Q * B * P'.
80+
*> A = Q * B * P**T.
8181
*> \endverbatim
8282
*>
8383
*> \param[in] LDQ
@@ -102,8 +102,8 @@
102102
*> \param[in] PT
103103
*> \verbatim
104104
*> PT is DOUBLE PRECISION array, dimension (LDPT,N)
105-
*> The min(m,n) by n orthogonal matrix P' in the reduction
106-
*> A = Q * B * P'.
105+
*> The min(m,n) by n orthogonal matrix P**T in the reduction
106+
*> A = Q * B * P**T.
107107
*> \endverbatim
108108
*>
109109
*> \param[in] LDPT
@@ -121,7 +121,8 @@
121121
*> \param[out] RESID
122122
*> \verbatim
123123
*> RESID is DOUBLE PRECISION
124-
*> The test ratio: norm(A - Q * B * P') / ( n * norm(A) * EPS )
124+
*> The test ratio:
125+
*> norm(A - Q * B * P**T) / ( n * norm(A) * EPS )
125126
*> \endverbatim
126127
*
127128
* Authors:
@@ -180,7 +181,7 @@ SUBROUTINE DBDT01( M, N, KD, A, LDA, Q, LDQ, D, E, PT, LDPT, WORK,
180181
RETURN
181182
END IF
182183
*
183-
* Compute A - Q * B * P' one column at a time.
184+
* Compute A - Q * B * P**T one column at a time.
184185
*
185186
RESID = ZERO
186187
IF( KD.NE.0 ) THEN
@@ -258,7 +259,7 @@ SUBROUTINE DBDT01( M, N, KD, A, LDA, Q, LDQ, D, E, PT, LDPT, WORK,
258259
END IF
259260
END IF
260261
*
261-
* Compute norm(A - Q * B * P') / ( n * norm(A) * EPS )
262+
* Compute norm(A - Q * B * P**T) / ( n * norm(A) * EPS )
262263
*
263264
ANORM = DLANGE( '1', M, N, A, LDA, WORK )
264265
EPS = DLAMCH( 'Precision' )

TESTING/EIG/dbdt02.f

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,10 @@
2525
*>
2626
*> \verbatim
2727
*>
28-
*> DBDT02 tests the change of basis C = U' * B by computing the residual
28+
*> DBDT02 tests the change of basis C = U**H * B by computing the
29+
*> residual
2930
*>
30-
*> RESID = norm( B - U * C ) / ( max(m,n) * norm(B) * EPS ),
31+
*> RESID = norm(B - U * C) / ( max(m,n) * norm(B) * EPS ),
3132
*>
3233
*> where B and C are M by N matrices, U is an M by M orthogonal matrix,
3334
*> and EPS is the machine precision.
@@ -64,7 +65,7 @@
6465
*> \param[in] C
6566
*> \verbatim
6667
*> C is DOUBLE PRECISION array, dimension (LDC,N)
67-
*> The m by n matrix C, assumed to contain U' * B.
68+
*> The m by n matrix C, assumed to contain U**H * B.
6869
*> \endverbatim
6970
*>
7071
*> \param[in] LDC
@@ -93,7 +94,7 @@
9394
*> \param[out] RESID
9495
*> \verbatim
9596
*> RESID is DOUBLE PRECISION
96-
*> RESID = norm( B - U * C ) / ( max(m,n) * norm(B) * EPS ),
97+
*> RESID = norm(B - U * C) / ( max(m,n) * norm(B) * EPS ),
9798
*> \endverbatim
9899
*
99100
* Authors:
@@ -152,7 +153,7 @@ SUBROUTINE DBDT02( M, N, B, LDB, C, LDC, U, LDU, WORK, RESID )
152153
REALMN = DBLE( MAX( M, N ) )
153154
EPS = DLAMCH( 'Precision' )
154155
*
155-
* Compute norm( B - U * C )
156+
* Compute norm(B - U * C)
156157
*
157158
DO 10 J = 1, N
158159
CALL DCOPY( M, B( 1, J ), 1, WORK, 1 )

0 commit comments

Comments
 (0)