LAPACK  3.5.0
LAPACK: Linear Algebra PACKage
zerrls.f File Reference

Go to the source code of this file.

Functions/Subroutines

subroutine zerrls (PATH, NUNIT)
 ZERRLS More...
 

Function/Subroutine Documentation

subroutine zerrls ( character*3  PATH,
integer  NUNIT 
)

ZERRLS

Purpose:
 ZERRLS tests the error exits for the COMPLEX*16 least squares
 driver routines (ZGELS, CGELSS, CGELSX, CGELSY, CGELSD).
Parameters
[in]PATH
          PATH is CHARACTER*3
          The LAPACK path name for the routines to be tested.
[in]NUNIT
          NUNIT is INTEGER
          The unit number for output.
Author
Univ. of Tennessee
Univ. of California Berkeley
Univ. of Colorado Denver
NAG Ltd.
Date
November 2011

Definition at line 57 of file zerrls.f.

57 *
58 * -- LAPACK test routine (version 3.4.0) --
59 * -- LAPACK is a software package provided by Univ. of Tennessee, --
60 * -- Univ. of California Berkeley, Univ. of Colorado Denver and NAG Ltd..--
61 * November 2011
62 *
63 * .. Scalar Arguments ..
64  CHARACTER*3 path
65  INTEGER nunit
66 * ..
67 *
68 * =====================================================================
69 *
70 * .. Parameters ..
71  INTEGER nmax
72  parameter( nmax = 2 )
73 * ..
74 * .. Local Scalars ..
75  CHARACTER*2 c2
76  INTEGER info, irnk
77  DOUBLE PRECISION rcond
78 * ..
79 * .. Local Arrays ..
80  INTEGER ip( nmax )
81  DOUBLE PRECISION rw( nmax ), s( nmax )
82  COMPLEX*16 a( nmax, nmax ), b( nmax, nmax ), w( nmax )
83 * ..
84 * .. External Functions ..
85  LOGICAL lsamen
86  EXTERNAL lsamen
87 * ..
88 * .. External Subroutines ..
89  EXTERNAL alaesm, chkxer, zgels, zgelsd, zgelss, zgelsx,
90  $ zgelsy
91 * ..
92 * .. Scalars in Common ..
93  LOGICAL lerr, ok
94  CHARACTER*32 srnamt
95  INTEGER infot, nout
96 * ..
97 * .. Common blocks ..
98  COMMON / infoc / infot, nout, ok, lerr
99  COMMON / srnamc / srnamt
100 * ..
101 * .. Executable Statements ..
102 *
103  nout = nunit
104  c2 = path( 2: 3 )
105  a( 1, 1 ) = ( 1.0d+0, 0.0d+0 )
106  a( 1, 2 ) = ( 2.0d+0, 0.0d+0 )
107  a( 2, 2 ) = ( 3.0d+0, 0.0d+0 )
108  a( 2, 1 ) = ( 4.0d+0, 0.0d+0 )
109  ok = .true.
110  WRITE( nout, fmt = * )
111 *
112 * Test error exits for the least squares driver routines.
113 *
114  IF( lsamen( 2, c2, 'LS' ) ) THEN
115 *
116 * ZGELS
117 *
118  srnamt = 'ZGELS '
119  infot = 1
120  CALL zgels( '/', 0, 0, 0, a, 1, b, 1, w, 1, info )
121  CALL chkxer( 'ZGELS ', infot, nout, lerr, ok )
122  infot = 2
123  CALL zgels( 'N', -1, 0, 0, a, 1, b, 1, w, 1, info )
124  CALL chkxer( 'ZGELS ', infot, nout, lerr, ok )
125  infot = 3
126  CALL zgels( 'N', 0, -1, 0, a, 1, b, 1, w, 1, info )
127  CALL chkxer( 'ZGELS ', infot, nout, lerr, ok )
128  infot = 4
129  CALL zgels( 'N', 0, 0, -1, a, 1, b, 1, w, 1, info )
130  CALL chkxer( 'ZGELS ', infot, nout, lerr, ok )
131  infot = 6
132  CALL zgels( 'N', 2, 0, 0, a, 1, b, 2, w, 2, info )
133  CALL chkxer( 'ZGELS ', infot, nout, lerr, ok )
134  infot = 8
135  CALL zgels( 'N', 2, 0, 0, a, 2, b, 1, w, 2, info )
136  CALL chkxer( 'ZGELS ', infot, nout, lerr, ok )
137  infot = 10
138  CALL zgels( 'N', 1, 1, 0, a, 1, b, 1, w, 1, info )
139  CALL chkxer( 'ZGELS ', infot, nout, lerr, ok )
140 *
141 * ZGELSS
142 *
143  srnamt = 'ZGELSS'
144  infot = 1
145  CALL zgelss( -1, 0, 0, a, 1, b, 1, s, rcond, irnk, w, 1, rw,
146  $ info )
147  CALL chkxer( 'ZGELSS', infot, nout, lerr, ok )
148  infot = 2
149  CALL zgelss( 0, -1, 0, a, 1, b, 1, s, rcond, irnk, w, 1, rw,
150  $ info )
151  CALL chkxer( 'ZGELSS', infot, nout, lerr, ok )
152  infot = 3
153  CALL zgelss( 0, 0, -1, a, 1, b, 1, s, rcond, irnk, w, 1, rw,
154  $ info )
155  CALL chkxer( 'ZGELSS', infot, nout, lerr, ok )
156  infot = 5
157  CALL zgelss( 2, 0, 0, a, 1, b, 2, s, rcond, irnk, w, 2, rw,
158  $ info )
159  CALL chkxer( 'ZGELSS', infot, nout, lerr, ok )
160  infot = 7
161  CALL zgelss( 2, 0, 0, a, 2, b, 1, s, rcond, irnk, w, 2, rw,
162  $ info )
163  CALL chkxer( 'ZGELSS', infot, nout, lerr, ok )
164 *
165 * ZGELSX
166 *
167  srnamt = 'ZGELSX'
168  infot = 1
169  CALL zgelsx( -1, 0, 0, a, 1, b, 1, ip, rcond, irnk, w, rw,
170  $ info )
171  CALL chkxer( 'ZGELSX', infot, nout, lerr, ok )
172  infot = 2
173  CALL zgelsx( 0, -1, 0, a, 1, b, 1, ip, rcond, irnk, w, rw,
174  $ info )
175  CALL chkxer( 'ZGELSX', infot, nout, lerr, ok )
176  infot = 3
177  CALL zgelsx( 0, 0, -1, a, 1, b, 1, ip, rcond, irnk, w, rw,
178  $ info )
179  CALL chkxer( 'ZGELSX', infot, nout, lerr, ok )
180  infot = 5
181  CALL zgelsx( 2, 0, 0, a, 1, b, 2, ip, rcond, irnk, w, rw,
182  $ info )
183  CALL chkxer( 'ZGELSX', infot, nout, lerr, ok )
184  infot = 7
185  CALL zgelsx( 2, 0, 0, a, 2, b, 1, ip, rcond, irnk, w, rw,
186  $ info )
187  CALL chkxer( 'ZGELSX', infot, nout, lerr, ok )
188 *
189 * ZGELSY
190 *
191  srnamt = 'ZGELSY'
192  infot = 1
193  CALL zgelsy( -1, 0, 0, a, 1, b, 1, ip, rcond, irnk, w, 10, rw,
194  $ info )
195  CALL chkxer( 'ZGELSY', infot, nout, lerr, ok )
196  infot = 2
197  CALL zgelsy( 0, -1, 0, a, 1, b, 1, ip, rcond, irnk, w, 10, rw,
198  $ info )
199  CALL chkxer( 'ZGELSY', infot, nout, lerr, ok )
200  infot = 3
201  CALL zgelsy( 0, 0, -1, a, 1, b, 1, ip, rcond, irnk, w, 10, rw,
202  $ info )
203  CALL chkxer( 'ZGELSY', infot, nout, lerr, ok )
204  infot = 5
205  CALL zgelsy( 2, 0, 0, a, 1, b, 2, ip, rcond, irnk, w, 10, rw,
206  $ info )
207  CALL chkxer( 'ZGELSY', infot, nout, lerr, ok )
208  infot = 7
209  CALL zgelsy( 2, 0, 0, a, 2, b, 1, ip, rcond, irnk, w, 10, rw,
210  $ info )
211  CALL chkxer( 'ZGELSY', infot, nout, lerr, ok )
212  infot = 12
213  CALL zgelsy( 0, 3, 0, a, 1, b, 3, ip, rcond, irnk, w, 1, rw,
214  $ info )
215  CALL chkxer( 'ZGELSY', infot, nout, lerr, ok )
216 *
217 * ZGELSD
218 *
219  srnamt = 'ZGELSD'
220  infot = 1
221  CALL zgelsd( -1, 0, 0, a, 1, b, 1, s, rcond, irnk, w, 10, rw,
222  $ ip, info )
223  CALL chkxer( 'ZGELSD', infot, nout, lerr, ok )
224  infot = 2
225  CALL zgelsd( 0, -1, 0, a, 1, b, 1, s, rcond, irnk, w, 10, rw,
226  $ ip, info )
227  CALL chkxer( 'ZGELSD', infot, nout, lerr, ok )
228  infot = 3
229  CALL zgelsd( 0, 0, -1, a, 1, b, 1, s, rcond, irnk, w, 10, rw,
230  $ ip, info )
231  CALL chkxer( 'ZGELSD', infot, nout, lerr, ok )
232  infot = 5
233  CALL zgelsd( 2, 0, 0, a, 1, b, 2, s, rcond, irnk, w, 10, rw,
234  $ ip, info )
235  CALL chkxer( 'ZGELSD', infot, nout, lerr, ok )
236  infot = 7
237  CALL zgelsd( 2, 0, 0, a, 2, b, 1, s, rcond, irnk, w, 10, rw,
238  $ ip, info )
239  CALL chkxer( 'ZGELSD', infot, nout, lerr, ok )
240  infot = 12
241  CALL zgelsd( 2, 2, 1, a, 2, b, 2, s, rcond, irnk, w, 1, rw, ip,
242  $ info )
243  CALL chkxer( 'ZGELSD', infot, nout, lerr, ok )
244  END IF
245 *
246 * Print a summary line.
247 *
248  CALL alaesm( path, ok, nout )
249 *
250  RETURN
251 *
252 * End of ZERRLS
253 *
subroutine zgelsx(M, N, NRHS, A, LDA, B, LDB, JPVT, RCOND, RANK, WORK, RWORK, INFO)
ZGELSX solves overdetermined or underdetermined systems for GE matrices
Definition: zgelsx.f:186
subroutine zgelsy(M, N, NRHS, A, LDA, B, LDB, JPVT, RCOND, RANK, WORK, LWORK, RWORK, INFO)
ZGELSY solves overdetermined or underdetermined systems for GE matrices
Definition: zgelsy.f:212
subroutine chkxer(SRNAMT, INFOT, NOUT, LERR, OK)
Definition: cblat2.f:3199
subroutine zgelss(M, N, NRHS, A, LDA, B, LDB, S, RCOND, RANK, WORK, LWORK, RWORK, INFO)
ZGELSS solves overdetermined or underdetermined systems for GE matrices
Definition: zgelss.f:180
logical function lsamen(N, CA, CB)
LSAMEN
Definition: lsamen.f:76
subroutine zgelsd(M, N, NRHS, A, LDA, B, LDB, S, RCOND, RANK, WORK, LWORK, RWORK, IWORK, INFO)
ZGELSD computes the minimum-norm solution to a linear least squares problem for GE matrices ...
Definition: zgelsd.f:227
subroutine alaesm(PATH, OK, NOUT)
ALAESM
Definition: alaesm.f:65
subroutine zgels(TRANS, M, N, NRHS, A, LDA, B, LDB, WORK, LWORK, INFO)
ZGELS solves overdetermined or underdetermined systems for GE matrices
Definition: zgels.f:184

Here is the call graph for this function:

Here is the caller graph for this function: