1LSAMETST(1) LAPACK test routine (version 3.1) LSAMETST(1)
2
3
4
7 PROGRAM TEST1
8
9 INTEGER I1, I2
10
11 LOGICAL LSAME
12
13 EXTERNAL LSAME
14
15 INTRINSIC ICHAR
16
17 I1 = ICHAR( 'A' )
18
19 I2 = ICHAR( 'a' )
20
21 IF( I2-I1.EQ.32 ) THEN
22
23 WRITE( *, * ) ' ASCII character set'
24
25 ELSE
26
27 WRITE( *, * ) ' Non-ASCII character set, IOFF should be ',I2-I1
28
29 END IF
30
31 IF( WRITE( *, 9999 )'A', 'A'
32
33 IF( WRITE( *, 9999 )'A', 'a'
34
35 IF( WRITE( *, 9999 )'a', 'A'
36
37 IF( WRITE( *, 9999 )'a', 'a'
38
39 IF( LSAME( 'A', 'B' ) ) WRITE( *, 9998 )'A', 'B'
40
41 IF( LSAME( 'A', 'b' ) ) WRITE( *, 9998 )'A', 'b'
42
43 IF( LSAME( 'a', 'B' ) ) WRITE( *, 9998 )'a', 'B'
44
45 IF( LSAME( 'a', 'b' ) ) WRITE( *, 9998 )'a', 'b'
46
47 IF( LSAME( 'O', '/' ) ) WRITE( *, 9998 )'O', '/'
48
49 IF( LSAME( '/', 'O' ) ) WRITE( *, 9998 )'/', 'O'
50
51 IF( LSAME( 'o', '/' ) ) WRITE( *, 9998 )'o', '/'
52
53 IF( LSAME( '/', 'o' ) ) WRITE( *, 9998 )'/', 'o'
54
55 WRITE( *, * )' Tests completed'
56
57 9999 FORMAT( ' *** Error: LSAME( ', A1, ', ', A1, ') is
58 .FALSE.' )
59
60 9998 FORMAT( ' *** Error: LSAME( ', A1, ', ', A1, ') is
61 .TRUE.' )
62
63 END
64
66 LAPACK test routine (version 3.1)November 2006 LSAMETST(1)