LAPACK  3.6.1
LAPACK: Linear Algebra PACKage
logical function lsamen ( integer  N,
character*( * )  CA,
character*( * )  CB 
)

LSAMEN

Download LSAMEN + dependencies [TGZ] [ZIP] [TXT]

Purpose:
 LSAMEN  tests if the first N letters of CA are the same as the
 first N letters of CB, regardless of case.
 LSAMEN returns .TRUE. if CA and CB are equivalent except for case
 and .FALSE. otherwise.  LSAMEN also returns .FALSE. if LEN( CA )
 or LEN( CB ) is less than N.
Parameters
[in]N
          N is INTEGER
          The number of characters in CA and CB to be compared.
[in]CA
          CA is CHARACTER*(*)
[in]CB
          CB is CHARACTER*(*)
          CA and CB specify two character strings of length at least N.
          Only the first N characters of each string will be accessed.
Author
Univ. of Tennessee
Univ. of California Berkeley
Univ. of Colorado Denver
NAG Ltd.
Date
November 2011

Definition at line 76 of file lsamen.f.

76 *
77 * -- LAPACK auxiliary routine (version 3.4.0) --
78 * -- LAPACK is a software package provided by Univ. of Tennessee, --
79 * -- Univ. of California Berkeley, Univ. of Colorado Denver and NAG Ltd..--
80 * November 2011
81 *
82 * .. Scalar Arguments ..
83  CHARACTER*( * ) ca, cb
84  INTEGER n
85 * ..
86 *
87 * =====================================================================
88 *
89 * .. Local Scalars ..
90  INTEGER i
91 * ..
92 * .. External Functions ..
93  LOGICAL lsame
94  EXTERNAL lsame
95 * ..
96 * .. Intrinsic Functions ..
97  INTRINSIC len
98 * ..
99 * .. Executable Statements ..
100 *
101  lsamen = .false.
102  IF( len( ca ).LT.n .OR. len( cb ).LT.n )
103  $ GO TO 20
104 *
105 * Do for each character in the two strings.
106 *
107  DO 10 i = 1, n
108 *
109 * Test if the characters are equal using LSAME.
110 *
111  IF( .NOT.lsame( ca( i: i ), cb( i: i ) ) )
112  $ GO TO 20
113 *
114  10 CONTINUE
115  lsamen = .true.
116 *
117  20 CONTINUE
118  RETURN
119 *
120 * End of LSAMEN
121 *
logical function lsamen(N, CA, CB)
LSAMEN
Definition: lsamen.f:76
logical function lsame(CA, CB)
LSAME
Definition: lsame.f:55

Here is the caller graph for this function: