PLASMA  2.4.5
PLASMA - Parallel Linear Algebra for Scalable Multi-core Architectures
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups
zerrls.f
Go to the documentation of this file.
1  SUBROUTINE zerrls( PATH, NUNIT )
2 *
3  include 'plasmaf.h'
4 *
5 * -- LAPACK test routine (version 3.1) --
6 * Univ. of Tennessee, Univ. of California Berkeley and NAG Ltd..
7 * November 2006
8 *
9 * .. Scalar Arguments ..
10  CHARACTER*3 path
11  INTEGER nunit
12 * ..
13 *
14 * Purpose
15 * =======
16 *
17 * ZERRLS tests the error exits for the COMPLEX*16 least squares
18 * driver routines (ZGELS, ZGELSS, CGELSX, CGELSY, CGELSD).
19 *
20 * Arguments
21 * =========
22 *
23 * PATH (input) CHARACTER*3
24 * The LAPACK path name for the routines to be tested.
25 *
26 * NUNIT (input) INTEGER
27 * The unit number for output.
28 *
29 * =====================================================================
30 *
31 * .. Parameters ..
32  INTEGER nmax
33  parameter( nmax = 2 )
34 * ..
35 * .. Local Scalars ..
36  CHARACTER*2 c2
37  INTEGER info, irnk
38  DOUBLE PRECISION rcond
39  INTEGER ht( 2 )
40 * ..
41 * .. Local Arrays ..
42  INTEGER ip( nmax )
43  DOUBLE PRECISION rw( nmax ), s( nmax )
44  COMPLEX*16 a( nmax, nmax ), b( nmax, nmax ), w( nmax )
45 * ..
46 * .. External Functions ..
47  LOGICAL lsamen
48  EXTERNAL lsamen
49 * ..
50 * .. External Subroutines ..
51  EXTERNAL alaesm, chkxer, zgels, zgelsd, zgelss, zgelsx,
52  $ zgelsy
53 * ..
54 * .. Scalars in Common ..
55  LOGICAL lerr, ok
56  CHARACTER*32 srnamt
57  INTEGER infot, nout
58 * ..
59 * .. Common blocks ..
60  common / infoc / infot, nout, ok, lerr
61  common / srnamc / srnamt
62 * ..
63 * .. Executable Statements ..
64 *
65  nout = nunit
66  c2 = path( 2: 3 )
67  a( 1, 1 ) = ( 1.0d+0, 0.0d+0 )
68  a( 1, 2 ) = ( 2.0d+0, 0.0d+0 )
69  a( 2, 2 ) = ( 3.0d+0, 0.0d+0 )
70  a( 2, 1 ) = ( 4.0d+0, 0.0d+0 )
71  ok = .true.
72  WRITE( nout, fmt = * )
73 *
74 * Disable PLASMA warnings/errors
75 *
76  CALL plasma_disable( plasma_warnings, info )
77  CALL plasma_disable( plasma_errors, info )
78 *
79 * Test error exits for the least squares driver routines.
80 *
81  IF( lsamen( 2, c2, 'LS' ) ) THEN
82 *
83 * ZGELS
84 *
85  CALL plasma_alloc_workspace_zgels( 2, 2, ht, info )
86 *
87  srnamt = 'ZGELS '
88  infot = 103
89  CALL plasma_zgels( '/', 0, 0, 0, a, 1, ht, b, 1, info )
90  CALL chkxer( 'ZGELS ', infot, nout, info, ok )
91  infot = 2
92  CALL plasma_zgels( plasmanotrans, -1, 0, 0, a, 1, ht,
93  $ b, 1, info )
94  CALL chkxer( 'ZGELS ', infot, nout, info, ok )
95  infot = 3
96  CALL plasma_zgels( plasmanotrans, 0, -1, 0, a, 1, ht,
97  $ b, 1, info )
98  CALL chkxer( 'ZGELS ', infot, nout, info, ok )
99  infot = 4
100  CALL plasma_zgels( plasmanotrans, 0, 0, -1, a, 1, ht,
101  $ b, 1, info )
102  CALL chkxer( 'ZGELS ', infot, nout, info, ok )
103  infot = 6
104  CALL plasma_zgels( plasmanotrans, 2, 0, 0, a, 1, ht,
105  $ b, 2, info )
106  CALL chkxer( 'ZGELS ', infot, nout, info, ok )
107  infot = 9
108  CALL plasma_zgels( plasmanotrans, 2, 0, 0, a, 2, ht,
109  $ b, 1, info )
110  CALL chkxer( 'ZGELS ', infot, nout, info, ok )
111 *
112  CALL plasma_dealloc_handle( ht, info )
113  END IF
114 *
115 * Print a summary line.
116 *
117  CALL alaesm( path, ok, nout )
118 *
119 * Enable PLASMA warnings/errors
120 *
121  CALL plasma_enable( plasma_warnings, info )
122  CALL plasma_enable( plasma_errors, info )
123 *
124  return
125 *
126 * End of ZERRLS
127 *
128  END