167 SUBROUTINE ccklse( NN, MVAL, PVAL, NVAL, NMATS, ISEED, THRESH,
168 $ nmax, a, af, b, bf, x, work, rwork, nin, nout,
177 INTEGER info, nin, nmats, nmax, nn, nout
181 INTEGER iseed( 4 ), mval( * ), nval( * ), pval( * )
183 COMPLEX a( * ), af( * ), b( * ), bf( * ), work( * ),
191 parameter( ntests = 7 )
193 parameter( ntypes = 8 )
197 CHARACTER dista, distb, type
199 INTEGER i, iinfo, ik, imat, kla, klb, kua, kub, lda,
200 $ ldb, lwork, m, modea, modeb, n, nfail, nrun,
202 REAL anorm, bnorm, cndnma, cndnmb
205 LOGICAL dotype( ntypes )
206 REAL result( ntests )
224 CALL
alareq( path, nmats, dotype, ntypes, nin, nout )
235 IF( p.GT.n .OR. n.GT.m+p )
THEN
237 WRITE( nout, fmt = * )
240 WRITE( nout, fmt = 9997 )m, p, n
251 IF( p.GT.n .OR. n.GT.m+p )
254 DO 30 imat = 1, ntypes
258 IF( .NOT.dotype( imat ) )
264 CALL
slatb9( path, imat, m, p, n, type, kla, kua, klb, kub,
265 $ anorm, bnorm, modea, modeb, cndnma, cndnmb,
268 CALL
clatms( m, n, dista, iseed, type, rwork, modea, cndnma,
269 $ anorm, kla, kua,
'No packing', a, lda, work,
271 IF( iinfo.NE.0 )
THEN
272 WRITE( nout, fmt = 9999 )iinfo
277 CALL
clatms( p, n, distb, iseed, type, rwork, modeb, cndnmb,
278 $ bnorm, klb, kub,
'No packing', b, ldb, work,
280 IF( iinfo.NE.0 )
THEN
281 WRITE( nout, fmt = 9999 )iinfo
288 CALL
clarhs(
'CGE',
'New solution',
'Upper',
'N', m, n,
289 $ max( m-1, 0 ), max( n-1, 0 ), 1, a, lda,
290 $ x( 4*nmax+1 ), max( n, 1 ), x, max( m, 1 ),
293 CALL
clarhs(
'CGE',
'Computed',
'Upper',
'N', p, n,
294 $ max( p-1, 0 ), max( n-1, 0 ), 1, b, ldb,
295 $ x( 4*nmax+1 ), max( n, 1 ), x( 2*nmax+1 ),
296 $ max( p, 1 ), iseed, iinfo )
300 CALL
clsets( m, p, n, a, af, lda, b, bf, ldb, x,
301 $ x( nmax+1 ), x( 2*nmax+1 ), x( 3*nmax+1 ),
302 $ x( 4*nmax+1 ), work, lwork, rwork,
309 IF( result( i ).GE.thresh )
THEN
310 IF( nfail.EQ.0 .AND. firstt )
THEN
314 WRITE( nout, fmt = 9998 )m, p, n, imat, i,
326 CALL
alasum( path, nout, nfail, nrun, 0 )
328 9999 format(
' CLATMS in CCKLSE INFO = ', i5 )
329 9998 format(
' M=', i4,
' P=', i4,
', N=', i4,
', type ', i2,
330 $
', test ', i2,
', ratio=', g13.6 )
331 9997 format(
' *** Invalid input for LSE: M = ', i6,
', P = ', i6,
332 $
', N = ', i6,
';', /
' must satisfy P <= N <= P+M ',
333 $
'(this set of values will be skipped)' )