167 SUBROUTINE zcklse( 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
178 DOUBLE PRECISION thresh
181 INTEGER iseed( 4 ), mval( * ), nval( * ), pval( * )
182 DOUBLE PRECISION rwork( * )
183 COMPLEX*16 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 DOUBLE PRECISION anorm, bnorm, cndnma, cndnmb
205 LOGICAL dotype( ntypes )
206 DOUBLE PRECISION 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
dlatb9( path, imat, m, p, n, type, kla, kua, klb, kub,
265 $ anorm, bnorm, modea, modeb, cndnma, cndnmb,
268 CALL
zlatms( 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
zlatms( 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
zlarhs(
'ZGE',
'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
zlarhs(
'ZGE',
'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
zlsets( 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(
' ZLATMS in ZCKLSE 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)' )