1      MODULE F77_LAPACK
2!
3!  -- LAPACK95 interface driver routine (version 3.0) --
4!     UNI-C, Denmark; Univ. of Tennessee, USA; NAG Ltd., UK
5!     September, 2000
6!
7
8      INTERFACE LA_LANGB
9
10       FUNCTION DLANGB( NORM, N, KL, KU, AB, LDAB, WORK )
11         USE LA_PRECISION, ONLY: WP => DP
12         REAL(WP) :: DLANGB
13         CHARACTER(LEN=1), INTENT(IN) :: NORM
14         INTEGER, INTENT(IN) :: LDAB, N, KL, KU
15         REAL(WP), INTENT(IN) :: AB( LDAB, * )
16         REAL(WP), INTENT(OUT) :: WORK( * )
17      END FUNCTION DLANGB
18
19       END INTERFACE
20
21       INTERFACE LA_TGSEN
22
23      SUBROUTINE DTGSEN( IJOB, WANTQ, WANTZ, SELECT, N, A, LDA, B, LDB, &
24     &                   ALPHAR, ALPHAI, BETA, Q, LDQ, Z, LDZ, M, PL,   &
25     &                   PR, DIF, WORK, LWORK, IWORK, LIWORK, INFO )
26      USE LA_PRECISION, ONLY: WP => DP
27      LOGICAL, INTENT(IN) :: WANTQ, WANTZ
28      INTEGER, INTENT(IN) :: IJOB, LDA, LDB, LDQ, LDZ, LIWORK, LWORK, N
29      INTEGER, INTENT(OUT) :: INFO, M, IWORK(LIWORK)
30      REAL(WP), INTENT(OUT) :: PL, PR
31      LOGICAL, INTENT(IN) :: SELECT(*)
32      REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*), Q(LDQ,*), Z(LDZ,*)
33      REAL(WP), INTENT(OUT) :: ALPHAI(*), ALPHAR(*), BETA(*), DIF(2),   &
34     &                         WORK(LWORK)
35      END SUBROUTINE DTGSEN
36
37
38       END INTERFACE
39
40
41       INTERFACE LA_TGSNA
42
43      SUBROUTINE DTGSNA( JOB, HOWMNY, SELECT, N, A, LDA, B, LDB, VL,    &
44     &                   LDVL, VR, LDVR, S, DIF, MM, M, WORK, LWORK,    &
45     &                   IWORK, INFO )
46      USE LA_PRECISION, ONLY: WP => DP
47      CHARACTER(LEN=1), INTENT(IN) :: HOWMNY, JOB
48      INTEGER, INTENT(IN) :: LDA, LDB, LDVL, LDVR, LWORK, MM, N
49      INTEGER, INTENT(OUT) :: INFO, M, IWORK(*)
50      LOGICAL, INTENT(IN) :: SELECT(*)
51      REAL(WP), INTENT(OUT) :: DIF(*), S(*)
52      REAL(WP), INTENT(IN) :: A(LDA,*), B(LDB,*), VL(LDVL,*),           &
53     &                        VR(LDVR,*)
54      REAL(WP), INTENT(OUT) :: WORK(LWORK)
55      END SUBROUTINE DTGSNA
56
57       END INTERFACE
58
59       INTERFACE LA_TGSYL
60
61      SUBROUTINE DTGSYL( TRANS, IJOB, M, N, A, LDA, B, LDB, C, LDC, D,  &
62     &                   LDD, E, LDE, F, LDF, SCALE, DIF, WORK, LWORK,  &
63     &                   IWORK, INFO )
64      USE LA_PRECISION, ONLY: WP => DP
65      CHARACTER(LEN=1), INTENT(IN) :: TRANS
66      INTEGER, INTENT(IN) :: IJOB, LDA, LDB, LDC, LDD, LDE, LDF, LWORK, &
67     &                       M, N
68      INTEGER, INTENT(OUT) :: INFO, IWORK(*)
69      REAL(WP), INTENT(OUT) :: DIF, SCALE
70      REAL(WP), INTENT(IN) :: A(LDA,*), B(LDB,*), D(LDD,*), E(LDF,*)
71      REAL(WP), INTENT(INOUT) :: C(LDC,*), F(LDF,*)
72      REAL(WP), INTENT(OUT) :: WORK(LWORK)
73      END SUBROUTINE DTGSYL
74
75       END INTERFACE
76
77       INTERFACE LA_TGEXC
78
79         SUBROUTINE DTGEXC( WANTQ, WANTZ, N, A, LDA, B, LDB, Q, LDQ, Z, &
80     &                      LDZ, IFST, ILST, WORK, LWORK, INFO )
81      USE LA_PRECISION, ONLY: WP => DP
82      LOGICAL, INTENT(IN) :: WANTQ, WANTZ
83      INTEGER, INTENT(IN) :: LDA, LDB, LDQ, LDZ, LWORK, N
84      INTEGER, INTENT(INOUT) :: IFST, ILST
85      INTEGER, INTENT(OUT) :: INFO
86      REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*), Q(LDQ,*), Z(LDZ,*)
87      REAL(WP), INTENT(OUT) :: WORK(LWORK)
88      END SUBROUTINE DTGEXC
89
90
91       END INTERFACE
92
93       INTERFACE LA_BDSDC
94
95         SUBROUTINE DBDSDC( UPLO, COMPQ, N, D, E, U, LDU, VT, LDVT, Q,  &
96     &                      IQ, WORK, IWORK, INFO )
97      USE LA_PRECISION, ONLY: WP => DP
98      CHARACTER(LEN=1), INTENT(IN) :: COMPQ, UPLO
99      INTEGER, INTENT(IN) :: LDU, LDVT, N
100      INTEGER, INTENT(OUT) :: INFO, IQ( * ), IWORK( * )
101      REAL(WP), INTENT(INOUT) :: D( * ), E( * )
102      REAL(WP), INTENT(OUT) :: Q(*), U(LDU,*), VT(LDVT,*), WORK(*)
103      END SUBROUTINE DBDSDC
104
105       END INTERFACE
106
107       INTERFACE LA_STEGR
108
109         SUBROUTINE DSTEGR( JOBZ, RANGE, N, D, E, VL, VU, IL, IU,       &
110     &                      ABSTOL, M, W, Z, LDZ, ISUPPZ, WORK, LWORK,  &
111     &                      IWORK, LIWORK, INFO )
112      USE LA_PRECISION, ONLY: WP => DP
113      CHARACTER(LEN=1), INTENT(IN) :: JOBZ, RANGE
114      INTEGER, INTENT(IN) :: IL, IU, LDZ, LIWORK, LWORK, N
115      INTEGER, INTENT(OUT) :: INFO, M
116      INTEGER, INTENT(OUT) :: ISUPPZ( * ), IWORK(LIWORK)
117      REAL(WP), INTENT(IN) :: ABSTOL, VL, VU
118      REAL(WP), INTENT(INOUT) :: D( * ), E( * )
119      REAL(WP), INTENT(IN) :: W( * )
120      REAL(WP), INTENT(OUT) :: WORK(LWORK)
121      REAL(WP), INTENT(OUT) :: Z( LDZ, * )
122      END SUBROUTINE DSTEGR
123
124       END INTERFACE
125
126       INTERFACE LA_ORMRZ
127
128         SUBROUTINE DORMRZ( SIDE, TRANS, M, N, K, L, A, LDA, TAU, C,    &
129     &                      LDC, WORK, LWORK, INFO )
130      USE LA_PRECISION, ONLY: WP => DP
131      CHARACTER(LEN=1), INTENT(IN) :: SIDE, TRANS
132      INTEGER, INTENT(IN) :: K, L, LDA, LDC, LWORK, M, N
133      INTEGER, INTENT(OUT) :: INFO
134      REAL(WP), INTENT(IN) :: A( LDA, * ), TAU( * )
135      REAL(WP), INTENT(INOUT) :: C( LDC, * )
136      REAL(WP), INTENT(OUT) :: WORK(LWORK)
137      END SUBROUTINE DORMRZ
138
139       END INTERFACE
140
141
142
143       INTERFACE LA_TZRZF
144
145         SUBROUTINE DTZRZF( M, N, A, LDA, TAU, WORK, LWORK, INFO )
146      USE LA_PRECISION, ONLY: WP => DP
147      INTEGER, INTENT(IN) :: LDA, LWORK, M, N
148      INTEGER, INTENT(OUT) :: INFO
149      REAL(WP), INTENT(INOUT) :: A( LDA, * )
150      REAL(WP), INTENT(OUT) :: TAU( * ), WORK(LWORK)
151      END SUBROUTINE DTZRZF
152
153       END INTERFACE
154
155       INTERFACE LA_GEQP3
156
157         SUBROUTINE DGEQP3( M, N, A, LDA, JPVT, TAU, WORK, LWORK,       &
158     &                      INFO )
159      USE LA_PRECISION, ONLY: WP => DP
160      INTEGER, INTENT(IN) :: LDA, LWORK, M, N
161      INTEGER, INTENT(OUT) :: INFO
162      INTEGER, INTENT(INOUT) :: JPVT( * )
163      REAL(WP), INTENT(INOUT) :: A( LDA, * )
164      REAL(WP), INTENT(OUT) :: TAU( * ), WORK(LWORK)
165      END SUBROUTINE DGEQP3
166
167
168       END INTERFACE
169
170       INTERFACE LA_GESDD
171
172
173         SUBROUTINE DGESDD( JOBZ, M, N, A, LDA, S, U, LDU, VT, LDVT,    &
174     &                      WORK, LWORK, IWORK, INFO )
175      USE LA_PRECISION, ONLY: WP => DP
176      CHARACTER(LEN=1), INTENT(IN) :: JOBZ
177      INTEGER, INTENT(IN) :: M, N, LDA, LDU, LDVT, LWORK
178      INTEGER, INTENT(OUT) :: INFO
179      REAL(WP), INTENT(OUT) :: S(*)
180      REAL(WP), INTENT(INOUT) :: A(LDA,*)
181      REAL(WP), INTENT(OUT) :: U(LDU,*), VT(LDVT,*), WORK(*)
182      INTEGER :: IWORK(*)
183      END SUBROUTINE DGESDD
184
185
186      END INTERFACE
187
188
189      INTERFACE LA_GGRQF
190
191      SUBROUTINE DGGRQF( M, P, N, A, LDA, TAUA, B, LDB, TAUB, WORK,     &
192     &                   LWORK, INFO )
193         USE LA_PRECISION, ONLY: WP => DP
194         INTEGER, INTENT(IN) :: LDA, LDB, LWORK, M, N, P
195         INTEGER, INTENT(OUT) :: INFO
196         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
197         REAL(WP), INTENT(OUT) :: TAUA(*), TAUB(*), WORK(*)
198      END SUBROUTINE DGGRQF
199
200      END INTERFACE
201
202      INTERFACE LA_GGQRF
203
204      SUBROUTINE DGGQRF( N, M, P, A, LDA, TAUA, B, LDB, TAUB, WORK,     &
205     &                   LWORK, INFO )
206         USE LA_PRECISION, ONLY: WP => DP
207         INTEGER, INTENT(IN) :: LDA, LDB, LWORK, M, N, P
208         INTEGER, INTENT(OUT) :: INFO
209         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
210         REAL(WP), INTENT(OUT) :: TAUA(*), TAUB(*), WORK(*)
211      END SUBROUTINE DGGQRF
212
213      END INTERFACE
214
215      INTERFACE LA_DISNA
216
217      SUBROUTINE DDISNA( JOB, M, N, D, SEP, INFO )
218         USE LA_PRECISION, ONLY: WP => DP
219         CHARACTER(LEN=1), INTENT(IN) :: JOB
220         INTEGER, INTENT(IN) :: M, N
221         INTEGER, INTENT(OUT) :: INFO
222         REAL(WP), INTENT(IN) :: D(*)
223         REAL(WP), INTENT(OUT) :: SEP(*)
224      END SUBROUTINE DDISNA
225
226      END INTERFACE
227
228      INTERFACE LA_TGSJA
229
230      SUBROUTINE DTGSJA( JOBU, JOBV, JOBQ, M, P, N, K, L, A, LDA, B,    &
231     &                   LDB, TOLA, TOLB, ALPHA, BETA, U, LDU, V, LDV,  &
232     &                   Q, LDQ, WORK, NCYCLE, INFO )
233         USE LA_PRECISION, ONLY: WP => DP
234         CHARACTER(LEN=1), INTENT(IN) :: JOBQ, JOBU, JOBV
235         INTEGER, INTENT(IN) :: K, L, LDA, LDB, LDQ, LDU, LDV, M, N,    &
236     &                          NCYCLE, P
237         INTEGER, INTENT(OUT) :: INFO
238         REAL(WP), INTENT(IN) :: TOLA, TOLB
239         REAL(WP), INTENT(OUT) :: ALPHA(*), BETA(*)
240         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*), Q(LDQ,*),       &
241     &                              U(LDU,*), V(LDV,*)
242         REAL(WP), INTENT(OUT) :: WORK(*)
243      END SUBROUTINE DTGSJA
244
245      END INTERFACE
246
247      INTERFACE LA_GGSVP
248
249      SUBROUTINE DGGSVP( JOBU, JOBV, JOBQ, M, P, N, A, LDA, B, LDB,     &
250     &                   TOLA, TOLB, K, L, U, LDU, V, LDV, Q, LDQ,      &
251     &                   IWORK, TAU, WORK, INFO )
252         USE LA_PRECISION, ONLY: WP => DP
253         CHARACTER(LEN=1), INTENT(IN) :: JOBQ, JOBU, JOBV
254         INTEGER, INTENT(IN) :: LDA, LDB, LDQ, LDU, LDV, M, N, P
255         INTEGER, INTENT(OUT) :: INFO, K, L, IWORK(*)
256         REAL(WP), INTENT(IN) :: TOLA, TOLB
257         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
258         REAL(WP), INTENT(OUT) :: Q(LDQ,*), TAU(*), U(LDU,*), V(LDV,*), &
259     &                            WORK(*)
260      END SUBROUTINE DGGSVP
261
262      END INTERFACE
263
264      INTERFACE LA_TGEVC
265
266      SUBROUTINE DTGEVC( SIDE, HOWMNY, SELECT, N, A, LDA, B, LDB, VL,   &
267     &                   LDVL, VR, LDVR, MM, M, WORK, INFO )
268         USE LA_PRECISION, ONLY: WP => DP
269         CHARACTER(LEN=1), INTENT(IN) :: HOWMNY, SIDE
270         INTEGER, INTENT(IN) :: LDA, LDB, LDVL, LDVR, MM, N
271         INTEGER, INTENT(OUT) :: INFO, M
272         LOGICAL, INTENT(IN) :: SELECT(*)
273         REAL(WP), INTENT(IN) :: A(LDA,*), B(LDB,*)
274         REAL(WP), INTENT(INOUT) :: VL(LDVL,*), VR(LDVR,*)
275         REAL(WP), INTENT(OUT) :: WORK(*)
276      END SUBROUTINE DTGEVC
277
278      END INTERFACE
279
280      INTERFACE LA_HGEQZ
281
282      SUBROUTINE DHGEQZ( JOB, COMPQ, COMPZ, N, ILO, IHI, A, LDA, B, LDB,&
283     &                   ALPHAR, ALPHAI, BETA, Q, LDQ, Z, LDZ, WORK,    &
284     &                   LWORK, INFO )
285         USE LA_PRECISION, ONLY: WP => DP
286         CHARACTER(LEN=1), INTENT(IN) :: COMPQ, COMPZ, JOB
287         INTEGER, INTENT(IN) :: IHI, ILO, LDA, LDB, LDQ, LDZ, LWORK, N
288         INTEGER, INTENT(OUT) :: INFO
289         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*), Q(LDQ,*),       &
290     &                              Z(LDZ,*)
291         REAL(WP), INTENT(OUT) :: ALPHAR(*), ALPHAI(*), BETA(*), WORK(LWORK)
292      END SUBROUTINE DHGEQZ
293
294      END INTERFACE
295
296      INTERFACE LA_GGBAK
297
298      SUBROUTINE DGGBAK( JOB, SIDE, N, ILO, IHI, LSCALE, RSCALE, M, V,  &
299     &                   LDV, INFO )
300         USE LA_PRECISION, ONLY: WP => DP
301         CHARACTER(LEN=1), INTENT(IN) :: JOB, SIDE
302         INTEGER, INTENT(IN) :: IHI, ILO, LDV, M, N
303         INTEGER, INTENT(OUT) :: INFO
304         REAL(WP), INTENT(IN) :: LSCALE(*), RSCALE(*)
305         REAL(WP), INTENT(INOUT) :: V(LDV,*)
306      END SUBROUTINE DGGBAK
307
308      END INTERFACE
309
310      INTERFACE LA_GGBAL
311
312      SUBROUTINE DGGBAL( JOB, N, A, LDA, B, LDB, ILO, IHI, LSCALE,      &
313     &                   RSCALE, WORK, INFO )
314         USE LA_PRECISION, ONLY: WP => DP
315         CHARACTER(LEN=1), INTENT(IN) :: JOB
316         INTEGER, INTENT(IN) :: LDA, LDB, N
317         INTEGER, INTENT(OUT) :: IHI, ILO, INFO
318         REAL(WP), INTENT(OUT) :: LSCALE(*), RSCALE(*), WORK(*)
319         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
320      END SUBROUTINE DGGBAL
321
322      END INTERFACE
323
324      INTERFACE LA_GGHRD
325
326      SUBROUTINE DGGHRD( COMPQ, COMPZ, N, ILO, IHI, A, LDA, B, LDB, Q,  &
327     &                   LDQ, Z, LDZ, INFO )
328         USE LA_PRECISION, ONLY: WP => DP
329         CHARACTER(LEN=1), INTENT(IN) :: COMPQ, COMPZ
330         INTEGER, INTENT(IN) :: IHI, ILO, LDA, LDB, LDQ, LDZ, N
331         INTEGER, INTENT(OUT) :: INFO
332         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*), Q(LDQ,*),       &
333     &                              Z(LDZ,*)
334      END SUBROUTINE DGGHRD
335
336      END INTERFACE
337
338      INTERFACE LA_PBSTF
339
340      SUBROUTINE DPBSTF( UPLO, N, KD, AB, LDAB, INFO )
341         USE LA_PRECISION, ONLY: WP => DP
342         CHARACTER(LEN=1), INTENT(IN) ::UPLO
343         INTEGER, INTENT(IN) :: KD, LDAB, N
344         INTEGER, INTENT(OUT) :: INFO
345         REAL(WP), INTENT(INOUT) :: AB( LDAB, * )
346      END SUBROUTINE DPBSTF
347
348      END INTERFACE
349
350      INTERFACE LA_SBGST
351
352      SUBROUTINE DSBGST( VECT, UPLO, N, KA, KB, AB, LDAB, BB, LDBB, X,  &
353     &                   LDX, WORK, INFO )
354         USE LA_PRECISION, ONLY: WP => DP
355         CHARACTER(LEN=1), INTENT(IN) :: UPLO, VECT
356         INTEGER, INTENT(IN) :: KA, KB, LDAB, LDBB, LDX, N
357         INTEGER, INTENT(OUT) :: INFO
358         REAL(WP), INTENT(IN) :: BB(LDBB,*)
359         REAL(WP), INTENT(INOUT) :: AB(LDAB,*)
360         REAL(WP), INTENT(OUT) :: WORK(*), X(LDX,*)
361      END SUBROUTINE DSBGST
362
363      END INTERFACE
364
365
366      INTERFACE LA_SPGST
367
368      SUBROUTINE DSPGST( ITYPE, UPLO, N, AP, BP, INFO )
369         USE LA_PRECISION, ONLY: WP => DP
370         CHARACTER(LEN=1), INTENT(IN) :: UPLO
371         INTEGER, INTENT(IN) :: ITYPE, N
372         INTEGER, INTENT(OUT) :: INFO
373         REAL(WP), INTENT(IN) :: BP(*)
374         REAL(WP), INTENT(INOUT) :: AP(*)
375      END SUBROUTINE DSPGST
376
377      END INTERFACE
378
379
380      INTERFACE LA_BDSQR
381
382      SUBROUTINE DBDSQR( UPLO, N, NCVT, NRU, NCC, D, E, VT, LDVT, U,    &
383     &                   LDU, C, LDC, RWORK, INFO )
384         USE LA_PRECISION, ONLY: WP => DP
385         CHARACTER(LEN=1), INTENT(IN) :: UPLO
386         INTEGER, INTENT(IN) :: LDC, LDU, LDVT, N, NCC, NCVT, NRU
387         INTEGER, INTENT(OUT) :: INFO
388         REAL, INTENT(INOUT) :: D(*), E(*)
389         REAL, INTENT(OUT) :: RWORK(*)
390         REAL(WP), INTENT(INOUT) :: C(LDC,*), U(LDU,*), VT(LDVT,*)
391      END SUBROUTINE DBDSQR
392
393      END INTERFACE
394
395      INTERFACE LA_ORMBR
396
397      SUBROUTINE DORMBR( VECT, SIDE, TRANS, M, N, K, A, LDA, TAU, C,    &
398     &                   LDC, WORK, LWORK, INFO )
399         USE LA_PRECISION, ONLY: WP => DP
400         CHARACTER(LEN=1), INTENT(IN) :: SIDE, TRANS, VECT
401         INTEGER, INTENT(IN) :: K, LDA, LDC, LWORK, M, N
402         INTEGER, INTENT(OUT) :: INFO
403         REAL(WP), INTENT(IN) :: A(LDA,*), TAU(*)
404         REAL(WP), INTENT(INOUT) :: C(LDA,*)
405         REAL(WP), INTENT(OUT) :: WORK(LWORK)
406      END SUBROUTINE DORMBR
407
408      END INTERFACE
409
410
411      INTERFACE LA_ORGBR
412
413      SUBROUTINE DORGBR( VECT, M, N, K, A, LDA, TAU, WORK, LWORK,       &
414     &                   INFO )
415         USE LA_PRECISION, ONLY: WP => DP
416         CHARACTER(LEN=1), INTENT(IN) :: VECT
417         INTEGER, INTENT(IN) :: K, LDA, LWORK, M, N
418         INTEGER, INTENT(OUT) :: INFO
419         REAL(WP), INTENT(IN) :: TAU(*)
420         REAL(WP), INTENT(INOUT) :: A(LDA,*)
421         REAL(WP), INTENT(OUT) :: WORK(LWORK)
422      END SUBROUTINE DORGBR
423
424      END INTERFACE
425
426
427      INTERFACE LA_GBBRD
428
429      SUBROUTINE DGBBRD( VECT, M, N, NCC, KL, KU, AB, LDAB, D, E, Q,    &
430     &                   LDQ, PT, LDPT, C, LDC, WORK, INFO )
431         USE LA_PRECISION, ONLY: WP => DP
432         CHARACTER(LEN=1), INTENT(IN) :: VECT
433         INTEGER, INTENT(IN) :: KL, KU, LDAB, LDC, LDPT, LDQ, M, N, NCC
434         INTEGER, INTENT(OUT) :: INFO
435         REAL, INTENT(OUT) :: D(*), E(*)
436         REAL(WP), INTENT(INOUT) :: AB(LDAB,*), C(LDC,*)
437         REAL(WP), INTENT(OUT) :: PT(LDPT,*), Q(LDQ,*), WORK(*)
438      END SUBROUTINE DGBBRD
439
440      END INTERFACE
441
442      INTERFACE LA_GEBRD
443
444      SUBROUTINE DGEBRD( M, N, A, LDA, D, E, TAUQ, TAUP, WORK, LWORK,   &
445     &                   INFO )
446         USE LA_PRECISION, ONLY: WP => DP
447         INTEGER, INTENT(IN) :: LDA, LWORK, M, N
448         INTEGER, INTENT(OUT) :: INFO
449         REAL(WP), INTENT(OUT) :: D(*), E(*)
450         REAL(WP), INTENT(INOUT) :: A(LDA,*)
451         REAL(WP), INTENT(OUT) :: TAUP(*), TAUQ(*), WORK(LWORK)
452      END SUBROUTINE DGEBRD
453
454      END INTERFACE
455
456      INTERFACE LA_TRSEN
457
458      SUBROUTINE DTRSEN( JOB, COMPQ, SELECT, N, T, LDT, Q, LDQ, WR, WI, &
459     &                   M, S, SEP, WORK, LWORK, IWORK, LIWORK, INFO )
460         USE LA_PRECISION, ONLY: WP => DP
461         CHARACTER(LEN=1), INTENT(IN) :: COMPQ, JOB
462         INTEGER, INTENT(IN) :: LDQ, LDT, LWORK, N, LIWORK
463         INTEGER, INTENT(OUT) :: INFO, M, IWORK(LIWORK)
464         REAL(WP), INTENT(OUT) :: S, SEP
465         LOGICAL, INTENT(IN) :: SELECT(*)
466         REAL(WP), INTENT(INOUT) :: Q(LDQ,*), T(LDT,*)
467         REAL(WP), INTENT(IN) :: WR(*), WI(*)
468         REAL(WP), INTENT(OUT) :: WORK(LWORK)
469      END SUBROUTINE DTRSEN
470
471      END INTERFACE
472
473      INTERFACE LA_TRSNA
474
475      SUBROUTINE DTRSNA( JOB, HOWMNY, SELECT, N, T, LDT, VL, LDVL, VR,  &
476     &                   LDVR, S, SEP, MM, M, WORK, LDWORK, IWORK,      &
477     &                   INFO )
478         USE LA_PRECISION, ONLY: WP => DP
479         CHARACTER(LEN=1), INTENT(IN) :: HOWMNY, JOB
480         INTEGER, INTENT(IN) :: LDT, LDVL, LDVR, LDWORK, MM, N
481         INTEGER, INTENT(OUT) :: INFO, M, IWORK(*)
482         LOGICAL, INTENT(IN) :: SELECT(*)
483         REAL(WP), INTENT(OUT) :: S(*), SEP(*)
484         REAL(WP), INTENT(IN) :: T(LDT,*), VL(LDVL,*), VR(LDVR,*)
485         REAL(WP), INTENT(OUT) :: WORK(LDWORK,*)
486      END SUBROUTINE DTRSNA
487
488      END INTERFACE
489
490      INTERFACE LA_TRSYL
491
492      SUBROUTINE DTRSYL( TRANA, TRANB, ISGN, M, N, A, LDA, B, LDB, C,   &
493     &                   LDC, SCALE, INFO )
494         USE LA_PRECISION, ONLY: WP => DP
495         CHARACTER(LEN=1), INTENT(IN) :: TRANA, TRANB
496         INTEGER, INTENT(IN) :: ISGN, LDA, LDB, LDC, M, N
497         INTEGER, INTENT(OUT) :: INFO
498         REAL(WP), INTENT(OUT) :: SCALE
499         REAL(WP), INTENT(IN) :: A(LDA,*), B(LDB,*)
500         REAL(WP), INTENT(INOUT) :: C(LDC,*)
501      END SUBROUTINE DTRSYL
502
503      END INTERFACE
504
505      INTERFACE LA_TREXC
506
507      SUBROUTINE DTREXC( COMPQ, N, T, LDT, Q, LDQ, IFST, ILST, WORK,    &
508     &                   INFO )
509         USE LA_PRECISION, ONLY: WP => DP
510         CHARACTER(LEN=1), INTENT(IN) :: COMPQ
511         INTEGER, INTENT(IN) :: IFST, ILST, LDQ, LDT, N
512         INTEGER, INTENT(OUT) :: INFO
513         REAL(WP), INTENT(INOUT) :: Q(LDQ,*), T(LDT,*), WORK(*)
514      END SUBROUTINE DTREXC
515
516      END INTERFACE
517
518      INTERFACE LA_TREVC
519
520      SUBROUTINE DTREVC( SIDE, HOWMNY, SELECT, N, T, LDT, VL, LDVL, VR, &
521     &                   LDVR, MM, M, WORK, INFO )
522         USE LA_PRECISION, ONLY: WP => DP
523         CHARACTER(LEN=1), INTENT(IN) :: HOWMNY, SIDE
524         INTEGER, INTENT(IN) :: LDT, LDVL, LDVR, MM, N
525         INTEGER, INTENT(OUT) :: INFO, M
526         LOGICAL, INTENT(INOUT) :: SELECT(*)
527         REAL(WP), INTENT(IN) :: T(LDT,*)
528         REAL(WP), INTENT(INOUT) :: VL(LDVL,*), VR(LDVR,*)
529         REAL(WP), INTENT(OUT) :: WORK(*)
530      END SUBROUTINE DTREVC
531
532      END INTERFACE
533
534      INTERFACE LA_HSEIN
535
536      SUBROUTINE DHSEIN( SIDE, EIGSRC, INITV, SELECT, N, H, LDH, WR, WI,&
537     &                   VL, LDVL, VR, LDVR, MM, M, WORK, IFAILL,       &
538     &                   IFAILR, INFO )
539         USE LA_PRECISION, ONLY: WP => DP
540         CHARACTER(LEN=1), INTENT(IN) :: EIGSRC, INITV, SIDE
541         INTEGER, INTENT(IN) :: LDH, LDVL, LDVR, MM, N
542         INTEGER, INTENT(OUT) :: INFO, M, IFAILL(*), IFAILR(*)
543         LOGICAL, INTENT(IN) :: SELECT(*)
544         REAL(WP), INTENT(INOUT) :: WR(*), WI(*)
545         REAL(WP), INTENT(IN) :: H(LDH,*)
546         REAL(WP), INTENT(INOUT) :: VL(LDVL,*), VR(LDVR,*)
547         REAL(WP), INTENT(OUT) :: WORK(*)
548      END SUBROUTINE DHSEIN
549
550      END INTERFACE
551
552      INTERFACE LA_HSEQR
553
554      SUBROUTINE DHSEQR( JOB, COMPZ, N, ILO, IHI, H, LDH, WR, WI, Z,    &
555     &                   LDZ, WORK, LWORK, INFO )
556         USE LA_PRECISION, ONLY: WP => DP
557         CHARACTER(LEN=1), INTENT(IN) :: COMPZ, JOB
558         INTEGER, INTENT(IN) :: IHI, ILO, LDH, LDZ, LWORK, N
559         INTEGER, INTENT(OUT) :: INFO
560         REAL(WP), INTENT(OUT) :: WR(*), WI(*)
561         REAL(WP), INTENT(INOUT) :: H(LDH,*), Z(LDZ,*)
562         REAL(WP), INTENT(OUT) :: WORK(LWORK)
563      END SUBROUTINE DHSEQR
564
565      END INTERFACE
566
567      INTERFACE LA_ORMHR
568
569      SUBROUTINE DORMHR( SIDE, TRANS, M, N, ILO, IHI, A, LDA, TAU, C,   &
570     &                   LDC, WORK, LWORK, INFO )
571         USE LA_PRECISION, ONLY: WP => DP
572         CHARACTER(LEN=1),  INTENT(IN) :: SIDE, TRANS
573         INTEGER, INTENT(IN) :: IHI, ILO, LDA, LDC, LWORK, M, N
574         INTEGER, INTENT(OUT) :: INFO
575         REAL(WP), INTENT(IN) :: A(LDA,*), TAU(*)
576         REAL(WP), INTENT(INOUT) :: C(LDA,*)
577         REAL(WP), INTENT(OUT) :: WORK(LWORK)
578      END SUBROUTINE DORMHR
579
580      END INTERFACE
581
582
583      INTERFACE LA_ORGHR
584
585      SUBROUTINE DORGHR( N, ILO, IHI, A, LDA, TAU, WORK, LWORK, INFO )
586         USE LA_PRECISION, ONLY: WP => DP
587         INTEGER, INTENT(IN) :: IHI, ILO, LDA, LWORK, N
588         INTEGER, INTENT(OUT) :: INFO
589         REAL(WP), INTENT(IN) :: TAU(*)
590         REAL(WP), INTENT(INOUT) :: A(LDA,*)
591         REAL(WP), INTENT(OUT) :: WORK(LWORK)
592      END SUBROUTINE DORGHR
593
594      END INTERFACE
595
596
597      INTERFACE LA_GEBAK
598
599      SUBROUTINE DGEBAK( JOB, SIDE, N, ILO, IHI, SCALE, M, V, LDV,      &
600     &                   INFO )
601         USE LA_PRECISION, ONLY: WP => DP
602         CHARACTER(LEN=1), INTENT(IN) :: JOB, SIDE
603         INTEGER, INTENT(IN) :: IHI, ILO, LDV, M, N
604         INTEGER, INTENT(OUT) :: INFO
605         REAL(WP), INTENT(IN) :: SCALE(*)
606         REAL(WP), INTENT(INOUT) :: V(LDV,*)
607      END SUBROUTINE DGEBAK
608
609      END INTERFACE
610
611      INTERFACE LA_GEBAL
612
613      SUBROUTINE DGEBAL( JOB, N, A, LDA, ILO, IHI, SCALE, INFO )
614         USE LA_PRECISION, ONLY: WP => DP
615         CHARACTER(LEN=1), INTENT(IN) :: JOB
616         INTEGER, INTENT(IN) :: LDA, N
617         INTEGER, INTENT(OUT) :: IHI, ILO, INFO
618         REAL(WP), INTENT(OUT) :: SCALE(*)
619         REAL(WP), INTENT(INOUT) :: A(LDA,*)
620      END SUBROUTINE DGEBAL
621
622      END INTERFACE
623
624      INTERFACE LA_GEHRD
625
626      SUBROUTINE DGEHRD( N, ILO, IHI, A, LDA, TAU, WORK, LWORK, INFO )
627         USE LA_PRECISION, ONLY: WP => DP
628         INTEGER, INTENT(IN) :: IHI, ILO, LDA, LWORK, N
629         INTEGER, INTENT(OUT) :: INFO
630         REAL(WP), INTENT(INOUT) :: A(LDA,*)
631         REAL(WP), INTENT(OUT) :: TAU(*), WORK(LWORK)
632      END SUBROUTINE DGEHRD
633
634      END INTERFACE
635
636      INTERFACE LA_PTEQR
637
638      SUBROUTINE DPTEQR( COMPZ, N, D, E, Z, LDZ, WORK, INFO )
639         USE LA_PRECISION, ONLY: WP => DP
640         CHARACTER(LEN=1), INTENT(IN) :: COMPZ
641         INTEGER, INTENT(IN) :: INFO, LDZ, N
642         REAL(WP), INTENT(INOUT) :: D(*), E(*)
643         REAL(WP), INTENT(OUT) :: WORK(*)
644         REAL(WP), INTENT(INOUT) :: Z(LDZ,*)
645      END SUBROUTINE DPTEQR
646
647      END INTERFACE
648
649      INTERFACE LA_STEIN
650
651      SUBROUTINE DSTEIN( N, D, E, M, W, IBLOCK, ISPLIT, Z, LDZ, WORK,   &
652     &                   IWORK, IFAIL, INFO )
653         USE LA_PRECISION, ONLY: WP => DP
654         INTEGER, INTENT(IN) :: LDZ, M, N, IBLOCK(*), ISPLIT(*)
655         INTEGER, INTENT(OUT) :: INFO, IFAIL(*), IWORK(*)
656         REAL(WP), INTENT(IN) :: D(*), E(*), W(*)
657         REAL(WP), INTENT(OUT) :: WORK(*)
658         REAL(WP), INTENT(OUT) :: Z( LDZ, * )
659      END SUBROUTINE DSTEIN
660
661      END INTERFACE
662
663      INTERFACE LA_STEBZ
664
665      SUBROUTINE DSTEBZ( RANGE, ORDER, N, VL, VU, IL, IU, ABSTOL, D, E, &
666     &                   M, NSPLIT, W, IBLOCK, ISPLIT, WORK, IWORK,     &
667     &                   INFO )
668         USE LA_PRECISION, ONLY: WP => DP
669         CHARACTER(LEN=1), INTENT(IN) :: ORDER, RANGE
670         INTEGER, INTENT(IN) :: IL, IU, M, N
671         INTEGER, INTENT(OUT) :: INFO, NSPLIT, IBLOCK(*), ISPLIT(*),    &
672     &                           IWORK(*)
673         REAL(WP), INTENT(IN) :: ABSTOL, VL, VU, D(*), E(*)
674         REAL(WP), INTENT(OUT) :: W(*), WORK(*)
675      END SUBROUTINE DSTEBZ
676
677      END INTERFACE
678
679      INTERFACE LA_STEDC
680
681      SUBROUTINE DSTEDC( COMPZ, N, D, E, Z, LDZ, WORK, LWORK, IWORK,    &
682     &                   LIWORK, INFO )
683         USE LA_PRECISION, ONLY: WP => DP
684         CHARACTER(LEN=1), INTENT(IN) :: COMPZ
685         INTEGER, INTENT(IN) :: LDZ, LIWORK, LWORK, N
686         INTEGER, INTENT(OUT) :: INFO, IWORK(LIWORK)
687         REAL(WP), INTENT(INOUT) :: D(*), E(*)
688         REAL(WP), INTENT(INOUT) :: Z(LDZ,*)
689         REAL(WP), INTENT(OUT) :: WORK(LWORK)
690      END SUBROUTINE DSTEDC
691
692      END INTERFACE
693
694      INTERFACE LA_STERF
695
696      SUBROUTINE DSTERF( N, D, E, INFO )
697         USE LA_PRECISION, ONLY: WP => DP
698         INTEGER, INTENT(IN) :: N
699         INTEGER, INTENT(OUT) :: INFO
700         REAL(WP), INTENT(INOUT) :: D(*), E(*)
701      END SUBROUTINE DSTERF
702
703      END INTERFACE
704
705      INTERFACE LA_STEQR
706
707      SUBROUTINE DSTEQR( COMPZ, N, D, E, Z, LDZ, WORK, INFO )
708         USE LA_PRECISION, ONLY: WP => DP
709         CHARACTER(LEN=1), INTENT(IN) :: COMPZ
710         INTEGER, INTENT(IN) :: LDZ, N
711         INTEGER, INTENT(OUT) :: INFO
712         REAL(WP), INTENT(INOUT) :: D(*), E(*)
713         REAL(WP), INTENT(OUT) :: WORK(*)
714         REAL(WP), INTENT(INOUT) :: Z(LDZ,*)
715      END SUBROUTINE DSTEQR
716
717      END INTERFACE
718
719      INTERFACE LA_OPMTR
720
721      SUBROUTINE DOPMTR( SIDE, UPLO, TRANS, M, N, AP, TAU, C, LDC, WORK,&
722     &                   INFO )
723         USE LA_PRECISION, ONLY: WP => DP
724         CHARACTER(LEN=1), INTENT(IN) :: SIDE, TRANS, UPLO
725         INTEGER, INTENT(IN) :: LDC, M, N
726         INTEGER, INTENT(OUT) :: INFO
727         REAL(WP), INTENT(IN) :: AP(*), TAU(*)
728         REAL(WP), INTENT(INOUT) :: C(LDC,*)
729         REAL(WP), INTENT(OUT) :: WORK(*)
730      END SUBROUTINE DOPMTR
731
732      END INTERFACE
733
734
735      INTERFACE LA_OPGTR
736
737      SUBROUTINE DOPGTR( UPLO, N, AP, TAU, Q, LDQ, WORK, INFO )
738         USE LA_PRECISION, ONLY: WP => DP
739         CHARACTER(LEN=1), INTENT(IN) :: UPLO
740         INTEGER, INTENT(IN) :: LDQ, N
741         INTEGER, INTENT(OUT) :: INFO
742         REAL(WP), INTENT(IN) :: AP(*), TAU(*)
743         REAL(WP), INTENT(OUT) :: Q(LDQ,*), WORK(*)
744      END SUBROUTINE DOPGTR
745
746      END INTERFACE
747
748
749      INTERFACE LA_ORMTR
750
751      SUBROUTINE DORMTR( SIDE, UPLO, TRANS, M, N, A, LDA, TAU, C, LDC,  &
752     &                   WORK, LWORK, INFO )
753         USE LA_PRECISION, ONLY: WP => DP
754         CHARACTER(LEN=1), INTENT(IN) :: SIDE, TRANS, UPLO
755         INTEGER, INTENT(IN) :: LDA, LDC, LWORK, M, N
756         INTEGER, INTENT(OUT) :: INFO
757         REAL(WP), INTENT(IN) :: A(LDA,*), TAU(*)
758         REAL(WP), INTENT(OUT) :: WORK(LWORK)
759         REAL(WP), INTENT(INOUT) :: C(LDC,*)
760      END SUBROUTINE DORMTR
761
762      END INTERFACE
763
764
765      INTERFACE LA_SBTRD
766
767      SUBROUTINE DSBTRD( VECT, UPLO, N, KD, AB, LDAB, D, E, Q, LDQ,     &
768     &                   WORK, INFO )
769         USE LA_PRECISION, ONLY: WP => DP
770         CHARACTER(LEN=1), INTENT(IN) :: UPLO, VECT
771         INTEGER, INTENT(IN) :: KD, LDAB, LDQ, N
772         INTEGER, INTENT(OUT) :: INFO
773         REAL(WP), INTENT(OUT) :: D(*), E(*)
774         REAL(WP), INTENT(INOUT) :: AB(LDAB,*), Q(LDQ,*)
775         REAL(WP), INTENT(OUT) :: WORK(*)
776      END SUBROUTINE DSBTRD
777
778      END INTERFACE
779
780
781      INTERFACE LA_SPTRD
782
783      SUBROUTINE DSPTRD( UPLO, N, AP, D, E, TAU, INFO )
784         USE LA_PRECISION, ONLY: WP => DP
785         CHARACTER(LEN=1), INTENT(IN) :: UPLO
786         INTEGER, INTENT(IN) :: N
787         INTEGER, INTENT(OUT) :: INFO
788         REAL(WP), INTENT(OUT) :: D(*), E(*)
789         REAL(WP), INTENT(INOUT) :: AP(*)
790         REAL(WP), INTENT(OUT) :: TAU(*)
791      END SUBROUTINE DSPTRD
792
793      END INTERFACE
794
795
796      INTERFACE LA_TZRQF
797
798      SUBROUTINE DTZRQF( M, N, A, LDA, TAU, WORK, LWORK, INFO )
799         USE LA_PRECISION, ONLY: WP => DP
800         INTEGER, INTENT(IN) :: LDA, LWORK, M, N
801         INTEGER, INTENT(OUT) :: INFO
802         REAL(WP), INTENT(INOUT) :: A(LDA,*)
803         REAL(WP), INTENT(OUT) :: TAU(*), WORK(LWORK)
804      END SUBROUTINE DTZRQF
805
806      END INTERFACE
807
808      INTERFACE LA_ORMRQ
809
810      SUBROUTINE DORMRQ( SIDE, TRANS, M, N, K, A, LDA, TAU, C, LDC,     &
811     &                   WORK, LWORK, INFO )
812         USE LA_PRECISION, ONLY: WP => DP
813         CHARACTER(LEN=1), INTENT(IN) :: SIDE, TRANS
814         INTEGER, INTENT(IN) :: K, LDA, LDC, LWORK, M, N
815         INTEGER, INTENT(OUT) :: INFO
816         REAL(WP), INTENT(IN) :: A(LDA,*), TAU(*)
817         REAL(WP), INTENT(INOUT) :: C(LDC,*)
818         REAL(WP), INTENT(OUT) :: WORK(LWORK)
819      END SUBROUTINE DORMRQ
820
821      END INTERFACE
822
823
824      INTERFACE LA_ORGRQ
825
826      SUBROUTINE DORGRQ( M, N, K, A, LDA, TAU, WORK, LWORK, INFO )
827         USE LA_PRECISION, ONLY: WP => DP
828         INTEGER, INTENT(IN) :: K, LDA, LWORK, M, N
829         INTEGER, INTENT(OUT) :: INFO
830         REAL(WP), INTENT(IN) :: TAU(*)
831         REAL(WP), INTENT(INOUT) :: A(LDA,*)
832         REAL(WP), INTENT(OUT) :: WORK(LWORK)
833      END SUBROUTINE DORGRQ
834
835      END INTERFACE
836
837
838      INTERFACE LA_GERQF
839
840      SUBROUTINE DGERQF( M, N, A, LDA, TAU, WORK, LWORK, INFO )
841         USE LA_PRECISION, ONLY: WP => DP
842         INTEGER, INTENT(IN) :: LDA, LWORK, M, N
843         INTEGER, INTENT(OUT) :: INFO
844         REAL(WP), INTENT(INOUT) :: A(LDA,*)
845         REAL(WP), INTENT(OUT) :: TAU(*), WORK(LWORK)
846      END SUBROUTINE DGERQF
847
848      END INTERFACE
849
850      INTERFACE LA_ORMQL
851
852      SUBROUTINE DORMQL( SIDE, TRANS, M, N, K, A, LDA, TAU, C, LDC,     &
853     &                   WORK, LWORK, INFO )
854         USE LA_PRECISION, ONLY: WP => DP
855         CHARACTER(LEN=1), INTENT(IN) :: SIDE, TRANS
856         INTEGER, INTENT(IN) :: K, LDA, LDC, LWORK, M, N
857         INTEGER, INTENT(OUT) :: INFO
858         REAL(WP), INTENT(IN) :: A(LDA,*), TAU(*)
859         REAL(WP), INTENT(INOUT) :: C(LDC,*)
860         REAL(WP), INTENT(OUT) :: WORK(LWORK)
861      END SUBROUTINE DORMQL
862
863      END INTERFACE
864
865
866      INTERFACE LA_ORGQL
867
868      SUBROUTINE DORGQL( M, N, K, A, LDA, TAU, WORK, LWORK, INFO )
869         USE LA_PRECISION, ONLY: WP => DP
870         INTEGER, INTENT(IN) :: K, LDA, LWORK, M, N
871         INTEGER, INTENT(OUT) :: INFO
872         REAL(WP), INTENT(IN) :: TAU(*)
873         REAL(WP), INTENT(INOUT) :: A(LDA,*)
874         REAL(WP), INTENT(OUT) :: WORK(LWORK)
875      END SUBROUTINE DORGQL
876
877      END INTERFACE
878
879
880      INTERFACE LA_GEQLF
881
882      SUBROUTINE DGEQLF( M, N, A, LDA, TAU, WORK, LWORK, INFO )
883         USE LA_PRECISION, ONLY: WP => DP
884         INTEGER, INTENT(IN) :: LDA, LWORK, M, N
885         INTEGER, INTENT(OUT) :: INFO
886         REAL(WP), INTENT(INOUT) :: A(LDA,*)
887         REAL(WP), INTENT(OUT) :: TAU(*), WORK(LWORK)
888      END SUBROUTINE DGEQLF
889
890      END INTERFACE
891
892      INTERFACE LA_ORMLQ
893
894      SUBROUTINE DORMLQ( SIDE, TRANS, M, N, K, A, LDA, TAU, C, LDC,     &
895     &                   WORK, LWORK, INFO )
896         USE LA_PRECISION, ONLY: WP => DP
897         CHARACTER(LEN=1), INTENT(IN) :: SIDE, TRANS
898         INTEGER, INTENT(IN) :: K, LDA, LDC, LWORK, M, N
899         INTEGER, INTENT(OUT) :: INFO
900         REAL(WP), INTENT(IN) :: A(LDA,*), TAU(*)
901         REAL(WP), INTENT(INOUT) :: C(LDC,*)
902         REAL(WP), INTENT(OUT) :: WORK(LWORK)
903      END SUBROUTINE DORMLQ
904
905      END INTERFACE
906
907
908      INTERFACE LA_ORGLQ
909
910      SUBROUTINE DORGLQ( M, N, K, A, LDA, TAU, WORK, LWORK, INFO )
911         USE LA_PRECISION, ONLY: WP => DP
912         INTEGER, INTENT(IN) :: K, LDA, LWORK, M, N
913         INTEGER, INTENT(OUT) :: INFO
914         REAL(WP), INTENT(IN) :: TAU(*)
915         REAL(WP), INTENT(INOUT) :: A(LDA,*)
916         REAL(WP), INTENT(OUT) :: WORK(LWORK)
917      END SUBROUTINE DORGLQ
918
919      END INTERFACE
920
921
922      INTERFACE LA_GELQF
923
924      SUBROUTINE DGELQF( M, N, A, LDA, TAU, WORK, LWORK, INFO )
925         USE LA_PRECISION, ONLY: WP => DP
926         INTEGER, INTENT(IN) :: LDA, LWORK, M, N
927         INTEGER, INTENT(OUT) :: INFO
928         REAL(WP), INTENT(INOUT) :: A(LDA,*)
929         REAL(WP), INTENT(OUT) :: TAU(*), WORK(LWORK)
930      END SUBROUTINE DGELQF
931
932      END INTERFACE
933
934      INTERFACE LA_ORMQR
935
936      SUBROUTINE DORMQR( SIDE, TRANS, M, N, K, A, LDA, TAU, C, LDC,     &
937     &                   WORK, LWORK, INFO )
938         USE LA_PRECISION, ONLY: WP => DP
939         CHARACTER(LEN=1), INTENT(IN) :: SIDE, TRANS
940         INTEGER, INTENT(IN) :: K, LDA, LDC, LWORK, M, N
941         INTEGER, INTENT(OUT) :: INFO
942         REAL(WP), INTENT(IN) :: A(LDA,*), TAU(*)
943         REAL(WP), INTENT(INOUT) :: C(LDC,*)
944         REAL(WP), INTENT(OUT) :: WORK(LWORK)
945      END SUBROUTINE DORMQR
946
947      END INTERFACE
948
949
950      INTERFACE LA_ORGQR
951
952      SUBROUTINE DORGQR( M, N, K, A, LDA, TAU, WORK, LWORK, INFO )
953         USE LA_PRECISION, ONLY: WP => DP
954         INTEGER, INTENT(IN) :: K, LDA, LWORK, M, N
955         INTEGER, INTENT(OUT) :: INFO
956         REAL(WP), INTENT(INOUT) :: A(LDA,*)
957         REAL(WP), INTENT(IN) :: TAU(*)
958         REAL(WP), INTENT(OUT) :: WORK(LWORK)
959      END SUBROUTINE DORGQR
960
961      END INTERFACE
962
963
964      INTERFACE LA_GEQRF
965
966      SUBROUTINE DGEQRF( M, N, A, LDA, TAU, WORK, LWORK, INFO )
967         USE LA_PRECISION, ONLY: WP => DP
968         INTEGER, INTENT(IN) :: LDA, LWORK, M, N
969         INTEGER, INTENT(OUT) :: INFO
970         REAL(WP), INTENT(INOUT) :: A(LDA,*)
971         REAL(WP), INTENT(OUT) :: TAU(*), WORK(LWORK)
972      END SUBROUTINE DGEQRF
973
974      END INTERFACE
975
976      INTERFACE LA_GEQPF
977
978      SUBROUTINE DGEQPF( M, N, A, LDA, JPVT, TAU, WORK, INFO )
979         USE LA_PRECISION, ONLY: WP => DP
980         INTEGER, INTENT(IN) :: LDA, M, N
981         INTEGER, INTENT(OUT) :: INFO
982         INTEGER, INTENT(INOUT) :: JPVT(*)
983         REAL(WP), INTENT(INOUT) :: A(LDA,*)
984         REAL(WP), INTENT(OUT) :: TAU(*), WORK(*)
985      END SUBROUTINE DGEQPF
986
987      END INTERFACE
988
989      INTERFACE LA_TBRFS
990
991      SUBROUTINE DTBRFS( UPLO, TRANS, DIAG, N, KD, NRHS, AB, LDAB, B,   &
992     &                   LDB, X, LDX, FERR, BERR, WORK, IWORK, INFO )
993         USE LA_PRECISION, ONLY: WP => DP
994         CHARACTER(LEN=1), INTENT(IN) :: DIAG, TRANS, UPLO
995         INTEGER, INTENT(IN) :: KD, LDAB, LDB, LDX, N, NRHS
996         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
997         REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
998         REAL(WP), INTENT(IN) :: AB(LDAB,*), B(LDB,*), X(LDX,*)
999         REAL(WP), INTENT(OUT) :: WORK(*)
1000      END SUBROUTINE DTBRFS
1001
1002      MODULE PROCEDURE DTBRFS1
1003
1004      END INTERFACE
1005
1006      INTERFACE LA_TBCON
1007
1008      SUBROUTINE DTBCON( NORM, UPLO, DIAG, N, KD, AB, LDAB, RCOND, WORK,&
1009     &                   IWORK, INFO )
1010         USE LA_PRECISION, ONLY: WP => DP
1011         CHARACTER(LEN=1), INTENT(IN) :: DIAG, NORM, UPLO
1012         INTEGER, INTENT(IN) :: KD, LDAB, N
1013         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
1014         REAL(WP), INTENT(OUT) :: RCOND
1015         REAL(WP), INTENT(IN) :: AB(LDAB,*)
1016         REAL(WP), INTENT(OUT) :: WORK(*)
1017      END SUBROUTINE DTBCON
1018
1019      END INTERFACE
1020
1021      INTERFACE LA_TBTRS
1022
1023      SUBROUTINE DTBTRS( UPLO, TRANS, DIAG, N, KD, NRHS, AB, LDAB, B,   &
1024     &                   LDB, INFO )
1025         USE LA_PRECISION, ONLY: WP => DP
1026         CHARACTER(LEN=1), INTENT(IN) :: DIAG, TRANS, UPLO
1027         INTEGER, INTENT(IN) :: KD, LDAB, LDB, N, NRHS
1028         INTEGER, INTENT(OUT) :: INFO
1029         REAL(WP), INTENT(IN) :: AB(LDAB,*)
1030         REAL(WP), INTENT(INOUT) :: B(LDB,*)
1031      END SUBROUTINE DTBTRS
1032
1033      MODULE PROCEDURE DTBTRS1
1034
1035      END INTERFACE
1036
1037      INTERFACE LA_TPTRI
1038
1039      SUBROUTINE DTPTRI( UPLO, DIAG, N, AP, INFO )
1040         USE LA_PRECISION, ONLY: WP => DP
1041         CHARACTER(LEN=1), INTENT(IN) :: DIAG, UPLO
1042         INTEGER, INTENT(IN) :: N
1043         INTEGER, INTENT(OUT) :: INFO
1044         REAL(WP), INTENT(INOUT) :: AP( * )
1045      END SUBROUTINE DTPTRI
1046
1047      END INTERFACE
1048
1049      INTERFACE LA_TPRFS
1050
1051      SUBROUTINE DTPRFS( UPLO, TRANS, DIAG, N, NRHS, AP, B, LDB, X, LDX,&
1052     &                   FERR, BERR, WORK, IWORK, INFO )
1053         USE LA_PRECISION, ONLY: WP => DP
1054         CHARACTER(LEN=1), INTENT(IN) :: DIAG, TRANS, UPLO
1055         INTEGER, INTENT(IN) :: LDB, LDX, N, NRHS
1056         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
1057         REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
1058         REAL(WP), INTENT(IN) :: AP(*), B(LDB,*), X(LDX,*)
1059         REAL(WP), INTENT(OUT) :: WORK(*)
1060      END SUBROUTINE DTPRFS
1061
1062      MODULE PROCEDURE DTPRFS1
1063
1064      END INTERFACE
1065
1066      INTERFACE LA_TPCON
1067
1068      SUBROUTINE DTPCON( NORM, UPLO, DIAG, N, AP, RCOND, WORK, IWORK,   &
1069     &                   INFO )
1070         USE LA_PRECISION, ONLY: WP => DP
1071         CHARACTER(LEN=1), INTENT(IN) :: DIAG, NORM, UPLO
1072         INTEGER, INTENT(IN) :: N
1073         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
1074         REAL(WP), INTENT(OUT) :: RCOND
1075         REAL(WP), INTENT(IN) :: AP(*)
1076         REAL(WP), INTENT(OUT) :: WORK(*)
1077      END SUBROUTINE DTPCON
1078
1079      END INTERFACE
1080
1081      INTERFACE LA_TPTRS
1082
1083      SUBROUTINE DTPTRS( UPLO, TRANS, DIAG, N, NRHS, AP, B, LDB, INFO )
1084         USE LA_PRECISION, ONLY: WP => DP
1085         CHARACTER(LEN=1), INTENT(IN) :: DIAG, TRANS, UPLO
1086         INTEGER, INTENT(IN) :: LDB, N, NRHS
1087         INTEGER, INTENT(OUT) :: INFO
1088         REAL(WP), INTENT(IN) :: AP(*)
1089         REAL(WP), INTENT(INOUT) :: B(LDB,*)
1090      END SUBROUTINE DTPTRS
1091
1092      MODULE PROCEDURE DTPTRS1
1093
1094      END INTERFACE
1095
1096      INTERFACE LA_TRTRI
1097
1098      SUBROUTINE DTRTRI( UPLO, DIAG, N, A, LDA, INFO )
1099         USE LA_PRECISION, ONLY: WP => DP
1100         CHARACTER(LEN=1), INTENT(IN) :: DIAG, UPLO
1101         INTEGER, INTENT(IN) :: LDA, N
1102         INTEGER, INTENT(OUT) :: INFO
1103         REAL(WP), INTENT(INOUT) :: A( LDA, * )
1104      END SUBROUTINE DTRTRI
1105
1106      END INTERFACE
1107
1108      INTERFACE LA_TRRFS
1109
1110      SUBROUTINE DTRRFS( UPLO, TRANS, DIAG, N, NRHS, A, LDA, B, LDB, X, &
1111     &                   LDX, FERR, BERR, WORK, IWORK, INFO )
1112         USE LA_PRECISION, ONLY: WP => DP
1113         CHARACTER(LEN=1), INTENT(IN) :: DIAG, TRANS, UPLO
1114         INTEGER, INTENT(IN) :: LDA, LDB, LDX, N, NRHS
1115         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
1116         REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
1117         REAL(WP), INTENT(IN) :: A(LDA,*), B(LDB,*)
1118         REAL(WP), INTENT(IN) :: X(LDX,*)
1119         REAL(WP), INTENT(OUT) :: WORK(*)
1120      END SUBROUTINE DTRRFS
1121
1122      MODULE PROCEDURE DTRRFS1
1123
1124      END INTERFACE
1125
1126      INTERFACE LA_TRCON
1127
1128      SUBROUTINE DTRCON( NORM, UPLO, DIAG, N, A, LDA, RCOND, WORK,      &
1129     &                   IWORK, INFO )
1130         USE LA_PRECISION, ONLY: WP => DP
1131         CHARACTER(LEN=1), INTENT(IN) :: DIAG, NORM, UPLO
1132         INTEGER, INTENT(IN) :: LDA, N
1133         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
1134         REAL(WP), INTENT(OUT) :: RCOND
1135         REAL(WP), INTENT(IN) :: A(LDA,*)
1136         REAL(WP), INTENT(OUT) :: WORK(*)
1137      END SUBROUTINE DTRCON
1138
1139      END INTERFACE
1140
1141      INTERFACE LA_TRTRS
1142
1143      SUBROUTINE DTRTRS( UPLO, TRANS, DIAG, N, NRHS, A, LDA, B, LDB,    &
1144     &                   INFO )
1145         USE LA_PRECISION, ONLY: WP => DP
1146         CHARACTER(LEN=1), INTENT(IN) :: DIAG, TRANS, UPLO
1147         INTEGER, INTENT(IN) :: LDA, LDB, N, NRHS
1148         INTEGER, INTENT(OUT) :: INFO
1149         REAL(WP), INTENT(IN) :: A(LDA,*)
1150         REAL(WP), INTENT(INOUT) :: B(LDB,*)
1151      END SUBROUTINE DTRTRS
1152
1153      MODULE PROCEDURE DTRTRS1
1154
1155      END INTERFACE
1156
1157      INTERFACE LA_SPTRI
1158
1159      SUBROUTINE DSPTRI( UPLO, N, AP, IPIV, WORK, INFO )
1160         USE LA_PRECISION, ONLY: WP => DP
1161         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1162         INTEGER, INTENT(IN) :: N
1163         INTEGER, INTENT(OUT) :: INFO
1164         INTEGER, INTENT(IN) :: IPIV(*)
1165         REAL(WP), INTENT(INOUT) :: AP(*)
1166         REAL(WP), INTENT(OUT) :: WORK(*)
1167      END SUBROUTINE DSPTRI
1168
1169      END INTERFACE
1170
1171
1172      INTERFACE LA_SPRFS
1173
1174      SUBROUTINE DSPRFS( UPLO, N, NRHS, AP, AFP, IPIV, B, LDB, X, LDX,  &
1175     &                   FERR, BERR, WORK, IWORK, INFO )
1176         USE LA_PRECISION, ONLY: WP => DP
1177         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1178         INTEGER, INTENT(IN) :: LDB, LDX, N, NRHS
1179         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
1180         INTEGER, INTENT(IN) :: IPIV(*)
1181         REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
1182         REAL(WP), INTENT(IN) :: AFP(*), AP(*), B(LDB,*)
1183         REAL(WP), INTENT(INOUT) :: X(LDX,*)
1184         REAL(WP), INTENT(OUT) :: WORK(*)
1185      END SUBROUTINE DSPRFS
1186
1187      MODULE PROCEDURE DSPRFS1
1188
1189      END INTERFACE
1190
1191
1192
1193      INTERFACE LA_SPCON
1194
1195      SUBROUTINE DSPCON( UPLO, N, AP, IPIV, ANORM, RCOND, WORK, IWORK,  &
1196     &                   INFO )
1197         USE LA_PRECISION, ONLY: WP => DP
1198         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1199         INTEGER, INTENT(IN) :: N
1200         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
1201         REAL(WP), INTENT(IN) :: ANORM
1202         REAL(WP), INTENT(OUT) :: RCOND
1203         INTEGER, INTENT(IN) :: IPIV( * )
1204         REAL(WP), INTENT(IN) :: AP(*)
1205         REAL(WP), INTENT(OUT) :: WORK(*)
1206      END SUBROUTINE DSPCON
1207
1208      END INTERFACE
1209
1210      INTERFACE LA_SPTRS
1211
1212      SUBROUTINE DSPTRS( UPLO, N, NRHS, AP, IPIV, B, LDB, INFO )
1213         USE LA_PRECISION, ONLY: WP => DP
1214         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1215         INTEGER, INTENT(IN) :: LDB, N, NRHS
1216         INTEGER, INTENT(OUT) :: INFO
1217         INTEGER, INTENT(IN) :: IPIV(*)
1218         REAL(WP), INTENT(IN) :: AP(*)
1219         REAL(WP), INTENT(INOUT) :: B(LDB,*)
1220      END SUBROUTINE DSPTRS
1221
1222      MODULE PROCEDURE DSPTRS1
1223
1224      END INTERFACE
1225
1226
1227
1228      INTERFACE LA_SPTRF
1229
1230      SUBROUTINE DSPTRF( UPLO, N, AP, IPIV, INFO )
1231         USE LA_PRECISION, ONLY: WP => DP
1232         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1233         INTEGER, INTENT(IN) :: N
1234         INTEGER, INTENT(OUT) :: INFO, IPIV(*)
1235         REAL(WP), INTENT(INOUT) :: AP(*)
1236      END SUBROUTINE DSPTRF
1237
1238      END INTERFACE
1239
1240      INTERFACE LA_SYTRI
1241
1242      SUBROUTINE DSYTRI( UPLO, N, A, LDA, IPIV, WORK, INFO )
1243         USE LA_PRECISION, ONLY: WP => DP
1244         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1245         INTEGER, INTENT(IN) :: LDA, N
1246         INTEGER, INTENT(OUT) :: INFO
1247         INTEGER, INTENT(IN) :: IPIV(*)
1248         REAL(WP), INTENT(INOUT) :: A( LDA,*)
1249         REAL(WP), INTENT(OUT) :: WORK(*)
1250      END SUBROUTINE DSYTRI
1251
1252      END INTERFACE
1253
1254
1255      INTERFACE LA_SYRFS
1256
1257      SUBROUTINE DSYRFS( UPLO, N, NRHS, A, LDA, AF, LDAF, IPIV, B, LDB, &
1258     &                   X, LDX, FERR, BERR, WORK, IWORK, INFO )
1259         USE LA_PRECISION, ONLY: WP => DP
1260         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1261         INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, N, NRHS
1262         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
1263         INTEGER, INTENT(IN) :: IPIV(*)
1264         REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
1265         REAL(WP), INTENT(IN) ::  A( LDA,*), AF( LDAF,*), B( LDB,*)
1266         REAL(WP), INTENT(INOUT) :: X( LDX,*)
1267         REAL(WP), INTENT(OUT) :: WORK(*)
1268      END SUBROUTINE DSYRFS
1269
1270      MODULE PROCEDURE DSYRFS1
1271
1272      END INTERFACE
1273
1274
1275      INTERFACE LA_SYCON
1276
1277      SUBROUTINE DSYCON( UPLO, N, A, LDA, IPIV, ANORM, RCOND, WORK,     &
1278     &                   IWORK, INFO )
1279         USE LA_PRECISION, ONLY: WP => DP
1280         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1281         INTEGER, INTENT(IN) :: LDA, N
1282         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
1283         REAL(WP), INTENT(IN) :: ANORM
1284         REAL(WP), INTENT(OUT) :: RCOND
1285         INTEGER, INTENT(IN) :: IPIV(*)
1286         REAL(WP), INTENT(IN) :: A( LDA,*)
1287         REAL(WP), INTENT(OUT) :: WORK(*)
1288      END SUBROUTINE DSYCON
1289
1290      END INTERFACE
1291
1292
1293
1294      INTERFACE LA_SYTRS
1295
1296      SUBROUTINE DSYTRS( UPLO, N, NRHS, A, LDA, IPIV, B, LDB, INFO )
1297         USE LA_PRECISION, ONLY: WP => DP
1298         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1299         INTEGER, INTENT(IN) :: LDA, LDB, N, NRHS
1300         INTEGER, INTENT(OUT) :: INFO
1301         INTEGER , INTENT(IN) :: IPIV(*)
1302         REAL(WP), INTENT(IN) :: A( LDA,*)
1303         REAL(WP), INTENT(INOUT) :: B( LDB,*)
1304      END SUBROUTINE DSYTRS
1305
1306      MODULE PROCEDURE DSYTRS1
1307
1308      END INTERFACE
1309
1310
1311      INTERFACE LA_SYTRF
1312
1313      SUBROUTINE DSYTRF( UPLO, N, A, LDA, IPIV, WORK, LWORK, INFO )
1314         USE LA_PRECISION, ONLY: WP => DP
1315         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1316         INTEGER, INTENT(IN) :: LDA, LWORK, N
1317         INTEGER, INTENT(OUT) :: INFO, IPIV(*)
1318         REAL(WP), INTENT(INOUT) :: A( LDA,*)
1319         REAL(WP), INTENT(OUT) :: WORK( LWORK )
1320      END SUBROUTINE DSYTRF
1321
1322      END INTERFACE
1323
1324      INTERFACE LA_PTRFS
1325
1326      SUBROUTINE DPTRFS( N, NRHS, D, E, DF, EF, B, LDB, X, LDX, FERR,   &
1327     &                   BERR, WORK, INFO )
1328         USE LA_PRECISION, ONLY: WP => DP
1329         INTEGER, INTENT(IN) :: LDB, LDX, N, NRHS
1330         INTEGER, INTENT(OUT) :: INFO
1331         REAL(WP), INTENT(IN) :: D(*), DF(*)
1332         REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
1333         REAL(WP), INTENT(IN) :: B( LDB,*), E(*), EF(*)
1334         REAL(WP), INTENT(INOUT) :: X( LDX,*)
1335         REAL(WP), INTENT(OUT) :: WORK(*)
1336      END SUBROUTINE DPTRFS
1337
1338      MODULE PROCEDURE DPTRFS1
1339
1340      END INTERFACE
1341
1342      INTERFACE LA_PTCON
1343
1344      SUBROUTINE DPTCON( N, D, E, ANORM, RCOND, RWORK, INFO )
1345         USE LA_PRECISION, ONLY: WP => DP
1346         INTEGER, INTENT(IN) :: N
1347         INTEGER, INTENT(OUT) :: INFO
1348         REAL(WP), INTENT(IN) :: ANORM, D(*)
1349         REAL(WP), INTENT(OUT) :: RCOND, RWORK(*)
1350         REAL(WP), INTENT(IN) :: E(*)
1351      END SUBROUTINE DPTCON
1352
1353      END INTERFACE
1354
1355      INTERFACE LA_PTTRS
1356
1357      SUBROUTINE DPTTRS( N, NRHS, D, E, B, LDB, INFO )
1358         USE LA_PRECISION, ONLY: WP => DP
1359         INTEGER, INTENT(IN) :: LDB, N, NRHS
1360         INTEGER, INTENT(OUT) :: INFO
1361         REAL(WP), INTENT(IN) :: D(*)
1362         REAL(WP), INTENT(IN) :: E(*)
1363         REAL(WP), INTENT(INOUT) :: B( LDB,*)
1364      END SUBROUTINE DPTTRS
1365
1366      MODULE PROCEDURE DPTTRS1
1367
1368      END INTERFACE
1369
1370      INTERFACE LA_PTTRF
1371
1372      SUBROUTINE DPTTRF( N, D, E, INFO )
1373         USE LA_PRECISION, ONLY: WP => DP
1374         INTEGER, INTENT(IN) :: N
1375         INTEGER, INTENT(OUT) :: INFO
1376         REAL(WP), INTENT(INOUT) :: D( * )
1377         REAL(WP), INTENT(INOUT) :: E( * )
1378      END SUBROUTINE DPTTRF
1379
1380      END INTERFACE
1381
1382      INTERFACE LA_PBEQU
1383
1384      SUBROUTINE DPBEQU( UPLO, N, KD, AB, LDAB, S, SCOND, AMAX, INFO )
1385         USE LA_PRECISION, ONLY: WP => DP
1386         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1387         INTEGER, INTENT(IN) :: KD, LDAB, N
1388         INTEGER, INTENT(OUT) :: INFO
1389         REAL(WP), INTENT(OUT) :: AMAX, SCOND, S(*)
1390         REAL(WP), INTENT(IN) :: AB( LDAB,*)
1391      END SUBROUTINE DPBEQU
1392
1393      END INTERFACE
1394
1395      INTERFACE LA_PBRFS
1396
1397      SUBROUTINE DPBRFS( UPLO, N, KD, NRHS, AB, LDAB, AFB, LDAFB, B,    &
1398     &                   LDB, X, LDX, FERR, BERR, WORK, IWORK, INFO )
1399         USE LA_PRECISION, ONLY: WP => DP
1400         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1401         INTEGER, INTENT(IN) ::  KD, LDAB, LDAFB, LDB, LDX, N, NRHS
1402         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
1403         REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
1404         REAL(WP), INTENT(IN) ::  AB( LDAB,*), AFB( LDAFB,*), B( LDB,*)
1405         REAL(WP), INTENT(INOUT) :: X( LDX,*)
1406         REAL(WP), INTENT(OUT) :: WORK(*)
1407      END SUBROUTINE DPBRFS
1408
1409      MODULE PROCEDURE DPBRFS1
1410
1411      END INTERFACE
1412
1413      INTERFACE LA_PBCON
1414
1415      SUBROUTINE DPBCON( UPLO, N, KD, AB, LDAB, ANORM, RCOND, WORK,     &
1416     &                   IWORK, INFO )
1417         USE LA_PRECISION, ONLY: WP => DP
1418         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1419         INTEGER, INTENT(IN) :: KD, LDAB, N
1420         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
1421         REAL(WP), INTENT(IN) :: ANORM
1422         REAL(WP), INTENT(OUT) :: RCOND
1423         REAL(WP), INTENT(IN) :: AB( LDAB,*)
1424         REAL(WP), INTENT(OUT) :: WORK(*)
1425      END SUBROUTINE DPBCON
1426
1427      END INTERFACE
1428
1429      INTERFACE LA_PBTRS
1430
1431      SUBROUTINE DPBTRS( UPLO, N, KD, NRHS, AB, LDAB, B, LDB, INFO )
1432         USE LA_PRECISION, ONLY: WP => DP
1433         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1434         INTEGER, INTENT(IN) :: KD, LDAB, LDB, N, NRHS
1435         INTEGER, INTENT(OUT) :: INFO
1436         REAL(WP), INTENT(IN) :: AB( LDAB,*)
1437         REAL(WP), INTENT(INOUT) :: B( LDB,*)
1438      END SUBROUTINE DPBTRS
1439
1440      MODULE PROCEDURE DPBTRS1
1441
1442      END INTERFACE
1443
1444      INTERFACE LA_PBTRF
1445
1446      SUBROUTINE DPBTRF( UPLO, N, KD, AB, LDAB, INFO )
1447         USE LA_PRECISION, ONLY: WP => DP
1448         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1449         INTEGER, INTENT(IN) :: KD, LDAB, N
1450         INTEGER, INTENT(OUT) :: INFO
1451         REAL(WP), INTENT(INOUT) :: AB( LDAB,*)
1452      END SUBROUTINE DPBTRF
1453
1454      END INTERFACE
1455
1456      INTERFACE LA_PPEQU
1457
1458      SUBROUTINE DPPEQU( UPLO, N, AP, S, SCOND, AMAX, INFO )
1459         USE LA_PRECISION, ONLY: WP => DP
1460         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1461         INTEGER, INTENT(IN) :: N
1462         INTEGER, INTENT(OUT) :: INFO
1463         REAL(WP), INTENT(OUT) :: AMAX, SCOND, S(*)
1464         REAL(WP), INTENT(IN) :: AP(*)
1465      END SUBROUTINE DPPEQU
1466
1467      END INTERFACE
1468
1469      INTERFACE LA_PPTRI
1470
1471      SUBROUTINE DPPTRI( UPLO, N, AP, INFO )
1472         USE LA_PRECISION, ONLY: WP => DP
1473         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1474         INTEGER, INTENT(IN) :: N
1475         INTEGER, INTENT(OUT) :: INFO
1476         REAL(WP), INTENT(INOUT) :: AP(*)
1477      END SUBROUTINE DPPTRI
1478
1479      END INTERFACE
1480
1481      INTERFACE LA_PPRFS
1482
1483      SUBROUTINE DPPRFS( UPLO, N, NRHS, AP, AFP, B, LDB, X, LDX, FERR,  &
1484     &                   BERR, WORK, IWORK, INFO )
1485         USE LA_PRECISION, ONLY: WP => DP
1486         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1487         INTEGER, INTENT(IN) :: LDB, LDX, N, NRHS
1488         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
1489         REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
1490         REAL(WP), INTENT(IN) :: AFP(*), AP(*), B( LDB,*)
1491         REAL(WP), INTENT(INOUT) :: X( LDX,*)
1492         REAL(WP), INTENT(OUT) :: WORK(*)
1493      END SUBROUTINE DPPRFS
1494
1495      MODULE PROCEDURE DPPRFS1
1496
1497      END INTERFACE
1498
1499      INTERFACE LA_PPCON
1500
1501      SUBROUTINE DPPCON( UPLO, N, AP, ANORM, RCOND, WORK, IWORK, INFO )
1502         USE LA_PRECISION, ONLY: WP => DP
1503         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1504         INTEGER, INTENT(IN) :: N
1505         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
1506         REAL(WP), INTENT(IN) :: ANORM
1507         REAL(WP), INTENT(OUT) :: RCOND
1508         REAL(WP), INTENT(IN) :: AP(*)
1509         REAL(WP), INTENT(OUT) :: WORK(*)
1510      END SUBROUTINE DPPCON
1511
1512      END INTERFACE
1513
1514      INTERFACE LA_PPTRS
1515
1516      SUBROUTINE DPPTRS( UPLO, N, NRHS, AP, B, LDB, INFO )
1517         USE LA_PRECISION, ONLY: WP => DP
1518         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1519         INTEGER, INTENT(IN) :: LDB, N, NRHS
1520         INTEGER, INTENT(OUT) :: INFO
1521         REAL(WP), INTENT(IN) :: AP(*)
1522         REAL(WP), INTENT(INOUT) :: B( LDB,*)
1523      END SUBROUTINE DPPTRS
1524
1525      MODULE PROCEDURE DPPTRS1
1526
1527      END INTERFACE
1528
1529      INTERFACE LA_PPTRF
1530
1531      SUBROUTINE DPPTRF( UPLO, N, AP, INFO )
1532         USE LA_PRECISION, ONLY: WP => DP
1533         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1534         INTEGER, INTENT(IN) :: N
1535         INTEGER, INTENT(OUT) :: INFO
1536         REAL(WP), INTENT(INOUT) :: AP(*)
1537      END SUBROUTINE DPPTRF
1538
1539      END INTERFACE
1540
1541      INTERFACE LA_POEQU
1542
1543      SUBROUTINE DPOEQU( N, A, LDA, S, SCOND, AMAX, INFO )
1544         USE LA_PRECISION, ONLY: WP => DP
1545         INTEGER, INTENT(IN) :: LDA, N
1546         INTEGER, INTENT(OUT) :: INFO
1547         REAL(WP), INTENT(OUT) :: AMAX, SCOND, S(*)
1548         REAL(WP), INTENT(IN) :: A( LDA,*)
1549      END SUBROUTINE DPOEQU
1550
1551      END INTERFACE
1552
1553      INTERFACE LA_POTRI
1554
1555      SUBROUTINE DPOTRI( UPLO, N, A, LDA, INFO )
1556         USE LA_PRECISION, ONLY: WP => DP
1557         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1558         INTEGER, INTENT(IN) :: LDA, N
1559         INTEGER, INTENT(OUT) :: INFO
1560         REAL(WP), INTENT(INOUT) :: A( LDA,*)
1561      END SUBROUTINE DPOTRI
1562
1563      END INTERFACE
1564
1565      INTERFACE LA_PORFS
1566
1567      SUBROUTINE DPORFS( UPLO, N, NRHS, A, LDA, AF, LDAF, B, LDB, X,    &
1568     &                   LDX, FERR, BERR, WORK, IWORK, INFO )
1569         USE LA_PRECISION, ONLY: WP => DP
1570         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1571         INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, N, NRHS
1572         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
1573         REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
1574         REAL(WP), INTENT(IN) :: A( LDA,*), AF( LDAF,*), B( LDB,*)
1575         REAL(WP), INTENT(INOUT) :: X( LDX,*)
1576         REAL(WP), INTENT(OUT) :: WORK(*)
1577      END SUBROUTINE DPORFS
1578
1579      MODULE PROCEDURE DPORFS1
1580
1581      END INTERFACE
1582
1583      INTERFACE LA_POTRS
1584
1585      SUBROUTINE DPOTRS( UPLO, N, NRHS, A, LDA, B, LDB, INFO )
1586         USE LA_PRECISION, ONLY: WP => DP
1587         CHARACTER(LEN=1), INTENT(IN) :: UPLO
1588         INTEGER, INTENT(IN) :: LDA, LDB, N, NRHS
1589         INTEGER, INTENT(OUT) :: INFO
1590         REAL(WP), INTENT(IN) :: A( LDA,*)
1591         REAL(WP), INTENT(INOUT) :: B( LDB,*)
1592      END SUBROUTINE DPOTRS
1593
1594      MODULE PROCEDURE DPOTRS1
1595
1596      END INTERFACE
1597
1598      INTERFACE LA_GTRFS
1599
1600      SUBROUTINE DGTRFS( TRANS, N, NRHS, DL, D, DU, DLF, DF, DUF, DU2,  &
1601     &                   IPIV, B, LDB, X, LDX, FERR, BERR, WORK, IWORK, &
1602     &                   INFO )
1603         USE LA_PRECISION, ONLY: WP => DP
1604         CHARACTER(LEN=1), INTENT(IN) :: TRANS
1605         INTEGER, INTENT(IN) :: LDB, LDX, N, NRHS, IPIV(*)
1606         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
1607         REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
1608         REAL(WP), INTENT(IN) :: B( LDB,*), D(*), DF(*), DL(*), DLF(*), &
1609     &                           DU(*), DU2(*), DUF(*)
1610         REAL(WP), INTENT(INOUT) :: X( LDX,*)
1611         REAL(WP), INTENT(OUT) :: WORK(*)
1612      END SUBROUTINE DGTRFS
1613
1614      MODULE PROCEDURE DGTRFS1
1615
1616      END INTERFACE
1617
1618      INTERFACE LA_GTCON
1619
1620      SUBROUTINE DGTCON( NORM, N, DL, D, DU, DU2, IPIV, ANORM, RCOND,   &
1621     &                   WORK, IWORK, INFO )
1622         USE LA_PRECISION, ONLY: WP => DP
1623         CHARACTER(LEN=1), INTENT(IN) :: NORM
1624         INTEGER, INTENT(IN) :: N
1625         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
1626         REAL(WP), INTENT(IN) :: ANORM
1627         REAL(WP), INTENT(OUT) :: RCOND
1628         INTEGER, INTENT(IN) :: IPIV(*)
1629         REAL(WP), INTENT(IN) :: D(*), DL(*), DU(*), DU2(*)
1630         REAL(WP), INTENT(OUT) :: WORK(*)
1631      END SUBROUTINE DGTCON
1632
1633      END INTERFACE
1634
1635      INTERFACE LA_GTTRS
1636
1637      SUBROUTINE DGTTRS( TRANS, N, NRHS, DL, D, DU, DU2, IPIV, B, LDB,  &
1638     &                   INFO )
1639         USE LA_PRECISION, ONLY: WP => DP
1640         CHARACTER(LEN=1), INTENT(IN) :: TRANS
1641         INTEGER, INTENT(IN) :: LDB, N, NRHS
1642         INTEGER, INTENT(OUT) :: INFO
1643         INTEGER, INTENT(IN) :: IPIV(*)
1644         REAL(WP), INTENT(IN) :: D(*), DL(*), DU(*), DU2(*)
1645         REAL(WP), INTENT(INOUT) :: B( LDB,*)
1646      END SUBROUTINE DGTTRS
1647
1648      MODULE PROCEDURE DGTTRS1
1649
1650      END INTERFACE
1651
1652      INTERFACE LA_GTTRF
1653
1654      SUBROUTINE DGTTRF( N, DL, D, DU, DU2, IPIV, INFO )
1655         USE LA_PRECISION, ONLY: WP => DP
1656         INTEGER, INTENT(IN) :: N
1657         INTEGER, INTENT(OUT) :: INFO
1658         INTEGER, INTENT(OUT) :: IPIV(*)
1659         REAL(WP), INTENT(INOUT) :: D(*), DL(*), DU(*)
1660         REAL(WP), INTENT(OUT) :: DU2(*)
1661      END SUBROUTINE DGTTRF
1662
1663      END INTERFACE
1664
1665      INTERFACE LA_GBEQU
1666
1667      SUBROUTINE DGBEQU( M, N, KL, KU, AB, LDAB, R, C, ROWCND, COLCND,  &
1668     &                   AMAX, INFO )
1669         USE LA_PRECISION, ONLY: WP => DP
1670         INTEGER, INTENT(IN) :: KL, KU, LDAB, M, N
1671         INTEGER, INTENT(OUT) :: INFO
1672         REAL(WP), INTENT(OUT) :: AMAX, COLCND, ROWCND
1673         REAL(WP), INTENT(OUT) :: C(*), R(*)
1674         REAL(WP), INTENT(IN) :: AB( LDAB,*)
1675      END SUBROUTINE DGBEQU
1676
1677      END INTERFACE
1678
1679      INTERFACE LA_GBRFS
1680
1681      SUBROUTINE DGBRFS( TRANS, N, KL, KU, NRHS, AB, LDAB, AFB, LDAFB,  &
1682     &                   IPIV, B, LDB, X, LDX, FERR, BERR, WORK, IWORK, &
1683     &                   INFO )
1684         USE LA_PRECISION, ONLY: WP => DP
1685         CHARACTER(LEN=1), INTENT(IN) :: TRANS
1686         INTEGER, INTENT(IN) :: KL, KU, LDAB, LDAFB, LDB, LDX, N, NRHS
1687         INTEGER, INTENT(OUT) :: INFO
1688         INTEGER, INTENT(IN) :: IPIV(*)
1689         INTEGER, INTENT(OUT) :: IWORK(*)
1690         REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
1691         REAL(WP), INTENT(IN) :: AB( LDAB,*), AFB( LDAFB,*), B( LDB,*)
1692         REAL(WP), INTENT(OUT) :: WORK(*)
1693         REAL(WP), INTENT(INOUT) :: X( LDX,*)
1694      END SUBROUTINE DGBRFS
1695
1696      MODULE PROCEDURE DGBRFS1
1697      END INTERFACE
1698
1699      INTERFACE LA_GBCON
1700
1701      SUBROUTINE DGBCON( NORM, N, KL, KU, AB, LDAB, IPIV, ANORM, RCOND, &
1702     &                   WORK, IWORK, INFO )
1703         USE LA_PRECISION, ONLY: WP => DP
1704         CHARACTER(LEN=1), INTENT(IN) :: NORM
1705         INTEGER, INTENT(IN) :: KL, KU, LDAB, N
1706         INTEGER, INTENT(OUT) :: INFO
1707         REAL(WP), INTENT(IN) :: ANORM
1708         REAL(WP), INTENT(OUT) :: RCOND
1709         INTEGER, INTENT(IN) :: IPIV( * )
1710         INTEGER, INTENT(OUT) :: IWORK( * )
1711         REAL(WP), INTENT(IN) :: AB( LDAB, * )
1712         REAL(WP), INTENT(OUT) :: WORK( * )
1713      END SUBROUTINE DGBCON
1714
1715      END INTERFACE
1716
1717      INTERFACE LA_GBTRS
1718
1719      SUBROUTINE DGBTRS( TRANS, N, KL, KU, NRHS, AB, LDAB, IPIV, B, LDB,&
1720     &                   INFO )
1721         USE LA_PRECISION, ONLY: WP => DP
1722         CHARACTER(LEN=1), INTENT(IN) :: TRANS
1723         INTEGER, INTENT(IN) :: KL, KU, LDAB, LDB, N, NRHS
1724         INTEGER, INTENT(OUT) :: INFO
1725         INTEGER, INTENT(IN) :: IPIV(*)
1726         REAL(WP), INTENT(IN) :: AB( LDAB,*)
1727         REAL(WP), INTENT(INOUT) :: B(LDB,*)
1728      END SUBROUTINE DGBTRS
1729
1730      MODULE PROCEDURE DGBTRS1
1731      END INTERFACE
1732
1733      INTERFACE LA_GBTRF
1734
1735      SUBROUTINE DGBTRF( M, N, KL, KU, AB, LDAB, IPIV, INFO )
1736         USE LA_PRECISION, ONLY: WP => DP
1737         INTEGER, INTENT(IN) :: KL, KU, LDAB, M, N
1738         INTEGER, INTENT(OUT) :: INFO
1739         INTEGER, INTENT(INOUT) :: IPIV(*)
1740         REAL(WP), INTENT(INOUT) :: AB(LDAB,*)
1741      END SUBROUTINE DGBTRF
1742
1743      END INTERFACE
1744
1745      INTERFACE
1746
1747      FUNCTION DLAMCH( CMACH )
1748         USE LA_PRECISION, ONLY: WP => DP
1749         REAL(WP) :: DLAMCH
1750         CHARACTER(LEN=1), INTENT(IN) :: CMACH
1751      END FUNCTION DLAMCH
1752
1753      END INTERFACE
1754
1755      INTERFACE LA_GGSVD
1756
1757       SUBROUTINE DGGSVD( JOBU, JOBV, JOBQ, M, N, P, K, L, A, LDA, B,   &
1758     &                    LDB, ALPHA, BETA, U, LDU, V, LDV, Q, LDQ,     &
1759     &                    WORK, IWORK, INFO )
1760         USE LA_PRECISION, ONLY: WP => DP
1761         CHARACTER(LEN=1), INTENT(IN) :: JOBU, JOBV, JOBQ
1762         INTEGER, INTENT(IN) :: M, N, P, LDA, LDB, LDU, LDV, LDQ
1763         INTEGER, INTENT(OUT) :: INFO, K, L, IWORK(*)
1764         REAL(WP), INTENT(OUT) :: ALPHA(*), BETA(*)
1765         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
1766         REAL(WP), INTENT(OUT) :: U(LDU,*), V(LDV,*), Q(LDQ,*), WORK(*)
1767      END SUBROUTINE DGGSVD
1768
1769       END INTERFACE
1770
1771      INTERFACE LA_GEGV
1772
1773       SUBROUTINE DGEGV( JOBVL, JOBVR, N, A, LDA, B, LDB, ALPHAR,       &
1774     &                   ALPHAI, BETA, VL, LDVL, VR, LDVR, WORK, LWORK, &
1775     &                   INFO )
1776         USE LA_PRECISION, ONLY: WP => DP
1777         CHARACTER(LEN=1), INTENT(IN) :: JOBVL, JOBVR
1778         INTEGER, INTENT(IN) :: LDA, LDB, N, LDVL, LDVR, LWORK
1779         INTEGER, INTENT(OUT) :: INFO
1780         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
1781         REAL(WP), INTENT(OUT) :: ALPHAR(*), ALPHAI(*), BETA(*),        &
1782     &                            VL(LDVL,*), VR(LDVR,*), WORK(*)
1783      END SUBROUTINE DGEGV
1784
1785       END INTERFACE
1786
1787      INTERFACE LA_GEGS
1788
1789       SUBROUTINE DGEGS( JOBVSL, JOBVSR, N, A, LDA, B, LDB, ALPHAR,     &
1790     &                   ALPHAI, BETA, VSL, LDVSL, VSR, LDVSR, WORK,    &
1791     &                   LWORK, INFO )
1792         USE LA_PRECISION, ONLY: WP => DP
1793         CHARACTER(LEN=1), INTENT(IN) :: JOBVSL, JOBVSR
1794         INTEGER, INTENT(IN) :: LDA, LDB, N, LDVSL, LDVSR, LWORK
1795         INTEGER, INTENT(OUT) :: INFO
1796         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
1797         REAL(WP), INTENT(OUT) :: ALPHAR(*), ALPHAI(*), BETA(*),        &
1798     &                            VSL(LDVSL,*), VSR(LDVSR,*), WORK(*)
1799      END SUBROUTINE DGEGS
1800
1801       END INTERFACE
1802
1803        INTERFACE LA_SBGVX
1804
1805
1806       SUBROUTINE DSBGVX( JOBZ, RANGE, UPLO, N, KAB, KBB, AB, LDAB, BB, &
1807     &                    LDBB, Q, LDQ, VL, VU, IL, IU, ABSTOL, M, W, Z,&
1808     &                    LDZ, WORK, IWORK, IFAIL, INFO )
1809         USE LA_PRECISION, ONLY: WP => DP
1810         CHARACTER(LEN=1), INTENT(IN) :: JOBZ, RANGE, UPLO
1811         INTEGER, INTENT(IN) :: N, IL, IU, KAB, KBB, LDAB, LDBB, LDQ, LDZ
1812         INTEGER, INTENT(OUT) :: M
1813         REAL(WP), INTENT(IN) ::  ABSTOL, VL, VU
1814         INTEGER, INTENT(OUT) ::  IWORK(*)
1815         INTEGER, INTENT(OUT) :: INFO
1816         REAL(WP), INTENT(INOUT) :: AB(LDAB,*), BB(LDBB,*)
1817         REAL(WP), INTENT(OUT) :: WORK(*), Q(LDQ,*), Z(LDZ,*)
1818         REAL(WP), INTENT(OUT) :: W(*)
1819         INTEGER, INTENT(IN) :: IFAIL(*)
1820        END SUBROUTINE DSBGVX
1821
1822        END INTERFACE
1823
1824
1825        INTERFACE LA_SBGVD
1826
1827
1828        SUBROUTINE DSBGVD( JOBZ, UPLO, N, KAB, KBB, AB, LDAB, BB, LDBB, &
1829     &                     W, Z, LDZ, WORK, LWORK, IWORK, LIWORK,       &
1830     &                     INFO )
1831           USE LA_PRECISION, ONLY: WP => DP
1832           CHARACTER(LEN=1), INTENT(IN) :: JOBZ, UPLO
1833           INTEGER, INTENT(IN) :: N, KAB, KBB, LDAB, LDBB, LDZ
1834           INTEGER, INTENT(IN) :: LWORK, LIWORK
1835           INTEGER, INTENT(OUT) :: INFO, IWORK(*)
1836           REAL(WP), INTENT(INOUT) :: AB(LDAB,*), BB(LDBB,*)
1837           REAL(WP), INTENT(OUT) :: W(*)
1838           REAL(WP), INTENT(OUT) :: Z(LDZ,*), WORK(*)
1839	 END SUBROUTINE DSBGVD
1840
1841         END INTERFACE
1842
1843
1844      INTERFACE LA_SBGV
1845
1846       SUBROUTINE DSBGV( JOBZ, UPLO, N, KA, KB, AB, LDAB, BB, LDBB, W,  &
1847     &                   Z, LDZ, WORK, INFO )
1848         USE LA_PRECISION, ONLY: WP => DP
1849         CHARACTER(LEN=1), INTENT(IN) :: JOBZ, UPLO
1850         INTEGER, INTENT(IN) :: KA, KB, LDAB, LDBB, N, LDZ
1851         INTEGER, INTENT(OUT) :: INFO
1852         REAL(WP), INTENT(OUT) :: W(*)
1853         REAL(WP), INTENT(INOUT) :: AB(LDAB,*), BB(LDBB,*)
1854         REAL(WP), INTENT(OUT) :: Z(LDZ,*), WORK(*)
1855      END SUBROUTINE DSBGV
1856
1857       END INTERFACE
1858
1859
1860       INTERFACE LA_SPGVX
1861
1862
1863       SUBROUTINE DSPGVX( ITYPE, JOBZ, RANGE, UPLO, N, AP, BP, VL, VU,  &
1864     &                    IL, IU, ABSTOL, M, W, Z, LDZ, WORK, IWORK,    &
1865     &                    IFAIL, INFO )
1866         USE LA_PRECISION, ONLY: WP => DP
1867         CHARACTER(LEN=1), INTENT(IN) :: JOBZ, RANGE, UPLO
1868         INTEGER, INTENT(IN) :: ITYPE, N, IL, IU, LDZ
1869         INTEGER, INTENT(OUT) :: M
1870         REAL(WP), INTENT(IN) ::  ABSTOL, VL, VU
1871         INTEGER, INTENT(OUT) ::  IWORK(*)
1872         INTEGER, INTENT(OUT) :: INFO
1873         REAL(WP), INTENT(INOUT) :: AP(*), BP(*)
1874         REAL(WP), INTENT(OUT) :: WORK(*), Z(LDZ,*)
1875         REAL(WP), INTENT(OUT) :: W(*)
1876         INTEGER, INTENT(IN) :: IFAIL(*)
1877        END SUBROUTINE DSPGVX
1878
1879        END INTERFACE
1880
1881
1882       INTERFACE LA_SPGVD
1883
1884
1885        SUBROUTINE DSPGVD( ITYPE, JOBZ, UPLO, N, AP, BP, W, Z, LDZ,     &
1886     &                     WORK, LWORK, IWORK, LIWORK, INFO )
1887        USE LA_PRECISION, ONLY: WP => DP
1888        CHARACTER(LEN=1), INTENT(IN) :: JOBZ, UPLO
1889        INTEGER, INTENT(IN) :: ITYPE, N, LDZ
1890        INTEGER, INTENT(IN) :: LWORK, LIWORK
1891        INTEGER, INTENT(OUT) :: INFO, IWORK(*)
1892        REAL(WP), INTENT(INOUT) :: AP(*), BP(*)
1893        REAL(WP), INTENT(OUT) :: W(*)
1894        REAL(WP), INTENT(OUT) :: Z(LDZ,*), WORK(*)
1895       END SUBROUTINE DSPGVD
1896
1897        END INTERFACE
1898
1899
1900      INTERFACE LA_SPGV
1901
1902       SUBROUTINE DSPGV( ITYPE, JOBZ, UPLO, N, AP, BP, W, Z, LDZ, WORK, &
1903     &                   INFO )
1904         USE LA_PRECISION, ONLY: WP => DP
1905         CHARACTER(LEN=1), INTENT(IN) :: JOBZ, UPLO
1906         INTEGER, INTENT(IN) :: ITYPE, N, LDZ
1907         INTEGER, INTENT(OUT) :: INFO
1908         REAL(WP), INTENT(OUT) :: W(*)
1909         REAL(WP), INTENT(INOUT) :: AP(*), BP(*)
1910         REAL(WP), INTENT(OUT) :: Z(LDZ,*), WORK(*)
1911      END SUBROUTINE DSPGV
1912
1913       END INTERFACE
1914
1915
1916      INTERFACE LA_GESVD
1917
1918       SUBROUTINE DGESVD( JOBU, JOBVT, M, N, A, LDA, S, U, LDU, VT,     &
1919     &                    LDVT, WORK, LWORK, INFO )
1920         USE LA_PRECISION, ONLY: WP => DP
1921         CHARACTER(LEN=1), INTENT(IN) :: JOBU, JOBVT
1922         INTEGER, INTENT(IN) :: M, N, LDA, LDU, LDVT, LWORK
1923         INTEGER, INTENT(OUT) :: INFO
1924         REAL(WP), INTENT(OUT) :: S(*)
1925         REAL(WP), INTENT(INOUT) :: A(LDA,*)
1926         REAL(WP), INTENT(OUT) :: U(LDU,*), VT(LDVT,*), WORK(*)
1927      END SUBROUTINE DGESVD
1928
1929       END INTERFACE
1930
1931      INTERFACE LA_GEEVX
1932
1933       SUBROUTINE DGEEVX( BALANC, JOBVL, JOBVR, SENSE, N, A, LDA, WR,   &
1934     &                    WI, VL, LDVL, VR, LDVR, ILO, IHI, SCALE,      &
1935     &                    ABNRM, RCONDE, RCONDV, WORK, LWORK, IWORK,    &
1936     &                    INFO )
1937         USE LA_PRECISION, ONLY: WP => DP
1938         CHARACTER(LEN=1), INTENT(IN) :: BALANC, JOBVL, JOBVR, SENSE
1939         INTEGER, INTENT(IN) :: N, LDA, LDVL, LDVR, LWORK
1940         INTEGER, INTENT(OUT) :: INFO, ILO, IHI, IWORK(*)
1941         REAL(WP), INTENT(OUT) :: ABNRM
1942         REAL(WP), INTENT(OUT) :: SCALE(*), RCONDE(*), RCONDV(*)
1943         REAL(WP), INTENT(INOUT) :: A(LDA,*)
1944         REAL(WP), INTENT(OUT) :: VL(LDVL,*), VR(LDVR,*), WR(*), WI(*), &
1945     &                            WORK(*)
1946      END SUBROUTINE DGEEVX
1947
1948       END INTERFACE
1949
1950        INTERFACE LA_GGEVX
1951
1952       SUBROUTINE DGGEVX( BALANC, JOBVL, JOBVR, SENSE, N, A, LDA, B,    &
1953     &                    LDB, ALPHAR, ALPHAI, BETA, VL, LDVL, VR, LDVR,&
1954     &                    ILO, IHI, LSCALE, RSCALE, ABNRM, BBNRM,       &
1955     &                    RCONDE, RCONDV, WORK, LWORK, IWORK, BWORK,    &
1956     &                    INFO )
1957         USE LA_PRECISION, ONLY: WP => DP
1958         CHARACTER(LEN=1), INTENT(IN) :: BALANC, JOBVL, JOBVR, SENSE
1959         INTEGER, INTENT(IN) :: LDA, LDB, N, LDVL, LDVR, LWORK
1960         INTEGER, INTENT(OUT) :: INFO
1961         INTEGER, INTENT(OUT):: ILO, IHI
1962         REAL(WP), INTENT(OUT) :: ABNRM, BBNRM
1963         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
1964         REAL(WP), INTENT(OUT) :: ALPHAR(*), ALPHAI(*), BETA(*),        &
1965     &                            VL(LDVL,*), VR(LDVR,*), WORK(*),      &
1966     &                            LSCALE(*), RSCALE(*), RCONDE(*),      &
1967     &                            RCONDV(*)
1968         INTEGER :: IWORK(*)
1969         LOGICAL :: BWORK(*)
1970        END SUBROUTINE DGGEVX
1971
1972        END INTERFACE
1973
1974        INTERFACE LA_GGEV
1975
1976       SUBROUTINE DGGEV( JOBVL, JOBVR, N, A, LDA, B, LDB, ALPHAR,       &
1977     &                   ALPHAI, BETA, VL, LDVL, VR, LDVR, WORK, LWORK, &
1978     &                   INFO )
1979         USE LA_PRECISION, ONLY: WP => DP
1980         CHARACTER(LEN=1), INTENT(IN) :: JOBVL, JOBVR
1981         INTEGER, INTENT(IN) :: LDA, LDB, N, LDVL, LDVR, LWORK
1982         INTEGER, INTENT(OUT) :: INFO
1983         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
1984         REAL(WP), INTENT(OUT) :: ALPHAR(*), ALPHAI(*), BETA(*),        &
1985     &                            VL(LDVL,*), VR(LDVR,*), WORK(*)
1986       END SUBROUTINE DGGEV
1987
1988       END INTERFACE
1989
1990      INTERFACE LA_GEEV
1991
1992       SUBROUTINE DGEEV( JOBVL, JOBVR, N, A, LDA, WR, WI, VL, LDVL, VR, &
1993     &                   LDVR, WORK, LWORK, INFO )
1994         USE LA_PRECISION, ONLY: WP => DP
1995         CHARACTER(LEN=1), INTENT(IN) :: JOBVL, JOBVR
1996         INTEGER, INTENT(IN) :: N, LDA, LDVL, LDVR, LWORK
1997         INTEGER, INTENT(OUT) :: INFO
1998         REAL(WP), INTENT(INOUT) :: A(LDA,*)
1999         REAL(WP), INTENT(OUT) :: VL(LDVL,*), VR(LDVR,*), WR(*), WI(*), &
2000     &                            WORK(*)
2001      END SUBROUTINE DGEEV
2002
2003       END INTERFACE
2004
2005      INTERFACE LA_GEESX
2006
2007       SUBROUTINE DGEESX( JOBVS, SORT, SELECT, SENSE, N, A, LDA, SDIM,  &
2008     &                    WR, WI, VS, LDVS, RCONDE, RCONDV, WORK, LWORK,&
2009     &                    IWORK, LIWORK, BWORK, INFO )
2010         USE LA_PRECISION, ONLY: WP => DP
2011         INTERFACE
2012            LOGICAL FUNCTION SELECT(WR, WI)
2013               USE LA_PRECISION, ONLY: WP => DP
2014               REAL(WP), INTENT(IN) :: WR, WI
2015            END FUNCTION SELECT
2016         END INTERFACE
2017         CHARACTER(LEN=1), INTENT(IN) :: JOBVS, SORT, SENSE
2018         INTEGER, INTENT(IN) :: N, LDA, LDVS, LWORK, LIWORK
2019         INTEGER, INTENT(OUT) :: INFO, SDIM, IWORK(*)
2020         LOGICAL, INTENT(OUT) :: BWORK(*)
2021         REAL(WP), INTENT(INOUT) :: A(LDA,*)
2022         REAL(WP), INTENT(OUT) :: RCONDV, RCONDE
2023         REAL(WP), INTENT(OUT) :: VS(LDVS,*), WR(*), WI(*), WORK(*)
2024         OPTIONAL :: SELECT
2025      END SUBROUTINE DGEESX
2026
2027       END INTERFACE
2028
2029       INTERFACE LA_GGESX
2030
2031       SUBROUTINE DGGESX( JOBVSL, JOBVSR, SORT, DELCTG, SENSE, N, A,    &
2032     &                    LDA, B, LDB, SDIM, ALPHAR, ALPHAI, BETA, VSL, &
2033     &                    LDVSL, VSR, LDVSR, RCONDE, RCONDV, WORK,      &
2034     &                    LWORK, IWORK, LIWORK, BWORK, INFO )
2035          USE LA_PRECISION, ONLY: WP => DP
2036          CHARACTER(LEN=1), INTENT(IN) :: JOBVSL, JOBVSR, SORT, SENSE
2037          INTEGER, INTENT(IN) :: LDA, LDB, N, LDVSL, LDVSR, LWORK, LIWORK
2038          INTEGER, INTENT(INOUT) :: INFO
2039          INTEGER, INTENT(OUT) :: SDIM
2040          REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
2041         REAL(WP), INTENT(OUT) :: ALPHAR(*), ALPHAI(*), BETA(*),        &
2042     &                            VSL(LDVSL,*), VSR(LDVSR,*), WORK(*)
2043          REAL(WP), INTENT(OUT) :: RCONDE(2), RCONDV(2)
2044          LOGICAL :: BWORK(*)
2045          INTEGER :: IWORK (*)
2046          INTERFACE
2047           LOGICAL FUNCTION DELCTG(ALPHAR, ALPHAI, BETA)
2048              USE LA_PRECISION, ONLY: WP => DP
2049              REAL(WP), INTENT(IN) :: ALPHAR, ALPHAI, BETA
2050           END FUNCTION DELCTG
2051          END INTERFACE
2052          OPTIONAL :: DELCTG
2053         END SUBROUTINE DGGESX
2054
2055      END INTERFACE
2056
2057
2058      INTERFACE LA_GGES
2059
2060       SUBROUTINE DGGES( JOBVSL, JOBVSR, SORT, DELCTG, N, A, LDA, B,    &
2061     &                   LDB, SDIM, ALPHAR, ALPHAI, BETA, VSL, LDVSL,   &
2062     &                   VSR, LDVSR, WORK, LWORK, BWORK, INFO )
2063       USE LA_PRECISION, ONLY: WP => DP
2064       CHARACTER(LEN=1), INTENT(IN) :: JOBVSL, JOBVSR, SORT
2065       INTEGER, INTENT(IN) :: LDA, LDB, N, LDVSL, LDVSR, LWORK
2066       INTEGER, INTENT(INOUT) :: INFO
2067       INTEGER, INTENT(OUT) :: SDIM
2068       REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
2069         REAL(WP), INTENT(OUT) :: ALPHAR(*), ALPHAI(*), BETA(*),        &
2070     &                            VSL(LDVSL,*), VSR(LDVSR,*), WORK(*)
2071       LOGICAL :: BWORK(*)
2072       INTERFACE
2073         LOGICAL FUNCTION DELCTG(ALPHAR, ALPHAI, BETA)
2074          USE LA_PRECISION, ONLY: WP => DP
2075          REAL(WP), INTENT(IN) :: ALPHAR, ALPHAI, BETA
2076         END FUNCTION DELCTG
2077       END INTERFACE
2078       OPTIONAL :: DELCTG
2079      END SUBROUTINE DGGES
2080
2081        END INTERFACE
2082
2083      INTERFACE LA_GEES
2084
2085       SUBROUTINE DGEES( JOBVS, SORT, SELECT, N, A, LDA, SDIM, WR, WI,  &
2086     &                   VS, LDVS, WORK, LWORK, BWORK, INFO )
2087         USE LA_PRECISION, ONLY: WP => DP
2088         INTERFACE
2089            LOGICAL FUNCTION SELECT(WR, WI)
2090               USE LA_PRECISION, ONLY: WP => DP
2091               REAL(WP), INTENT(IN) :: WR, WI
2092            END FUNCTION SELECT
2093         END INTERFACE
2094         CHARACTER(LEN=1), INTENT(IN) :: JOBVS, SORT
2095         INTEGER, INTENT(IN) :: N, LDA, LDVS, LWORK
2096         INTEGER, INTENT(OUT) :: INFO, SDIM
2097         LOGICAL, INTENT(OUT) :: BWORK(*)
2098         REAL(WP), INTENT(INOUT) :: A(LDA,*)
2099         REAL(WP), INTENT(OUT) :: VS(LDVS,*), WR(*), WI(*), WORK(*)
2100         OPTIONAL :: SELECT
2101      END SUBROUTINE DGEES
2102
2103       END INTERFACE
2104
2105        INTERFACE LA_STEVR
2106
2107       SUBROUTINE DSTEVR( JOBZ, RANGE, N, D, E, VL, VU, IL, IU, ABSTOL, &
2108     &                    M, W, Z, LDZ, ISUPPZ, WORK, LWORK, IWORK,     &
2109     &                    LIWORK, INFO )
2110         USE LA_PRECISION, ONLY: WP => DP
2111         CHARACTER(LEN=1), INTENT(IN) :: JOBZ, RANGE
2112         INTEGER, INTENT(IN) :: N, IL, IU, LDZ,  LWORK, LIWORK
2113         INTEGER, INTENT(OUT) :: M
2114         INTEGER, INTENT(OUT), TARGET :: ISUPPZ(*)
2115         REAL(WP), INTENT(IN) :: ABSTOL, VL, VU
2116         INTEGER, INTENT(OUT) ::  IWORK(*)
2117         INTEGER, INTENT(OUT) :: INFO
2118         REAL(WP), INTENT(INOUT) :: D(*), E(*)
2119         REAL(WP), INTENT(OUT) :: WORK(*), W(*)
2120         REAL(WP), INTENT(OUT), TARGET :: Z(LDZ,*)
2121       END SUBROUTINE DSTEVR
2122
2123       END INTERFACE
2124
2125      INTERFACE LA_STEVX
2126
2127       SUBROUTINE DSTEVX( JOBZ, RANGE, N, D, E, VL, VU, IL, IU, ABSTOL, &
2128     &                    M, W, Z, LDZ, WORK, IWORK, IFAIL, INFO )
2129         USE LA_PRECISION, ONLY: WP => DP
2130         CHARACTER(LEN=1), INTENT(IN) :: JOBZ, RANGE
2131         INTEGER, INTENT(IN) :: LDZ, N, IL, IU
2132         INTEGER, INTENT(OUT) :: INFO, IWORK(*), M, IFAIL(*)
2133         REAL(WP), INTENT(IN) :: VL, VU, ABSTOL
2134         REAL(WP), INTENT(INOUT) :: D(*), E(*)
2135         REAL(WP), INTENT(OUT) :: W(*), Z(LDZ,*), WORK(*)
2136      END SUBROUTINE DSTEVX
2137
2138       END INTERFACE
2139
2140      INTERFACE LA_STEVD
2141
2142       SUBROUTINE DSTEVD( JOBZ, N, D, E, Z, LDZ, WORK, LWORK, IWORK,    &
2143     &                    LIWORK, INFO )
2144         USE LA_PRECISION, ONLY: WP => DP
2145         CHARACTER(LEN=1), INTENT(IN) :: JOBZ
2146         INTEGER, INTENT(IN) :: LDZ, N, LWORK, LIWORK
2147         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
2148         REAL(WP), INTENT(INOUT) :: D(*), E(*)
2149         REAL(WP), INTENT(OUT) :: Z(LDZ,*), WORK(*)
2150      END SUBROUTINE DSTEVD
2151
2152       END INTERFACE
2153
2154      INTERFACE LA_STEV
2155
2156       SUBROUTINE DSTEV( JOBZ, N, D, E, Z, LDZ, WORK, INFO )
2157         USE LA_PRECISION, ONLY: WP => DP
2158         CHARACTER(LEN=1), INTENT(IN) :: JOBZ
2159         INTEGER, INTENT(IN) :: LDZ, N
2160         INTEGER, INTENT(OUT) :: INFO
2161         REAL(WP), INTENT(INOUT) :: D(*), E(*)
2162         REAL(WP), INTENT(OUT) :: Z(LDZ,*), WORK(*)
2163      END SUBROUTINE DSTEV
2164
2165       END INTERFACE
2166
2167      INTERFACE LA_SBEVX
2168
2169       SUBROUTINE DSBEVX( JOBZ, RANGE, UPLO, N, KD, AB, LDAB, Q, LDQ,   &
2170     &                    VL, VU, IL, IU, ABSTOL, M, W, Z, LDZ, WORK,   &
2171     &                    IWORK, IFAIL, INFO )
2172         USE LA_PRECISION, ONLY: WP => DP
2173         CHARACTER(LEN=1), INTENT(IN) :: JOBZ, UPLO, RANGE
2174         INTEGER, INTENT(IN) :: LDZ, N, IL, IU, LDQ, KD, LDAB
2175         INTEGER, INTENT(OUT) :: INFO, IWORK(*), M, IFAIL(*)
2176         REAL(WP), INTENT(IN) :: VL, VU, ABSTOL
2177         REAL(WP), INTENT(INOUT) :: AB(LDAB,*)
2178         REAL(WP), INTENT(OUT) :: W(*)
2179         REAL(WP), INTENT(OUT) :: Q(LDQ,*), Z(LDZ,*), WORK(*)
2180      END SUBROUTINE DSBEVX
2181
2182       END INTERFACE
2183
2184
2185      INTERFACE LA_SBEVD
2186
2187       SUBROUTINE DSBEVD( JOBZ, UPLO, N, KD, AB, LDAB, W, Z, LDZ, WORK, &
2188     &                    LWORK, IWORK, LIWORK, INFO )
2189         USE LA_PRECISION, ONLY: WP => DP
2190         CHARACTER(LEN=1), INTENT(IN) :: JOBZ, UPLO
2191         INTEGER, INTENT(IN) :: N, KD, LDAB, LDZ, LWORK, LIWORK
2192         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
2193         REAL(WP), INTENT(INOUT) :: AB(LDAB,*)
2194         REAL(WP), INTENT(OUT) :: W(*)
2195         REAL(WP), INTENT(OUT) :: Z(LDZ,*), WORK(*)
2196      END SUBROUTINE DSBEVD
2197
2198       END INTERFACE
2199
2200
2201      INTERFACE LA_SBEV
2202
2203       SUBROUTINE DSBEV( JOBZ, UPLO, N, KD, AB, LDAB, W, Z, LDZ, WORK,  &
2204     &                   INFO )
2205         USE LA_PRECISION, ONLY: WP => DP
2206         CHARACTER(LEN=1), INTENT(IN) :: JOBZ, UPLO
2207         INTEGER, INTENT(IN) :: N, KD, LDAB, LDZ
2208         INTEGER, INTENT(OUT) :: INFO
2209         REAL(WP), INTENT(INOUT) :: AB(LDAB,*)
2210         REAL(WP), INTENT(OUT) :: W(*), Z(LDZ,*), WORK(*)
2211      END SUBROUTINE DSBEV
2212
2213       END INTERFACE
2214
2215
2216      INTERFACE LA_SPEVX
2217
2218       SUBROUTINE DSPEVX( JOBZ, RANGE, UPLO, N, AP, VL, VU, IL, IU,     &
2219     &                    ABSTOL, M, W, Z, LDZ, WORK, IWORK, IFAIL,     &
2220     &                    INFO )
2221         USE LA_PRECISION, ONLY: WP => DP
2222         CHARACTER(LEN=1), INTENT(IN) :: JOBZ, UPLO, RANGE
2223         INTEGER, INTENT(IN) :: LDZ, N, IL, IU
2224         INTEGER, INTENT(OUT) :: INFO, IWORK(*), M, IFAIL(*)
2225         REAL(WP), INTENT(IN) :: VL, VU, ABSTOL
2226         REAL(WP), INTENT(INOUT) :: AP(*)
2227         REAL(WP), INTENT(OUT) :: W(*), Z(LDZ,*), WORK(*)
2228      END SUBROUTINE DSPEVX
2229
2230       END INTERFACE
2231
2232
2233      INTERFACE LA_SPEVD
2234
2235       SUBROUTINE DSPEVD( JOBZ, UPLO, N, AP, W, Z, LDZ, WORK, LWORK,    &
2236     &                    IWORK, LIWORK, INFO )
2237         USE LA_PRECISION, ONLY: WP => DP
2238         CHARACTER(LEN=1), INTENT(IN) :: JOBZ, UPLO
2239         INTEGER, INTENT(IN) :: LDZ, N, LWORK, LIWORK
2240         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
2241         REAL(WP), INTENT(INOUT) :: AP(*)
2242         REAL(WP), INTENT(OUT) :: W(*), Z(LDZ,*), WORK(*)
2243      END SUBROUTINE DSPEVD
2244
2245       END INTERFACE
2246
2247
2248      INTERFACE LA_SPEV
2249
2250       SUBROUTINE DSPEV( JOBZ, UPLO, N, AP, W, Z, LDZ, WORK, INFO )
2251         USE LA_PRECISION, ONLY: WP => DP
2252         CHARACTER(LEN=1), INTENT(IN) :: JOBZ, UPLO
2253         INTEGER, INTENT(IN) :: LDZ, N
2254         INTEGER, INTENT(OUT) :: INFO
2255         REAL(WP), INTENT(INOUT) :: AP(*)
2256         REAL(WP), INTENT(OUT) :: W(*), Z(LDZ,*), WORK(*)
2257      END SUBROUTINE DSPEV
2258
2259       END INTERFACE
2260
2261
2262      INTERFACE LA_GGGLM
2263
2264       SUBROUTINE DGGGLM( N, M, P, A, LDA, B, LDB, D, X, Y, WORK, LWORK,&
2265     &                    INFO )
2266         USE LA_PRECISION, ONLY: WP => DP
2267         INTEGER, INTENT(IN) :: P, M, N, LDA, LDB, LWORK
2268         INTEGER, INTENT(OUT) :: INFO
2269         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*), D(*)
2270         REAL(WP), INTENT(OUT) :: WORK(*), X(*), Y(*)
2271      END SUBROUTINE DGGGLM
2272
2273       END INTERFACE
2274
2275      INTERFACE LA_GGLSE
2276
2277       SUBROUTINE DGGLSE( M, N, P, A, LDA, B, LDB, C, D, X, WORK, LWORK,&
2278     &                    INFO )
2279         USE LA_PRECISION, ONLY: WP => DP
2280         INTEGER, INTENT(IN) :: P, M, N, LDA, LDB, LWORK
2281         INTEGER, INTENT(OUT) :: INFO
2282         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*), C(*), D(*)
2283         REAL(WP), INTENT(OUT) :: WORK(*), X(*)
2284      END SUBROUTINE DGGLSE
2285
2286       END INTERFACE
2287
2288       INTERFACE LA_GELSY
2289
2290       SUBROUTINE DGELSY(  M, N, NRHS, A, LDA, B, LDB, JPVT, RCOND,     &
2291     &                     RANK, WORK, LWORK, INFO )
2292         USE LA_PRECISION, ONLY: WP => DP
2293         INTEGER, INTENT(IN) :: M, N, NRHS, LDA, LDB, LWORK
2294         INTEGER, INTENT(OUT) :: INFO, RANK
2295         INTEGER, INTENT(INOUT) :: JPVT(*)
2296         REAL(WP), INTENT(IN) :: RCOND
2297         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
2298         REAL(WP), INTENT(OUT) ::  WORK(*)
2299       END SUBROUTINE DGELSY
2300
2301        MODULE PROCEDURE DGELSY1
2302
2303        END INTERFACE
2304
2305        INTERFACE LA_GELSD
2306
2307       SUBROUTINE DGELSD(  M, N, NRHS, A, LDA, B, LDB, S, RCOND, RANK,  &
2308     &                     WORK, LWORK, IWORK, INFO )
2309          USE LA_PRECISION, ONLY: WP => DP
2310          INTEGER, INTENT(IN) :: NRHS, M, N, LDA, LDB, LWORK
2311          INTEGER, INTENT(OUT) :: INFO, RANK
2312          REAL(WP), INTENT(IN) :: RCOND
2313          REAL(WP), INTENT(INOUT) ::  A(LDA,*), B(LDB,*)
2314          REAL(WP), INTENT(OUT) :: S(*)
2315          REAL(WP), INTENT(OUT) :: WORK(*)
2316          INTEGER :: IWORK(*)
2317        END SUBROUTINE DGELSD
2318
2319          MODULE PROCEDURE DGELSD1
2320
2321       END INTERFACE
2322
2323      INTERFACE LA_GELSX
2324
2325       SUBROUTINE DGELSX( M, N, NRHS, A, LDA, B, LDB, JPVT, RCOND, RANK,&
2326     &                    WORK, INFO )
2327         USE LA_PRECISION, ONLY: WP => DP
2328         INTEGER, INTENT(IN) :: NRHS, M, N, LDA, LDB
2329         INTEGER, INTENT(OUT) :: INFO, RANK
2330         INTEGER, INTENT(INOUT) :: JPVT(*)
2331         REAL(WP), INTENT(IN) :: RCOND
2332         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
2333         REAL(WP), INTENT(OUT) :: WORK(*)
2334      END SUBROUTINE DGELSX
2335
2336      MODULE PROCEDURE DGELSX1
2337
2338       END INTERFACE
2339
2340      INTERFACE LA_GELSS
2341
2342       SUBROUTINE DGELSS( M, N, NRHS, A, LDA, B, LDB, S, RCOND, RANK,   &
2343     &                    WORK, LWORK, INFO )
2344         USE LA_PRECISION, ONLY: WP => DP
2345         INTEGER, INTENT(IN) :: NRHS, M, N, LDA, LDB, LWORK
2346         INTEGER, INTENT(OUT) :: INFO, RANK
2347         REAL(WP), INTENT(IN) :: RCOND
2348         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
2349         REAL(WP), INTENT(OUT) :: S(*)
2350         REAL(WP), INTENT(OUT) :: WORK(*)
2351      END SUBROUTINE DGELSS
2352
2353      MODULE PROCEDURE DGELSS1
2354
2355       END INTERFACE
2356
2357      INTERFACE LA_GELS
2358
2359       SUBROUTINE DGELS( TRANS, M, N, NRHS, A, LDA, B, LDB, WORK, LWORK,&
2360     &                   INFO )
2361         USE LA_PRECISION, ONLY: WP => DP
2362         CHARACTER(LEN=1), INTENT(IN) :: TRANS
2363         INTEGER, INTENT(IN) :: NRHS, M, N, LDA, LDB, LWORK
2364         INTEGER, INTENT(OUT) :: INFO
2365         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
2366         REAL(WP), INTENT(OUT) :: WORK(*)
2367      END SUBROUTINE DGELS
2368
2369      MODULE PROCEDURE DGELS1
2370
2371       END INTERFACE
2372
2373      INTERFACE LA_SPSV
2374
2375       SUBROUTINE DSPSV( UPLO, N, NRHS, AP, IPIV, B, LDB, INFO )
2376         USE LA_PRECISION, ONLY: WP => DP
2377         CHARACTER(LEN=1), INTENT(IN) :: UPLO
2378         INTEGER, INTENT(IN) :: NRHS, N, LDB
2379         INTEGER, INTENT(OUT) :: INFO
2380         INTEGER, INTENT(IN) :: IPIV(*)
2381         REAL(WP), INTENT(INOUT) :: AP(*), B(LDB,*)
2382      END SUBROUTINE DSPSV
2383
2384      MODULE PROCEDURE DSPSV1
2385
2386       END INTERFACE
2387
2388
2389      INTERFACE LA_SYSV
2390
2391       SUBROUTINE DSYSV( UPLO, N, NRHS, A, LDA, IPIV, B, LDB, WORK,     &
2392     &                   LWORK, INFO )
2393         USE LA_PRECISION, ONLY: WP => DP
2394         CHARACTER(LEN=1), INTENT(IN) :: UPLO
2395         INTEGER, INTENT(IN) :: NRHS, N, LDA, LDB, LWORK
2396         INTEGER, INTENT(OUT) :: INFO
2397         INTEGER, INTENT(IN) :: IPIV(*)
2398         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
2399         REAL(WP), INTENT(OUT) :: WORK(*)
2400      END SUBROUTINE DSYSV
2401
2402      MODULE PROCEDURE DSYSV1
2403
2404       END INTERFACE
2405
2406
2407      INTERFACE LA_PTSV
2408
2409       SUBROUTINE DPTSV( N, NRHS, D, E, B, LDB, INFO )
2410         USE LA_PRECISION, ONLY: WP => DP
2411         INTEGER, INTENT(IN) :: NRHS, N, LDB
2412         INTEGER, INTENT(OUT) :: INFO
2413         REAL(WP), INTENT(INOUT) :: D(*)
2414         REAL(WP), INTENT(INOUT) :: E(*), B(LDB,*)
2415      END SUBROUTINE DPTSV
2416
2417      MODULE PROCEDURE DPTSV1
2418
2419       END INTERFACE
2420
2421      INTERFACE LA_PBSV
2422
2423       SUBROUTINE DPBSV( UPLO, N, KD, NRHS, AB, LDAB, B, LDB, INFO )
2424         USE LA_PRECISION, ONLY: WP => DP
2425         CHARACTER(LEN=1), INTENT(IN) :: UPLO
2426         INTEGER, INTENT(IN) :: NRHS, N, LDB, KD, LDAB
2427         INTEGER, INTENT(OUT) :: INFO
2428         REAL(WP), INTENT(INOUT) :: AB(LDAB,*), B(LDB,*)
2429      END SUBROUTINE DPBSV
2430
2431      MODULE PROCEDURE DPBSV1
2432
2433       END INTERFACE
2434
2435      INTERFACE LA_PPSV
2436
2437       SUBROUTINE DPPSV( UPLO, N, NRHS, AP, B, LDB, INFO )
2438         USE LA_PRECISION, ONLY: WP => DP
2439         CHARACTER(LEN=1), INTENT(IN) :: UPLO
2440         INTEGER, INTENT(IN) :: NRHS, N, LDB
2441         INTEGER, INTENT(OUT) :: INFO
2442         REAL(WP), INTENT(INOUT) :: AP(*), B(LDB,*)
2443      END SUBROUTINE DPPSV
2444
2445      MODULE PROCEDURE DPPSV1
2446
2447       END INTERFACE
2448
2449      INTERFACE LA_POSV
2450
2451       SUBROUTINE DPOSV( UPLO, N, NRHS, A, LDA, B, LDB, INFO )
2452         USE LA_PRECISION, ONLY: WP => DP
2453         CHARACTER(LEN=1), INTENT(IN) :: UPLO
2454         INTEGER, INTENT(IN) :: NRHS, N, LDB, LDA
2455         INTEGER, INTENT(OUT) :: INFO
2456         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
2457      END SUBROUTINE DPOSV
2458
2459      MODULE PROCEDURE DPOSV1
2460
2461       END INTERFACE
2462
2463      INTERFACE LA_GTSV
2464
2465       SUBROUTINE DGTSV( N, NRHS, DL, D, DU, B, LDB, INFO )
2466         USE LA_PRECISION, ONLY: WP => DP
2467         INTEGER, INTENT(IN) :: NRHS, N, LDB
2468         INTEGER, INTENT(OUT) :: INFO
2469         REAL(WP), INTENT(INOUT) :: DL(*), D(*), DU(*), B(LDB,*)
2470      END SUBROUTINE DGTSV
2471
2472      MODULE PROCEDURE DGTSV1
2473
2474       END INTERFACE
2475
2476      INTERFACE LA_GBSV
2477
2478       SUBROUTINE DGBSV( N, KL, KU, NRHS, AB, LDAB, PIV, B, LDB, INFO )
2479         USE LA_PRECISION, ONLY: WP => DP
2480         INTEGER, INTENT(IN) :: KL, KU, LDAB, LDB, NRHS, N
2481         INTEGER, INTENT(OUT) :: INFO
2482         INTEGER, INTENT(OUT) :: PIV(*)
2483         REAL(WP), INTENT(INOUT) :: AB(LDAB,*), B(LDB,*)
2484      END SUBROUTINE DGBSV
2485
2486      MODULE PROCEDURE DGBSV1
2487
2488       END INTERFACE
2489
2490      INTERFACE LA_GESV
2491
2492       SUBROUTINE DGESV( N, NRHS, A, LDA, PIV, B, LDB, INFO )
2493         USE LA_PRECISION, ONLY: WP => DP
2494         INTEGER, INTENT(IN) :: LDA, LDB, NRHS, N
2495         INTEGER, INTENT(OUT) :: INFO
2496         INTEGER, INTENT(OUT) :: PIV(*)
2497         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
2498      END SUBROUTINE DGESV
2499
2500      MODULE PROCEDURE DGESV1
2501
2502       END INTERFACE
2503
2504      INTERFACE LA_SPSVX
2505
2506       SUBROUTINE DSPSVX( FACT, UPLO, N, NRHS, A, AF, IPIV, B, LDB, X,  &
2507     &                    LDX, RCOND, FERR, BERR, WORK, IWORK, INFO )
2508         USE LA_PRECISION, ONLY: WP => DP
2509         CHARACTER(LEN=1), INTENT(IN) :: UPLO, FACT
2510         INTEGER, INTENT(IN) :: LDB, LDX, NRHS, N
2511         INTEGER, INTENT(OUT) :: INFO
2512         INTEGER, INTENT(OUT) :: IWORK(*)
2513         INTEGER, INTENT(INOUT) :: IPIV(*)
2514         REAL(WP), INTENT(OUT) :: RCOND
2515         REAL(WP), INTENT(OUT) :: FERR(*), BERR(*)
2516         REAL(WP), INTENT(OUT) :: X(LDX,*), WORK(*)
2517         REAL(WP), INTENT(IN) :: A(*), B(LDB,*)
2518         REAL(WP), INTENT(INOUT) :: AF(*)
2519      END SUBROUTINE DSPSVX
2520
2521      MODULE PROCEDURE DSPSVX1
2522
2523       END INTERFACE
2524
2525
2526      INTERFACE LA_SYSVX
2527
2528       SUBROUTINE DSYSVX( FACT, UPLO, N, NRHS, A, LDA, AF, LDAF, IPIV,  &
2529     &                    B, LDB, X, LDX, RCOND, FERR, BERR, WORK,      &
2530     &                    LWORK, IWORK, INFO )
2531         USE LA_PRECISION, ONLY: WP => DP
2532         CHARACTER(LEN=1), INTENT(IN) :: UPLO, FACT
2533         INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, NRHS, N, LWORK
2534         INTEGER, INTENT(OUT) :: INFO
2535         INTEGER, INTENT(OUT) :: IWORK(*)
2536         INTEGER, INTENT(INOUT) :: IPIV(*)
2537         REAL(WP), INTENT(OUT) :: RCOND
2538         REAL(WP), INTENT(OUT) :: FERR(*), BERR(*)
2539         REAL(WP), INTENT(OUT) :: X(LDX,*), WORK(*)
2540         REAL(WP), INTENT(IN) :: A(LDA,*), B(LDB,*)
2541         REAL(WP), INTENT(INOUT) :: AF(LDAF,*)
2542      END SUBROUTINE DSYSVX
2543
2544      MODULE PROCEDURE DSYSVX1
2545
2546       END INTERFACE
2547
2548
2549      INTERFACE LA_PTSVX
2550
2551       SUBROUTINE DPTSVX( FACT, N, NRHS, D, E, DF, EF, B, LDB, X, LDX,  &
2552     &                    RCOND, FERR, BERR, WORK, INFO )
2553         USE LA_PRECISION, ONLY: WP => DP
2554         CHARACTER(LEN=1), INTENT(IN) :: FACT
2555         INTEGER, INTENT(IN) :: LDB, LDX, NRHS, N
2556         INTEGER, INTENT(OUT) :: INFO
2557         REAL(WP), INTENT(OUT) :: RCOND
2558         REAL(WP), INTENT(OUT) :: FERR(*), BERR(*)
2559         REAL(WP), INTENT(OUT) :: X(LDX,*), WORK(*)
2560         REAL(WP), INTENT(IN) :: D(*)
2561         REAL(WP), INTENT(IN) :: E(*), B(LDB,*)
2562         REAL(WP), INTENT(INOUT) :: DF(*)
2563         REAL(WP), INTENT(INOUT) :: EF(*)
2564      END SUBROUTINE DPTSVX
2565
2566      MODULE PROCEDURE DPTSVX1
2567
2568       END INTERFACE
2569
2570      INTERFACE LA_PBSVX
2571
2572       SUBROUTINE DPBSVX( FACT, UPLO, N, KD, NRHS, AB, LDAB, AFB, LDAFB,&
2573     &                    EQUED, S, B, LDB, X, LDX, RCOND, FERR, BERR,  &
2574     &                    WORK, IWORK, INFO )
2575         USE LA_PRECISION, ONLY: WP => DP
2576         CHARACTER(LEN=1), INTENT(IN) :: FACT, UPLO
2577         CHARACTER(LEN=1), INTENT(INOUT) :: EQUED
2578         INTEGER, INTENT(IN) :: LDAB, LDAFB, LDB, LDX, NRHS, N, KD
2579         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
2580         REAL(WP), INTENT(OUT) :: X(LDX,*), WORK(*), FERR(*), BERR(*),  &
2581     &                            RCOND
2582         REAL(WP), INTENT(INOUT) :: AB(LDAB,*), AFB(LDAFB,*), B(LDB,*), &
2583     &                              S(*)
2584      END SUBROUTINE DPBSVX
2585
2586      MODULE PROCEDURE DPBSVX1
2587
2588       END INTERFACE
2589
2590      INTERFACE LA_PPSVX
2591
2592       SUBROUTINE DPPSVX( FACT, UPLO, N, NRHS, AP, AFP, EQUED, S, B,    &
2593     &                    LDB, X, LDX, RCOND, FERR, BERR, WORK, IWORK,  &
2594     &                    INFO )
2595         USE LA_PRECISION, ONLY: WP => DP
2596         CHARACTER(LEN=1), INTENT(IN) :: FACT, UPLO
2597         CHARACTER(LEN=1), INTENT(INOUT) :: EQUED
2598         INTEGER, INTENT(IN) :: LDB, LDX, NRHS, N
2599         INTEGER, INTENT(OUT) :: INFO
2600         INTEGER, INTENT(OUT) :: IWORK(*)
2601         REAL(WP), INTENT(OUT) :: RCOND
2602         REAL(WP), INTENT(OUT) :: FERR(*), BERR(*)
2603         REAL(WP), INTENT(OUT) :: X(LDX,*), WORK(*)
2604         REAL(WP), INTENT(INOUT) :: AP(*), AFP(*), B(LDB,*), S(*)
2605      END SUBROUTINE DPPSVX
2606
2607      MODULE PROCEDURE DPPSVX1
2608
2609       END INTERFACE
2610
2611      INTERFACE LA_POSVX
2612
2613       SUBROUTINE DPOSVX( FACT, UPLO, N, NRHS, A, LDA, AF, LDAF, EQUED, &
2614     &                    S, B, LDB, X, LDX, RCOND, FERR, BERR, WORK,   &
2615     &                    IWORK, INFO )
2616         USE LA_PRECISION, ONLY: WP => DP
2617         CHARACTER(LEN=1), INTENT(IN) :: FACT, UPLO
2618         CHARACTER(LEN=1), INTENT(INOUT) :: EQUED
2619         INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, NRHS, N
2620         INTEGER, INTENT(OUT) :: INFO
2621         INTEGER, INTENT(OUT) :: IWORK(*)
2622         REAL(WP), INTENT(OUT) :: RCOND
2623         REAL(WP), INTENT(OUT) :: FERR(*), BERR(*)
2624         REAL(WP), INTENT(OUT) :: X(LDX,*), WORK(*)
2625         REAL(WP), INTENT(INOUT) :: S(*)
2626         REAL(WP), INTENT(INOUT) :: A(LDA,*), AF(LDAF,*), B(LDB,*)
2627      END SUBROUTINE DPOSVX
2628
2629      MODULE PROCEDURE DPOSVX1
2630
2631       END INTERFACE
2632
2633      INTERFACE LA_GTSVX
2634
2635       SUBROUTINE DGTSVX( FACT, TRANS, N, NRHS, DL, D, DU, DLF, DF, DUF,&
2636     &                    DU2, IPIV, B, LDB, X, LDX, RCOND, FERR, BERR, &
2637     &                    WORK, IWORK, INFO )
2638         USE LA_PRECISION, ONLY: WP => DP
2639         CHARACTER(LEN=1), INTENT(IN) :: TRANS, FACT
2640         INTEGER, INTENT(IN) :: LDB, LDX, NRHS, N
2641         INTEGER, INTENT(OUT) :: INFO
2642         INTEGER, INTENT(OUT) :: IWORK(*)
2643         INTEGER, INTENT(INOUT) :: IPIV(*)
2644         REAL(WP), INTENT(OUT) :: RCOND
2645         REAL(WP), INTENT(OUT) :: FERR(*), BERR(*), X(LDX,*), WORK(*)
2646         REAL(WP), INTENT(IN) :: B(LDB,*), DL(*), D(*), DU(*)
2647         REAL(WP), INTENT(INOUT) :: DF(*), DLF(*), DU2(*), DUF(*)
2648      END SUBROUTINE DGTSVX
2649
2650      MODULE PROCEDURE DGTSVX1
2651
2652       END INTERFACE
2653
2654      INTERFACE LA_GBSVX
2655
2656       SUBROUTINE DGBSVX( FACT, TRANS, N, KL, KU, NRHS, A, LDA, AF,     &
2657     &                    LDAF, PIV, EQUED, R, C, B, LDB, X, LDX, RCOND,&
2658     &                    FERR, BERR, WORK, IWORK, INFO )
2659         USE LA_PRECISION, ONLY: WP => DP
2660         CHARACTER(LEN=1), INTENT(IN) :: TRANS, FACT
2661         CHARACTER(LEN=1), INTENT(INOUT) :: EQUED
2662         INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, NRHS, N, KL, KU
2663         INTEGER, INTENT(OUT) :: INFO
2664         INTEGER, INTENT(OUT) :: IWORK(*)
2665         INTEGER, INTENT(INOUT) :: PIV(*)
2666         REAL(WP), INTENT(OUT) :: RCOND
2667         REAL(WP), INTENT(OUT) :: FERR(*), BERR(*)
2668         REAL(WP), INTENT(OUT) :: X(LDX,*), WORK(*)
2669         REAL(WP), INTENT(INOUT) :: R(*), C(*)
2670         REAL(WP), INTENT(INOUT) :: A(LDA,*), AF(LDAF,*), B(LDB,*)
2671      END SUBROUTINE DGBSVX
2672
2673      MODULE PROCEDURE DGBSVX1
2674
2675       END INTERFACE
2676
2677      INTERFACE LA_GESVX
2678
2679       SUBROUTINE DGESVX( FACT, TRANS, N, NRHS, A, LDA, AF, LDAF, PIV,  &
2680     &                    EQUED, R, C, B, LDB, X, LDX, RCOND, FERR,     &
2681     &                    BERR, WORK, IWORK, INFO )
2682         USE LA_PRECISION, ONLY: WP => DP
2683         CHARACTER(LEN=1), INTENT(IN) :: TRANS, FACT
2684         CHARACTER(LEN=1), INTENT(INOUT) :: EQUED
2685         INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, NRHS, N
2686         INTEGER, INTENT(OUT) :: INFO
2687         INTEGER, INTENT(OUT) :: IWORK(*)
2688         INTEGER, INTENT(INOUT) :: PIV(*)
2689         REAL(WP), INTENT(OUT) :: RCOND
2690         REAL(WP), INTENT(OUT) :: FERR(*), BERR(*)
2691         REAL(WP), INTENT(OUT) :: X(LDX,*), WORK(*)
2692         REAL(WP), INTENT(INOUT) :: R(*), C(*)
2693         REAL(WP), INTENT(INOUT) :: A(LDA,*), AF(LDAF,*), B(LDB,*)
2694      END SUBROUTINE DGESVX
2695
2696      MODULE PROCEDURE DGESVX1
2697
2698      END INTERFACE
2699
2700      INTERFACE LA_GETRF
2701
2702       SUBROUTINE DGETRF( M, N, A, LDA, PIV, INFO )
2703         USE LA_PRECISION, ONLY: WP => DP
2704         INTEGER, INTENT(IN) :: LDA, M, N
2705         INTEGER, INTENT(OUT) :: INFO
2706         INTEGER, INTENT( OUT ) :: PIV( * )
2707         REAL(WP), INTENT( INOUT ) :: A( LDA, * )
2708      END SUBROUTINE DGETRF
2709
2710
2711       END INTERFACE
2712
2713      INTERFACE LA_GETRS
2714
2715       SUBROUTINE DGETRS( TRANS, N, NRHS, A, LDA, PIV, B, LDB, INFO )
2716         USE LA_PRECISION, ONLY: WP => DP
2717         CHARACTER(LEN=1), INTENT(IN) :: TRANS
2718         INTEGER, INTENT(IN) :: LDA, LDB, NRHS, N
2719         INTEGER, INTENT(OUT) :: INFO
2720         INTEGER, INTENT(IN) :: PIV(*)
2721         REAL(WP), INTENT(IN) :: A(LDA,*)
2722         REAL(WP), INTENT(INOUT) :: B(LDB,*)
2723      END SUBROUTINE DGETRS
2724
2725      MODULE PROCEDURE DGETRS1
2726
2727       END INTERFACE
2728
2729      INTERFACE LA_GETRI
2730
2731       SUBROUTINE DGETRI( N, A, LDA, IPIV, WORK, LWORK, INFO )
2732         USE LA_PRECISION, ONLY: WP => DP
2733         INTEGER, INTENT(IN) :: LDA, LWORK, N
2734         INTEGER, INTENT(OUT) :: INFO
2735         INTEGER, INTENT(IN) :: IPIV(*)
2736         REAL(WP), INTENT(OUT) :: WORK(LWORK)
2737         REAL(WP), INTENT(INOUT) :: A(LDA,*)
2738      END SUBROUTINE DGETRI
2739
2740       END INTERFACE
2741
2742      INTERFACE LA_GERFS
2743
2744       SUBROUTINE DGERFS( TRANS, N, NRHS, A, LDA, AF, LDAF, PIV, B, LDB,&
2745     &                    X, LDX, FERR, BERR, WORK, IWORK, INFO )
2746         USE LA_PRECISION, ONLY: WP => DP
2747         CHARACTER(LEN=1), INTENT(IN) :: TRANS
2748         INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, NRHS, N
2749         INTEGER, INTENT(OUT) :: INFO
2750         INTEGER, INTENT(IN) :: PIV(*)
2751         INTEGER, INTENT(OUT) :: IWORK(*)
2752         REAL(WP), INTENT(OUT) :: FERR(*), BERR(*)
2753         REAL(WP), INTENT(OUT) :: WORK(*)
2754         REAL(WP), INTENT(IN) :: A(LDA,*), AF(LDAF,*), B(LDB,*)
2755         REAL(WP), INTENT(INOUT) :: X(LDX,*)
2756      END SUBROUTINE DGERFS
2757
2758      MODULE PROCEDURE DGERFS1
2759
2760       END INTERFACE
2761
2762      INTERFACE LA_GEEQU
2763
2764       SUBROUTINE DGEEQU( M, N, A, LDA, R, C, ROWCND, COLCND, AMAX,     &
2765     &                    INFO )
2766         USE LA_PRECISION, ONLY: WP => DP
2767         INTEGER, INTENT(IN) :: LDA, M, N
2768         INTEGER, INTENT(OUT) :: INFO
2769         REAL(WP), INTENT(OUT) :: AMAX, COLCND, ROWCND
2770         REAL(WP), INTENT(IN) :: A( LDA, * )
2771         REAL(WP), INTENT(OUT) :: C( * ), R( * )
2772      END SUBROUTINE DGEEQU
2773
2774       END INTERFACE
2775
2776      INTERFACE LA_LANGE
2777
2778       FUNCTION DLANGE( NORM, M, N, A, LDA, WORK )
2779         USE LA_PRECISION, ONLY: WP => DP
2780         REAL(WP) :: DLANGE
2781         CHARACTER(LEN=1), INTENT(IN) :: NORM
2782         INTEGER, INTENT(IN) :: LDA, M, N
2783         REAL(WP), INTENT(IN) :: A( LDA, * )
2784         REAL(WP), INTENT(OUT) :: WORK( * )
2785      END FUNCTION DLANGE
2786
2787      MODULE PROCEDURE DLANGE1
2788
2789       END INTERFACE
2790
2791      INTERFACE LA_GECON
2792
2793       SUBROUTINE DGECON( NORM, N, A, LDA, ANORM, RCOND, WORK, IWORK,   &
2794     &                    INFO )
2795         USE LA_PRECISION, ONLY: WP => DP
2796         CHARACTER(LEN=1), INTENT(IN) :: NORM
2797         INTEGER, INTENT(IN) :: LDA, N
2798         INTEGER, INTENT(OUT) :: INFO
2799         REAL(WP), INTENT(IN) :: ANORM
2800         REAL(WP), INTENT(OUT) :: RCOND
2801         INTEGER, INTENT(OUT) :: IWORK( * )
2802         REAL(WP), INTENT(IN) :: A( LDA, * )
2803         REAL(WP), INTENT(OUT) :: WORK( * )
2804      END SUBROUTINE DGECON
2805
2806       END INTERFACE
2807
2808      INTERFACE LA_SYEV
2809
2810       SUBROUTINE DSYEV( JOBZ, UPLO, N, A, LDA, W, WORK, LWORK, INFO )
2811         USE LA_PRECISION, ONLY: WP => DP
2812         CHARACTER(LEN=1), INTENT(IN) :: JOBZ, UPLO
2813         INTEGER, INTENT(IN) :: LDA, LWORK, N
2814         INTEGER, INTENT(OUT) :: INFO
2815         REAL(WP), INTENT(INOUT) :: A(LDA,*)
2816         REAL(WP), INTENT(OUT) :: W(*)
2817         REAL(WP), INTENT(OUT) :: WORK(*)
2818      END SUBROUTINE DSYEV
2819
2820       END INTERFACE
2821
2822
2823      INTERFACE LA_SYEVD
2824
2825       SUBROUTINE DSYEVD( JOBZ, UPLO, N, A, LDA, W, WORK, LWORK, IWORK, &
2826     &                    LIWORK, INFO )
2827         USE LA_PRECISION, ONLY: WP => DP
2828         CHARACTER(LEN=1), INTENT(IN) :: JOBZ, UPLO
2829         INTEGER, INTENT(IN) :: LDA, LIWORK, LWORK, N
2830         INTEGER, INTENT(OUT) :: INFO
2831         INTEGER, INTENT(OUT) :: IWORK(*)
2832         REAL(WP), INTENT(INOUT) :: A(LDA,*)
2833         REAL(WP), INTENT(OUT) :: W(*)
2834         REAL(WP), INTENT(OUT) :: WORK(*)
2835      END SUBROUTINE DSYEVD
2836
2837       END INTERFACE
2838
2839
2840       INTERFACE LA_SYEVR
2841
2842       SUBROUTINE DSYEVR( JOBZ, RANGE, UPLO, N, A, LDA, VL, VU, IL, IU, &
2843     &                    ABSTOL, M, W, Z, LDZ, ISUPPZ, WORK, LWORK,    &
2844     &                    IWORK, LIWORK, INFO )
2845         USE LA_PRECISION, ONLY: WP => DP
2846         CHARACTER(LEN=1), INTENT(IN) :: JOBZ, RANGE, UPLO
2847         INTEGER, INTENT(IN) :: N, IL, IU, LDZ, LDA, LWORK, LIWORK
2848         INTEGER, INTENT(OUT) :: M
2849         INTEGER, INTENT(OUT) :: ISUPPZ(*)
2850         REAL(WP), INTENT(IN) ::  ABSTOL, VL, VU
2851         INTEGER, INTENT(OUT) ::  IWORK(*)
2852         INTEGER, INTENT(OUT) :: INFO
2853         REAL(WP), INTENT(INOUT) :: A(LDA,*)
2854         REAL(WP), INTENT(OUT) :: WORK(*), Z(LDZ,*)
2855         REAL(WP), INTENT(OUT) :: W(*)
2856       END SUBROUTINE  DSYEVR
2857
2858      END INTERFACE
2859
2860
2861      INTERFACE LA_SYEVX
2862
2863       SUBROUTINE DSYEVX( JOBZ, RANGE, UPLO, N, A, LDA, VL, VU, IL, IU, &
2864     &                    ABSTOL, M, W, Z, LDZ, WORK, LWORK, IWORK,     &
2865     &                    IFAIL, INFO )
2866         USE LA_PRECISION, ONLY: WP => DP
2867         CHARACTER(LEN=1), INTENT(IN) :: JOBZ, RANGE, UPLO
2868         INTEGER, INTENT(IN) :: IL, IU, LDA, LDZ, LWORK, N
2869         INTEGER, INTENT(OUT) :: INFO, M
2870         INTEGER, INTENT(OUT) :: IFAIL(*), IWORK(*)
2871         REAL(WP), INTENT(IN) :: ABSTOL, VL, VU
2872         REAL(WP), INTENT(INOUT) :: A(LDA,*)
2873         REAL(WP), INTENT(OUT) :: W(*)
2874         REAL(WP), INTENT(OUT) :: WORK(*), Z(LDZ,*)
2875      END SUBROUTINE DSYEVX
2876
2877       END INTERFACE
2878
2879
2880      INTERFACE LA_SYGST
2881
2882       SUBROUTINE DSYGST( ITYPE, UPLO, N, A, LDA, B, LDB, INFO )
2883         USE LA_PRECISION, ONLY: WP => DP
2884         CHARACTER(LEN=1), INTENT(IN) :: UPLO
2885         INTEGER, INTENT(IN) :: ITYPE, LDA, LDB, N
2886         INTEGER, INTENT(OUT) :: INFO
2887         REAL(WP), INTENT(IN) :: B(LDB,*)
2888         REAL(WP), INTENT(INOUT) :: A(LDA,*)
2889      END SUBROUTINE DSYGST
2890
2891       END INTERFACE
2892
2893
2894      INTERFACE LA_SYGV
2895
2896       SUBROUTINE DSYGV( ITYPE, JOBZ, UPLO, N, A, LDA, B, LDB, W, WORK, &
2897     &                   LWORK, INFO )
2898         USE LA_PRECISION, ONLY: WP => DP
2899         CHARACTER(LEN=1), INTENT(IN) :: JOBZ, UPLO
2900         INTEGER, INTENT(IN) :: ITYPE, LDA, LDB, LWORK, N
2901         INTEGER, INTENT(OUT) :: INFO
2902         REAL(WP), INTENT(OUT) :: W(*)
2903         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
2904         REAL(WP), INTENT(OUT) :: WORK(*)
2905      END SUBROUTINE DSYGV
2906
2907       END INTERFACE
2908
2909
2910        INTERFACE LA_SYGVX
2911
2912
2913       SUBROUTINE DSYGVX( ITYPE, JOBZ, RANGE, UPLO, N, A, LDA, B, LDB,  &
2914     &                    VL, VU, IL, IU, ABSTOL, M, W, Z, LDZ, WORK,   &
2915     &                    LWORK, IWORK, IFAIL, INFO )
2916          USE LA_PRECISION, ONLY: WP => DP
2917          CHARACTER(LEN=1), INTENT(IN) :: JOBZ, RANGE, UPLO
2918          INTEGER, INTENT(IN) :: ITYPE, N, IL, IU, LDZ, LDA, LDB, LWORK
2919          INTEGER, INTENT(OUT) :: M
2920          REAL(WP), INTENT(IN) ::  ABSTOL, VL, VU
2921          INTEGER, INTENT(OUT) ::  IWORK(*)
2922          INTEGER, INTENT(OUT) :: INFO
2923          REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
2924          REAL(WP), INTENT(OUT) :: WORK(*), Z(LDZ,*)
2925          REAL(WP), INTENT(OUT) :: W(*)
2926          INTEGER, INTENT(IN) :: IFAIL(*)
2927         END SUBROUTINE DSYGVX
2928
2929        END INTERFACE
2930
2931
2932
2933       INTERFACE LA_SYGVD
2934
2935
2936       SUBROUTINE DSYGVD( ITYPE, JOBZ, UPLO, N, A, LDA, B, LDB, W, WORK,&
2937     &                    LWORK, IWORK, LIWORK, INFO )
2938         USE LA_PRECISION, ONLY: WP => DP
2939         CHARACTER(LEN=1), INTENT(IN) :: JOBZ, UPLO
2940         INTEGER, INTENT(IN) :: ITYPE, N, LDA, LDB, LWORK, LIWORK
2941         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
2942         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
2943         REAL(WP), INTENT(OUT) :: W(*)
2944         REAL(WP), INTENT(OUT) :: WORK(*)
2945        END SUBROUTINE DSYGVD
2946
2947        END INTERFACE
2948
2949
2950      INTERFACE LA_SYTRD
2951
2952       SUBROUTINE DSYTRD( UPLO, N, A, LDA, D, E, TAU, WORK, LWORK,      &
2953     &                    INFO )
2954         USE LA_PRECISION, ONLY: WP => DP
2955         CHARACTER(LEN=1), INTENT(IN) :: UPLO
2956         INTEGER, INTENT(IN) :: LDA, LWORK, N
2957         INTEGER, INTENT(OUT) :: INFO
2958         REAL(WP), INTENT(INOUT) :: A(LDA,*)
2959         REAL(WP), INTENT(OUT) :: D(*), E(*)
2960         REAL(WP), INTENT(OUT) :: TAU(*), WORK(LWORK)
2961      END SUBROUTINE DSYTRD
2962
2963       END INTERFACE
2964
2965
2966      INTERFACE LA_ORGTR
2967
2968       SUBROUTINE DORGTR( UPLO, N, A, LDA, TAU, WORK, LWORK, INFO )
2969         USE LA_PRECISION, ONLY: WP => DP
2970         CHARACTER(LEN=1), INTENT(IN) :: UPLO
2971         INTEGER, INTENT(IN) :: LDA, LWORK, N
2972         INTEGER, INTENT(OUT) :: INFO
2973         REAL(WP), INTENT(IN) :: TAU(*)
2974         REAL(WP), INTENT(INOUT) :: A(LDA,*)
2975         REAL(WP), INTENT(OUT) :: WORK(LWORK)
2976      END SUBROUTINE DORGTR
2977
2978       END INTERFACE
2979
2980
2981      INTERFACE LA_LANSY
2982
2983      FUNCTION DLANSY( NORM, UPLO, N, A, LDA, WORK )
2984         USE LA_PRECISION, ONLY: WP => DP
2985         REAL(WP) :: DLANSY
2986         CHARACTER(LEN=1), INTENT(IN) :: NORM, UPLO
2987         INTEGER, INTENT(IN) :: LDA, N
2988         REAL(WP), INTENT(IN) :: A( LDA, * )
2989         REAL(WP), INTENT(OUT) :: WORK( * )
2990      END FUNCTION DLANSY
2991
2992       END INTERFACE
2993
2994      INTERFACE LA_POTRF
2995
2996       SUBROUTINE DPOTRF( UPLO, N, A, LDA, INFO )
2997         USE LA_PRECISION, ONLY: WP => DP
2998         CHARACTER(LEN=1), INTENT(IN) :: UPLO
2999         INTEGER, INTENT(IN) :: LDA, N
3000         INTEGER, INTENT(OUT) :: INFO
3001         REAL(WP), INTENT(INOUT) :: A(LDA,*)
3002      END SUBROUTINE DPOTRF
3003
3004       END INTERFACE
3005
3006      INTERFACE LA_POCON
3007
3008       SUBROUTINE DPOCON( UPLO, N, A, LDA, ANORM, RCOND, WORK, IWORK,   &
3009     &                    INFO )
3010         USE LA_PRECISION, ONLY: WP => DP
3011         CHARACTER(LEN=1), INTENT(IN) :: UPLO
3012         INTEGER, INTENT(IN) :: LDA, N
3013         INTEGER, INTENT(OUT) :: INFO
3014         REAL(WP), INTENT(IN) :: ANORM
3015         REAL(WP), INTENT(OUT) :: RCOND
3016         INTEGER, INTENT(OUT) :: IWORK( * )
3017         REAL(WP), INTENT(IN) :: A( LDA, * )
3018         REAL(WP), INTENT(OUT) :: WORK( * )
3019      END SUBROUTINE DPOCON
3020
3021      END INTERFACE
3022
3023      INTERFACE LA_ILAENV
3024
3025      FUNCTION ILAENV( ISPEC, NAME, OPTS, N1, N2, N3, N4 )
3026         INTEGER :: ILAENV
3027         CHARACTER(LEN=*), INTENT(IN) :: NAME, OPTS
3028         INTEGER, INTENT(IN) :: ISPEC, N1, N2, N3, N4
3029      END FUNCTION ILAENV
3030
3031      END INTERFACE
3032
3033      INTERFACE LA_LAGGE
3034
3035       SUBROUTINE DLAGGE( M, N, KL, KU, D, A, LDA, ISEED, WORK, INFO )
3036         USE LA_PRECISION, ONLY: WP => DP
3037         INTEGER, INTENT(IN) :: M, N, KL, KU, LDA
3038         INTEGER, INTENT(OUT) :: INFO
3039         INTEGER, INTENT(INOUT) :: ISEED(4)
3040         REAL(WP), INTENT(IN) :: D(*)
3041         REAL(WP), INTENT(OUT) :: A(LDA,*), WORK(*)
3042      END SUBROUTINE DLAGGE
3043
3044      END INTERFACE
3045
3046      CONTAINS
3047
3048      SUBROUTINE DGESV1( N, NRHS, A, LDA, PIV, B, LDB, INFO )
3049         USE LA_PRECISION, ONLY: WP => DP
3050         INTEGER, INTENT(IN) :: LDA, LDB, NRHS, N
3051         INTEGER, INTENT(OUT) :: INFO
3052         INTEGER, INTENT(OUT) :: PIV(*)
3053         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(*)
3054         INTERFACE
3055           SUBROUTINE DGESV( N, NRHS, A, LDA, PIV, B, LDB, INFO )
3056             USE LA_PRECISION, ONLY: WP => DP
3057             INTEGER, INTENT(IN) :: LDA, LDB, NRHS, N
3058             INTEGER, INTENT(OUT) :: INFO
3059             INTEGER, INTENT(OUT) :: PIV(*)
3060             REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
3061           END SUBROUTINE DGESV
3062         END INTERFACE
3063         CALL DGESV( N, NRHS, A, LDA, PIV, B, LDB, INFO )
3064      END SUBROUTINE DGESV1
3065
3066
3067
3068      SUBROUTINE DGESVX1( FACT, TRANS, N, NRHS, A, LDA, AF, LDAF, PIV,  &
3069     &                    EQUED, R, C, B, LDB, X, LDX, RCOND, FERR,     &
3070     &                    BERR, WORK, IWORK, INFO )
3071         USE LA_PRECISION, ONLY: WP => DP
3072         CHARACTER(LEN=1), INTENT(IN) :: TRANS, FACT
3073         CHARACTER(LEN=1), INTENT(INOUT) :: EQUED
3074         INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, NRHS, N
3075         INTEGER, INTENT(OUT) :: INFO
3076         INTEGER, INTENT(OUT) :: IWORK(*)
3077         INTEGER, INTENT(INOUT) :: PIV(*)
3078         REAL(WP), INTENT(OUT) :: RCOND
3079         REAL(WP), INTENT(OUT) :: FERR, BERR
3080         REAL(WP), INTENT(OUT) :: X(*), WORK(*)
3081         REAL(WP), INTENT(INOUT) :: R(*), C(*)
3082         REAL(WP), INTENT(INOUT) :: A(LDA,*), AF(LDAF,*), B(*)
3083         INTERFACE
3084           SUBROUTINE DGESVX( FACT, TRANS, N, NRHS, A, LDA, AF, LDAF,   &
3085     &                        PIV, EQUED, R, C, B, LDB, X, LDX, RCOND,  &
3086     &                        FERR, BERR, WORK, IWORK, INFO )
3087             USE LA_PRECISION, ONLY: WP => DP
3088             CHARACTER(LEN=1), INTENT(IN) :: TRANS, FACT
3089             CHARACTER(LEN=1), INTENT(INOUT) :: EQUED
3090             INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, NRHS, N
3091             INTEGER, INTENT(OUT) :: INFO
3092             INTEGER, INTENT(OUT) :: IWORK(*)
3093             INTEGER, INTENT(INOUT) :: PIV(*)
3094             REAL(WP), INTENT(OUT) :: RCOND
3095             REAL(WP), INTENT(OUT) :: FERR(*), BERR(*)
3096             REAL(WP), INTENT(OUT) :: X(LDX,*), WORK(*)
3097             REAL(WP), INTENT(INOUT) :: R(*), C(*)
3098             REAL(WP), INTENT(INOUT) :: A(LDA,*), AF(LDAF,*), B(LDB,*)
3099           END SUBROUTINE DGESVX
3100         END INTERFACE
3101         REAL(WP) :: LFERR(1), LBERR(1)
3102         CALL DGESVX( FACT, TRANS, N, NRHS, A, LDA, AF, LDAF, PIV,      &
3103     &                EQUED, R, C, B, LDB, X, LDX, RCOND, LFERR, LBERR, &
3104     &                WORK, IWORK, INFO )
3105         FERR = LFERR(1); BERR = LBERR(1)
3106      END SUBROUTINE DGESVX1
3107
3108
3109      SUBROUTINE DPOSV1( UPLO, N, NRHS, A, LDA, B, LDB, INFO )
3110         USE LA_PRECISION, ONLY: WP => DP
3111         CHARACTER(LEN=1), INTENT(IN) :: UPLO
3112         INTEGER, INTENT(IN) :: NRHS, N, LDB, LDA
3113         INTEGER, INTENT(OUT) :: INFO
3114         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(*)
3115         INTERFACE
3116           SUBROUTINE DPOSV( UPLO, N, NRHS, A, LDA, B, LDB, INFO )
3117             USE LA_PRECISION, ONLY: WP => DP
3118             CHARACTER(LEN=1), INTENT(IN) :: UPLO
3119             INTEGER, INTENT(IN) :: NRHS, N, LDB, LDA
3120             INTEGER, INTENT(OUT) :: INFO
3121             REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
3122           END SUBROUTINE DPOSV
3123         END INTERFACE
3124         CALL DPOSV( UPLO, N, NRHS, A, LDA, B, LDB, INFO )
3125      END SUBROUTINE DPOSV1
3126
3127
3128      FUNCTION DLANGE1( NORM, M, N, A, LDA, WORK )
3129         USE LA_PRECISION, ONLY: WP => DP
3130         REAL(WP) :: DLANGE1
3131         CHARACTER(LEN=1), INTENT(IN) :: NORM
3132         INTEGER, INTENT(IN) :: LDA, M, N
3133         REAL(WP), INTENT(IN) :: A( * )
3134         REAL(WP), INTENT(OUT) :: WORK( * )
3135         INTERFACE
3136           FUNCTION DLANGE( NORM, M, N, A, LDA, WORK )
3137             USE LA_PRECISION, ONLY: WP => DP
3138             REAL(WP) :: DLANGE
3139             CHARACTER(LEN=1), INTENT(IN) :: NORM
3140             INTEGER, INTENT(IN) :: LDA, M, N
3141             REAL(WP), INTENT(IN) :: A( LDA, * )
3142             REAL(WP), INTENT(OUT) :: WORK( * )
3143           END FUNCTION DLANGE
3144         END INTERFACE
3145        DLANGE1 = DLANGE( NORM, M, N, A, LDA, WORK )
3146      END FUNCTION DLANGE1
3147
3148
3149      SUBROUTINE DGBSV1( N, KL, KU, NRHS, AB, LDAB, PIV, B, LDB, INFO )
3150         USE LA_PRECISION, ONLY: WP => DP
3151         INTEGER, INTENT(IN) :: KL, KU, LDAB, LDB, NRHS, N
3152         INTEGER, INTENT(OUT) :: INFO
3153         INTEGER, INTENT(OUT) :: PIV(*)
3154         REAL(WP), INTENT(INOUT) :: AB(LDAB,*), B(*)
3155         INTERFACE
3156           SUBROUTINE DGBSV( N, KL, KU, NRHS, AB, LDAB, PIV, B, LDB,    &
3157     &                       INFO )
3158             USE LA_PRECISION, ONLY: WP => DP
3159             INTEGER, INTENT(IN) :: KL, KU, LDAB, LDB, NRHS, N
3160             INTEGER, INTENT(OUT) :: INFO
3161             INTEGER, INTENT(OUT) :: PIV(*)
3162             REAL(WP), INTENT(INOUT) :: AB(LDAB,*), B(LDB,*)
3163           END SUBROUTINE DGBSV
3164         END INTERFACE
3165         CALL DGBSV( N, KL, KU, NRHS, AB, LDAB, PIV, B, LDB, INFO )
3166      END SUBROUTINE DGBSV1
3167
3168
3169      SUBROUTINE DGBSVX1( FACT, TRANS, N, KL, KU, NRHS, A, LDA, AF,     &
3170     &                    LDAF, PIV, EQUED, R, C, B, LDB, X, LDX, RCOND,&
3171     &                    FERR, BERR, WORK, IWORK, INFO )
3172         USE LA_PRECISION, ONLY: WP => DP
3173         CHARACTER(LEN=1), INTENT(IN) :: TRANS, FACT
3174         CHARACTER(LEN=1), INTENT(INOUT) :: EQUED
3175         INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, NRHS, N, KL, KU
3176         INTEGER, INTENT(OUT) :: INFO
3177         INTEGER, INTENT(OUT) :: IWORK(*)
3178         INTEGER, INTENT(INOUT) :: PIV(*)
3179         REAL(WP), INTENT(OUT) :: RCOND
3180         REAL(WP), INTENT(OUT) :: FERR, BERR
3181         REAL(WP), INTENT(OUT) :: X(*), WORK(*)
3182         REAL(WP), INTENT(INOUT) :: R(*), C(*)
3183         REAL(WP), INTENT(INOUT) :: A(LDA,*), AF(LDAF,*), B(*)
3184         INTERFACE
3185           SUBROUTINE DGBSVX( FACT, TRANS, N, KL, KU, NRHS, A, LDA, AF, &
3186     &                        LDAF, PIV, EQUED, R, C, B, LDB, X, LDX,   &
3187     &                        RCOND, FERR, BERR, WORK, IWORK, INFO )
3188             USE LA_PRECISION, ONLY: WP => DP
3189             CHARACTER(LEN=1), INTENT(IN) :: TRANS, FACT
3190             CHARACTER(LEN=1), INTENT(INOUT) :: EQUED
3191             INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, NRHS, N, KL, KU
3192             INTEGER, INTENT(OUT) :: INFO
3193!
3194             INTEGER, INTENT(OUT) :: IWORK(*)
3195             INTEGER, INTENT(INOUT) :: PIV(*)
3196             REAL(WP), INTENT(OUT) :: RCOND
3197             REAL(WP), INTENT(OUT) :: FERR(*), BERR(*)
3198             REAL(WP), INTENT(OUT) :: X(LDX,*), WORK(*)
3199             REAL(WP), INTENT(INOUT) :: R(*), C(*)
3200             REAL(WP), INTENT(INOUT) :: A(LDA,*), AF(LDAF,*), B(LDB,*)
3201           END SUBROUTINE DGBSVX
3202         END INTERFACE
3203         REAL(WP) :: LFERR(1), LBERR(1)
3204         CALL DGBSVX( FACT, TRANS, N, KL, KU, NRHS, A, LDA, AF, LDAF,   &
3205     &                PIV, EQUED, R, C, B, LDB, X, LDX, RCOND, LFERR,   &
3206     &                LBERR, WORK, IWORK, INFO )
3207         FERR = LFERR(1); BERR = LBERR(1)
3208      END SUBROUTINE DGBSVX1
3209
3210
3211      SUBROUTINE DGTSV1( N, NRHS, DL, D, DU, B, LDB, INFO )
3212         USE LA_PRECISION, ONLY: WP => DP
3213         INTEGER, INTENT(IN) :: NRHS, N, LDB
3214         INTEGER, INTENT(OUT) :: INFO
3215         REAL(WP), INTENT(INOUT) :: DL(*), D(*), DU(*), B(*)
3216         INTERFACE
3217           SUBROUTINE DGTSV( N, NRHS, DL, D, DU, B, LDB, INFO )
3218             USE LA_PRECISION, ONLY: WP => DP
3219             INTEGER, INTENT(IN) :: NRHS, N, LDB
3220             INTEGER, INTENT(OUT) :: INFO
3221             REAL(WP), INTENT(INOUT) :: DL(*), D(*), DU(*), B(LDB,*)
3222           END SUBROUTINE DGTSV
3223         END INTERFACE
3224         CALL DGTSV( N, NRHS, DL, D, DU, B, LDB, INFO )
3225      END SUBROUTINE DGTSV1
3226
3227
3228       SUBROUTINE DGTSVX1( FACT, TRANS, N, NRHS, DL, D, DU, DLF, DF,    &
3229     &                     DUF, DU2, IPIV, B, LDB, X, LDX, RCOND, FERR, &
3230     &                     BERR, WORK, IWORK, INFO )
3231         USE LA_PRECISION, ONLY: WP => DP
3232         CHARACTER(LEN=1), INTENT(IN) :: TRANS, FACT
3233         INTEGER, INTENT(IN) :: LDB, LDX, NRHS, N
3234         INTEGER, INTENT(OUT) :: INFO
3235         INTEGER, INTENT(OUT) :: IWORK(*)
3236         INTEGER, INTENT(INOUT) :: IPIV(*)
3237         REAL(WP), INTENT(OUT) :: RCOND
3238         REAL(WP), INTENT(OUT) :: FERR, BERR, X(*), WORK(*)
3239         REAL(WP), INTENT(IN) :: B(*), DL(*), D(*), DU(*)
3240         REAL(WP), INTENT(INOUT) :: DF(*), DLF(*), DU2(*), DUF(*)
3241         INTERFACE
3242           SUBROUTINE DGTSVX( FACT, TRANS, N, NRHS, DL, D, DU, DLF, DF, &
3243     &                        DUF, DU2, IPIV, B, LDB, X, LDX, RCOND,    &
3244     &                        FERR, BERR, WORK, IWORK, INFO )
3245             USE LA_PRECISION, ONLY: WP => DP
3246             CHARACTER(LEN=1), INTENT(IN) :: TRANS, FACT
3247             INTEGER, INTENT(IN) :: LDB, LDX, NRHS, N
3248             INTEGER, INTENT(OUT) :: INFO
3249             INTEGER, INTENT(OUT) :: IWORK(*)
3250             INTEGER, INTENT(INOUT) :: IPIV(*)
3251             REAL(WP), INTENT(OUT) :: RCOND
3252             REAL(WP), INTENT(OUT) :: FERR(*), BERR(*), X(LDX,*), WORK(*)
3253             REAL(WP), INTENT(IN) :: B(LDB,*), DL(*), D(*), DU(*)
3254             REAL(WP), INTENT(INOUT) :: DF(*), DLF(*), DU2(*), DUF(*)
3255           END SUBROUTINE DGTSVX
3256         END INTERFACE
3257         REAL(WP) :: LFERR(1), LBERR(1)
3258         CALL DGTSVX( FACT, TRANS, N, NRHS, DL, D, DU, DLF, DF, DUF,    &
3259     &                DU2, IPIV, B, LDB, X, LDX, RCOND, LFERR, LBERR,   &
3260     &                WORK, IWORK, INFO )
3261         FERR = LFERR(1); BERR = LBERR(1)
3262      END SUBROUTINE DGTSVX1
3263
3264
3265       SUBROUTINE DPOSVX1( FACT, UPLO, N, NRHS, A, LDA, AF, LDAF, EQUED,&
3266     &                     S, B, LDB, X, LDX, RCOND, FERR, BERR, WORK,  &
3267     &                     IWORK, INFO )
3268         USE LA_PRECISION, ONLY: WP => DP
3269         CHARACTER(LEN=1), INTENT(IN) :: FACT, UPLO
3270         CHARACTER(LEN=1), INTENT(INOUT) :: EQUED
3271         INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, NRHS, N
3272         INTEGER, INTENT(OUT) :: INFO
3273         INTEGER, INTENT(OUT) :: IWORK(*)
3274         REAL(WP), INTENT(OUT) :: RCOND
3275         REAL(WP), INTENT(OUT) :: FERR, BERR
3276         REAL(WP), INTENT(OUT) :: X(*), WORK(*)
3277         REAL(WP), INTENT(INOUT) :: S(*)
3278         REAL(WP), INTENT(INOUT) :: A(LDA,*), AF(LDAF,*), B(*)
3279         INTERFACE
3280           SUBROUTINE DPOSVX( FACT, UPLO, N, NRHS, A, LDA, AF, LDAF,    &
3281     &                        EQUED, S, B, LDB, X, LDX, RCOND, FERR,    &
3282     &                        BERR, WORK, IWORK, INFO )
3283             USE LA_PRECISION, ONLY: WP => DP
3284             CHARACTER(LEN=1), INTENT(IN) :: FACT, UPLO
3285             CHARACTER(LEN=1), INTENT(INOUT) :: EQUED
3286             INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, NRHS, N
3287             INTEGER, INTENT(OUT) :: INFO
3288             INTEGER, INTENT(OUT) :: IWORK(*)
3289             REAL(WP), INTENT(OUT) :: RCOND
3290             REAL(WP), INTENT(OUT) :: FERR(*), BERR(*)
3291             REAL(WP), INTENT(OUT) :: X(LDX,*), WORK(*)
3292             REAL(WP), INTENT(INOUT) :: S(*)
3293             REAL(WP), INTENT(INOUT) :: A(LDA,*), AF(LDAF,*), B(LDB,*)
3294           END SUBROUTINE DPOSVX
3295         END INTERFACE
3296         REAL(WP) :: LFERR(1), LBERR(1)
3297         CALL DPOSVX( FACT, UPLO, N, NRHS, A, LDA, AF, LDAF, EQUED, S,  &
3298     &                B, LDB, X, LDX, RCOND, LFERR, LBERR, WORK, IWORK, &
3299     &                INFO )
3300         FERR = LFERR(1); BERR = LBERR(1)
3301      END SUBROUTINE DPOSVX1
3302
3303
3304       SUBROUTINE DPPSV1( UPLO, N, NRHS, AP, B, LDB, INFO )
3305         USE LA_PRECISION, ONLY: WP => DP
3306         CHARACTER(LEN=1), INTENT(IN) :: UPLO
3307         INTEGER, INTENT(IN) :: NRHS, N, LDB
3308         INTEGER, INTENT(OUT) :: INFO
3309         REAL(WP), INTENT(INOUT) :: AP(*), B(*)
3310         INTERFACE
3311           SUBROUTINE DPPSV( UPLO, N, NRHS, AP, B, LDB, INFO )
3312             USE LA_PRECISION, ONLY: WP => DP
3313             CHARACTER(LEN=1), INTENT(IN) :: UPLO
3314             INTEGER, INTENT(IN) :: NRHS, N, LDB
3315             INTEGER, INTENT(OUT) :: INFO
3316             REAL(WP), INTENT(INOUT) :: AP(*), B(LDB,*)
3317           END SUBROUTINE DPPSV
3318         END INTERFACE
3319         CALL DPPSV( UPLO, N, NRHS, AP, B, LDB, INFO )
3320      END SUBROUTINE DPPSV1
3321
3322
3323       SUBROUTINE DPPSVX1( FACT, UPLO, N, NRHS, AP, AFP, EQUED, S, B,   &
3324     &                     LDB, X, LDX, RCOND, FERR, BERR, WORK, IWORK, &
3325     &                     INFO )
3326         USE LA_PRECISION, ONLY: WP => DP
3327         CHARACTER(LEN=1), INTENT(IN) :: FACT, UPLO
3328         CHARACTER(LEN=1), INTENT(INOUT) :: EQUED
3329         INTEGER, INTENT(IN) :: LDB, LDX, NRHS, N
3330         INTEGER, INTENT(OUT) :: INFO
3331         INTEGER, INTENT(OUT) :: IWORK(*)
3332         REAL(WP), INTENT(OUT) :: RCOND
3333         REAL(WP), INTENT(OUT) :: FERR, BERR
3334         REAL(WP), INTENT(OUT) :: X(*), WORK(*)
3335         REAL(WP), INTENT(INOUT) :: AP(*), AFP(*), B(*), S(*)
3336         INTERFACE
3337           SUBROUTINE DPPSVX( FACT, UPLO, N, NRHS, AP, AFP, EQUED, S, B,&
3338     &                        LDB, X, LDX, RCOND, FERR, BERR, WORK,     &
3339     &                        IWORK, INFO )
3340             USE LA_PRECISION, ONLY: WP => DP
3341             CHARACTER(LEN=1), INTENT(IN) :: FACT, UPLO
3342             CHARACTER(LEN=1), INTENT(INOUT) :: EQUED
3343             INTEGER, INTENT(IN) :: LDB, LDX, NRHS, N
3344             INTEGER, INTENT(OUT) :: INFO
3345             INTEGER, INTENT(OUT) :: IWORK(*)
3346             REAL(WP), INTENT(OUT) :: RCOND
3347             REAL(WP), INTENT(OUT) :: FERR(*), BERR(*)
3348             REAL(WP), INTENT(OUT) :: X(LDX,*), WORK(*)
3349             REAL(WP), INTENT(INOUT) :: AP(*), AFP(*), B(LDB,*), S(*)
3350           END SUBROUTINE DPPSVX
3351         END INTERFACE
3352         REAL(WP) :: LFERR(1), LBERR(1)
3353         CALL DPPSVX( FACT, UPLO, N, NRHS, AP, AFP, EQUED, S, B, LDB, X,&
3354     &                LDX, RCOND, LFERR, LBERR, WORK, IWORK, INFO )
3355         FERR = LFERR(1); BERR = LBERR(1)
3356      END SUBROUTINE DPPSVX1
3357
3358
3359       SUBROUTINE DPBSV1( UPLO, N, KD, NRHS, AB, LDAB, B, LDB, INFO )
3360         USE LA_PRECISION, ONLY: WP => DP
3361         CHARACTER(LEN=1), INTENT(IN) :: UPLO
3362         INTEGER, INTENT(IN) :: NRHS, N, LDB, KD, LDAB
3363         INTEGER, INTENT(OUT) :: INFO
3364         REAL(WP), INTENT(INOUT) :: AB(LDAB,*), B(*)
3365         INTERFACE
3366           SUBROUTINE DPBSV( UPLO, N, KD, NRHS, AB, LDAB, B, LDB,       &
3367     &                       INFO )
3368             USE LA_PRECISION, ONLY: WP => DP
3369             CHARACTER(LEN=1), INTENT(IN) :: UPLO
3370             INTEGER, INTENT(IN) :: NRHS, N, LDB, KD, LDAB
3371             INTEGER, INTENT(OUT) :: INFO
3372             REAL(WP), INTENT(INOUT) :: AB(LDAB,*), B(LDB,*)
3373           END SUBROUTINE DPBSV
3374         END INTERFACE
3375         CALL DPBSV( UPLO, N, KD, NRHS, AB, LDAB, B, LDB, INFO )
3376      END SUBROUTINE DPBSV1
3377
3378
3379       SUBROUTINE DPBSVX1( FACT, UPLO, N, KD, NRHS, AB, LDAB, AFB,      &
3380     &                     LDAFB, EQUED, S, B, LDB, X, LDX, RCOND, FERR,&
3381     &                     BERR, WORK, IWORK, INFO )
3382         USE LA_PRECISION, ONLY: WP => DP
3383         CHARACTER(LEN=1), INTENT(IN) :: FACT, UPLO
3384         CHARACTER(LEN=1), INTENT(INOUT) :: EQUED
3385         INTEGER, INTENT(IN) :: LDAB, LDAFB, LDB, LDX, NRHS, N, KD
3386         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
3387         REAL(WP), INTENT(OUT) :: X(*), WORK(*), FERR, BERR, RCOND
3388         REAL(WP), INTENT(INOUT) :: AB(LDAB,*), AFB(LDAFB,*), B(*),     &
3389     &                              S(*)
3390         INTERFACE
3391           SUBROUTINE DPBSVX( FACT, UPLO, N, KD, NRHS, AB, LDAB, AFB,   &
3392     &                        LDAFB, EQUED, S, B, LDB, X, LDX, RCOND,   &
3393     &                        FERR, BERR, WORK, IWORK, INFO )
3394             USE LA_PRECISION, ONLY: WP => DP
3395             CHARACTER(LEN=1), INTENT(IN) :: FACT, UPLO
3396             CHARACTER(LEN=1), INTENT(INOUT) :: EQUED
3397             INTEGER, INTENT(IN) :: LDAB, LDAFB, LDB, LDX, NRHS, N, KD
3398             INTEGER, INTENT(OUT) :: INFO, IWORK(*)
3399             REAL(WP), INTENT(OUT) :: X(LDX,*), WORK(*), FERR(*),       &
3400     &                                BERR(*), RCOND
3401             REAL(WP), INTENT(INOUT) :: AB(LDAB,*), AFB(LDAFB,*),       &
3402     &                                  B(LDB,*), S(*)
3403           END SUBROUTINE DPBSVX
3404         END INTERFACE
3405         REAL(WP) :: LFERR(1), LBERR(1)
3406         CALL DPBSVX( FACT, UPLO, N, KD, NRHS, AB, LDAB, AFB, LDAFB,    &
3407     &                EQUED, S, B, LDB, X, LDX, RCOND, LFERR, LBERR,    &
3408     &                WORK, IWORK, INFO )
3409         FERR = LFERR(1); BERR = LBERR(1)
3410      END SUBROUTINE DPBSVX1
3411
3412
3413       SUBROUTINE DPTSV1( N, NRHS, D, E, B, LDB, INFO )
3414         USE LA_PRECISION, ONLY: WP => DP
3415         INTEGER, INTENT(IN) :: NRHS, N, LDB
3416         INTEGER, INTENT(OUT) :: INFO
3417         REAL(WP), INTENT(INOUT) :: D(*)
3418         REAL(WP), INTENT(INOUT) :: E(*), B(*)
3419         INTERFACE
3420           SUBROUTINE DPTSV( N, NRHS, D, E, B, LDB, INFO )
3421             USE LA_PRECISION, ONLY: WP => DP
3422             INTEGER, INTENT(IN) :: NRHS, N, LDB
3423             INTEGER, INTENT(OUT) :: INFO
3424             REAL(WP), INTENT(INOUT) :: D(*)
3425             REAL(WP), INTENT(INOUT) :: E(*), B(LDB,*)
3426           END SUBROUTINE DPTSV
3427         END INTERFACE
3428         CALL DPTSV( N, NRHS, D, E, B, LDB, INFO )
3429      END SUBROUTINE DPTSV1
3430
3431
3432       SUBROUTINE DPTSVX1( FACT, N, NRHS, D, E, DF, EF, B, LDB, X, LDX, &
3433     &                     RCOND, FERR, BERR, WORK, INFO )
3434         USE LA_PRECISION, ONLY: WP => DP
3435         CHARACTER(LEN=1), INTENT(IN) :: FACT
3436         INTEGER, INTENT(IN) :: LDB, LDX, NRHS, N
3437         INTEGER, INTENT(OUT) :: INFO
3438         REAL(WP), INTENT(OUT) :: RCOND
3439         REAL(WP), INTENT(OUT) :: FERR, BERR
3440         REAL(WP), INTENT(OUT) :: X(*), WORK(*)
3441         REAL(WP), INTENT(IN) :: D(*)
3442         REAL(WP), INTENT(IN) :: E(*), B(*)
3443         REAL(WP), INTENT(INOUT) :: DF(*)
3444         REAL(WP), INTENT(INOUT) :: EF(*)
3445         INTERFACE
3446           SUBROUTINE DPTSVX( FACT, N, NRHS, D, E, DF, EF, B, LDB, X,   &
3447     &                        LDX, RCOND, FERR, BERR, WORK, INFO )
3448             USE LA_PRECISION, ONLY: WP => DP
3449             CHARACTER(LEN=1), INTENT(IN) :: FACT
3450             INTEGER, INTENT(IN) :: LDB, LDX, NRHS, N
3451             INTEGER, INTENT(OUT) :: INFO
3452             REAL(WP), INTENT(OUT) :: RCOND
3453             REAL(WP), INTENT(OUT) :: FERR(*), BERR(*)
3454             REAL(WP), INTENT(OUT) :: X(LDX,*), WORK(*)
3455             REAL(WP), INTENT(IN) :: D(*)
3456             REAL(WP), INTENT(IN) :: E(*), B(LDB,*)
3457             REAL(WP), INTENT(INOUT) :: DF(*)
3458             REAL(WP), INTENT(INOUT) :: EF(*)
3459           END SUBROUTINE DPTSVX
3460         END INTERFACE
3461         REAL(WP) :: LFERR(1), LBERR(1)
3462         CALL DPTSVX( FACT, N, NRHS, D, E, DF, EF, B, LDB, X, LDX,      &
3463     &                RCOND, LFERR, LBERR, WORK, INFO )
3464         FERR = LFERR(1); BERR = LBERR(1)
3465      END SUBROUTINE DPTSVX1
3466
3467
3468       SUBROUTINE DSYSV1( UPLO, N, NRHS, A, LDA, IPIV, B, LDB, WORK,    &
3469     &                    LWORK, INFO )
3470         USE LA_PRECISION, ONLY: WP => DP
3471         CHARACTER(LEN=1), INTENT(IN) :: UPLO
3472         INTEGER, INTENT(IN) :: NRHS, N, LDA, LDB, LWORK
3473         INTEGER, INTENT(OUT) :: INFO
3474         INTEGER, INTENT(IN) :: IPIV(*)
3475         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(*)
3476         REAL(WP), INTENT(OUT) :: WORK(*)
3477         INTERFACE
3478           SUBROUTINE DSYSV( UPLO, N, NRHS, A, LDA, IPIV, B, LDB, WORK, &
3479     &                       LWORK, INFO )
3480             USE LA_PRECISION, ONLY: WP => DP
3481             CHARACTER(LEN=1), INTENT(IN) :: UPLO
3482             INTEGER, INTENT(IN) :: NRHS, N, LDA, LDB, LWORK
3483             INTEGER, INTENT(OUT) :: INFO
3484             INTEGER, INTENT(IN) :: IPIV(*)
3485             REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
3486             REAL(WP), INTENT(OUT) :: WORK(*)
3487           END SUBROUTINE DSYSV
3488         END INTERFACE
3489         CALL DSYSV( UPLO, N, NRHS, A, LDA, IPIV, B, LDB, WORK, LWORK,  &
3490     &               INFO )
3491      END SUBROUTINE DSYSV1
3492
3493
3494
3495       SUBROUTINE DSYSVX1( FACT, UPLO, N, NRHS, A, LDA, AF, LDAF, IPIV, &
3496     &                     B, LDB, X, LDX, RCOND, FERR, BERR, WORK,     &
3497     &                     LWORK, IWORK, INFO )
3498         USE LA_PRECISION, ONLY: WP => DP
3499         CHARACTER(LEN=1), INTENT(IN) :: UPLO, FACT
3500         INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, NRHS, N, LWORK
3501         INTEGER, INTENT(OUT) :: INFO
3502         INTEGER, INTENT(OUT) :: IWORK(*)
3503         INTEGER, INTENT(INOUT) :: IPIV(*)
3504         REAL(WP), INTENT(OUT) :: RCOND
3505         REAL(WP), INTENT(OUT) :: FERR, BERR
3506         REAL(WP), INTENT(OUT) :: X(*), WORK(*)
3507         REAL(WP), INTENT(IN) :: A(LDA,*), B(*)
3508         REAL(WP), INTENT(INOUT) :: AF(LDAF,*)
3509         INTERFACE
3510           SUBROUTINE DSYSVX( FACT, UPLO, N, NRHS, A, LDA, AF, LDAF,    &
3511     &                        IPIV, B, LDB, X, LDX, RCOND, FERR, BERR,  &
3512     &                        WORK, LWORK, IWORK, INFO )
3513             USE LA_PRECISION, ONLY: WP => DP
3514             CHARACTER(LEN=1), INTENT(IN) :: UPLO, FACT
3515             INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, NRHS, N, LWORK
3516             INTEGER, INTENT(OUT) :: INFO
3517             INTEGER, INTENT(OUT) :: IWORK(*)
3518             INTEGER, INTENT(INOUT) :: IPIV(*)
3519             REAL(WP), INTENT(OUT) :: RCOND
3520             REAL(WP), INTENT(OUT) :: FERR(*), BERR(*)
3521             REAL(WP), INTENT(OUT) :: X(LDX,*), WORK(*)
3522             REAL(WP), INTENT(IN) :: A(LDA,*), B(LDB,*)
3523             REAL(WP), INTENT(INOUT) :: AF(LDAF,*)
3524           END SUBROUTINE DSYSVX
3525         END INTERFACE
3526         REAL(WP) :: LFERR(1), LBERR(1)
3527         CALL DSYSVX( FACT, UPLO, N, NRHS, A, LDA, AF, LDAF, IPIV, B,   &
3528     &                LDB, X, LDX, RCOND, LFERR, LBERR, WORK, LWORK,    &
3529     &                IWORK, INFO )
3530         FERR = LFERR(1); BERR = LBERR(1)
3531      END SUBROUTINE DSYSVX1
3532
3533
3534
3535       SUBROUTINE DSPSV1( UPLO, N, NRHS, AP, IPIV, B, LDB, INFO )
3536         USE LA_PRECISION, ONLY: WP => DP
3537         CHARACTER(LEN=1), INTENT(IN) :: UPLO
3538         INTEGER, INTENT(IN) :: NRHS, N, LDB
3539         INTEGER, INTENT(OUT) :: INFO
3540         INTEGER, INTENT(IN) :: IPIV(*)
3541         REAL(WP), INTENT(INOUT) :: AP(*), B(*)
3542         INTERFACE
3543           SUBROUTINE DSPSV( UPLO, N, NRHS, AP, IPIV, B, LDB, INFO )
3544             USE LA_PRECISION, ONLY: WP => DP
3545             CHARACTER(LEN=1), INTENT(IN) :: UPLO
3546             INTEGER, INTENT(IN) :: NRHS, N, LDB
3547             INTEGER, INTENT(OUT) :: INFO
3548             INTEGER, INTENT(IN) :: IPIV(*)
3549             REAL(WP), INTENT(INOUT) :: AP(*), B(LDB,*)
3550           END SUBROUTINE DSPSV
3551         END INTERFACE
3552         CALL DSPSV( UPLO, N, NRHS, AP, IPIV, B, LDB, INFO )
3553      END SUBROUTINE DSPSV1
3554
3555
3556
3557       SUBROUTINE DSPSVX1( FACT, UPLO, N, NRHS, A, AF, IPIV, B, LDB, X, &
3558     &                     LDX, RCOND, FERR, BERR, WORK, IWORK, INFO )
3559         USE LA_PRECISION, ONLY: WP => DP
3560         CHARACTER(LEN=1), INTENT(IN) :: UPLO, FACT
3561         INTEGER, INTENT(IN) :: LDB, LDX, NRHS, N
3562         INTEGER, INTENT(OUT) :: INFO
3563         INTEGER, INTENT(OUT) :: IWORK(*)
3564         INTEGER, INTENT(INOUT) :: IPIV(*)
3565         REAL(WP), INTENT(OUT) :: RCOND
3566         REAL(WP), INTENT(OUT) :: FERR, BERR
3567         REAL(WP), INTENT(OUT) :: X(*), WORK(*)
3568         REAL(WP), INTENT(IN) :: A(*), B(*)
3569         REAL(WP), INTENT(INOUT) :: AF(*)
3570         INTERFACE
3571           SUBROUTINE DSPSVX( FACT, UPLO, N, NRHS, A, AF, IPIV, B, LDB, &
3572     &                        X, LDX, RCOND, FERR, BERR, WORK, IWORK,   &
3573     &                        INFO )
3574             USE LA_PRECISION, ONLY: WP => DP
3575             CHARACTER(LEN=1), INTENT(IN) :: UPLO, FACT
3576             INTEGER, INTENT(IN) :: LDB, LDX, NRHS, N
3577             INTEGER, INTENT(OUT) :: INFO
3578             INTEGER, INTENT(OUT) :: IWORK(*)
3579             INTEGER, INTENT(INOUT) :: IPIV(*)
3580             REAL(WP), INTENT(OUT) :: RCOND
3581             REAL(WP), INTENT(OUT) :: FERR(*), BERR(*)
3582             REAL(WP), INTENT(OUT) :: X(LDX,*), WORK(*)
3583             REAL(WP), INTENT(IN) :: A(*), B(LDB,*)
3584             REAL(WP), INTENT(INOUT) :: AF(*)
3585           END SUBROUTINE DSPSVX
3586         END INTERFACE
3587         REAL(WP) :: LFERR(1), LBERR(1)
3588         CALL DSPSVX( FACT, UPLO, N, NRHS, A, AF, IPIV, B, LDB, X, LDX, &
3589     &                RCOND, LFERR, LBERR, WORK, IWORK, INFO )
3590         FERR = LFERR(1); BERR = LBERR(1)
3591      END SUBROUTINE DSPSVX1
3592
3593
3594
3595       SUBROUTINE DGELS1( TRANS, M, N, NRHS, A, LDA, B, LDB, WORK,      &
3596     &                    LWORK, INFO )
3597         USE LA_PRECISION, ONLY: WP => DP
3598         CHARACTER(LEN=1), INTENT(IN) :: TRANS
3599         INTEGER, INTENT(IN) :: NRHS, M, N, LDA, LDB, LWORK
3600         INTEGER, INTENT(OUT) :: INFO
3601         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(*)
3602         REAL(WP), INTENT(OUT) :: WORK(*)
3603         INTERFACE
3604           SUBROUTINE DGELS( TRANS, M, N, NRHS, A, LDA, B, LDB, WORK,   &
3605     &                       LWORK, INFO )
3606             USE LA_PRECISION, ONLY: WP => DP
3607             CHARACTER(LEN=1), INTENT(IN) :: TRANS
3608             INTEGER, INTENT(IN) :: NRHS, M, N, LDA, LDB, LWORK
3609             INTEGER, INTENT(OUT) :: INFO
3610             REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
3611             REAL(WP), INTENT(OUT) :: WORK(*)
3612           END SUBROUTINE DGELS
3613         END INTERFACE
3614         CALL DGELS( TRANS, M, N, NRHS, A, LDA, B, LDB, WORK, LWORK,    &
3615     &               INFO )
3616      END SUBROUTINE DGELS1
3617
3618
3619       SUBROUTINE DGELSY1( M, N, NRHS, A, LDA, B, LDB, JPVT, RCOND,     &
3620     &                     RANK, WORK, LWORK, INFO )
3621          USE LA_PRECISION, ONLY: WP => DP
3622          INTEGER, INTENT(IN) :: M, N, NRHS, LDA, LDB, LWORK
3623          INTEGER, INTENT(OUT) :: INFO, RANK
3624          INTEGER, INTENT(INOUT) :: JPVT(*)
3625          REAL(WP), INTENT(IN) :: RCOND
3626          REAL(WP), INTENT(INOUT) :: A(LDA,*), B(*)
3627          REAL(WP), INTENT(OUT) ::  WORK(*)
3628          INTERFACE
3629           SUBROUTINE DGELSY( M, N, NRHS, A, LDA, B, LDB, JPVT, RCOND,  &
3630     &                        RANK, WORK, LWORK, INFO )
3631          USE LA_PRECISION, ONLY: WP => DP
3632          INTEGER, INTENT(IN) :: M, N, NRHS, LDA, LDB, LWORK
3633          INTEGER, INTENT(OUT) :: INFO, RANK
3634          INTEGER, INTENT(INOUT) :: JPVT(*)
3635          REAL(WP), INTENT(IN) :: RCOND
3636          REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
3637          REAL(WP), INTENT(OUT) ::  WORK(*)
3638         END SUBROUTINE DGELSY
3639        END INTERFACE
3640         CALL DGELSY( M, N, NRHS, A, LDA, B, LDB, JPVT, RCOND, RANK,    &
3641     &                WORK, LWORK, INFO )
3642       END SUBROUTINE DGELSY1
3643
3644       SUBROUTINE DGELSD1( M, N, NRHS, A, LDA, B, LDB, S, RCOND, RANK,  &
3645     &                     WORK, LWORK, IWORK, INFO )
3646         USE LA_PRECISION, ONLY: WP =>  DP
3647         INTEGER, INTENT(IN) :: NRHS, M, N, LDA, LDB, LWORK
3648         INTEGER, INTENT(OUT) :: INFO, RANK
3649         REAL(WP), INTENT(IN) :: RCOND
3650         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(*)
3651         REAL(WP), INTENT(OUT) :: S(*)
3652         REAL(WP), INTENT(OUT) :: WORK(*)
3653         INTEGER :: IWORK(*)
3654         INTERFACE
3655           SUBROUTINE DGELSD( M, N, NRHS, A, LDA, B, LDB, S, RCOND,     &
3656     &                        RANK, WORK, LWORK, IWORK, INFO )
3657           USE LA_PRECISION, ONLY: WP => DP
3658           INTEGER, INTENT(IN) :: NRHS, M, N, LDA, LDB, LWORK
3659           INTEGER, INTENT(OUT) :: INFO, RANK
3660           REAL(WP), INTENT(IN) :: RCOND
3661           REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
3662           REAL(WP), INTENT(OUT) :: S(*)
3663           REAL(WP), INTENT(OUT) :: WORK(*)
3664           INTEGER :: IWORK(*)
3665         END SUBROUTINE DGELSD
3666       END INTERFACE
3667         CALL DGELSD ( M, N, NRHS, A, LDA, B, LDB, S, RCOND, RANK, WORK,&
3668     &                 LWORK, IWORK, INFO )
3669       END SUBROUTINE DGELSD1
3670
3671
3672       SUBROUTINE DGELSX1( M, N, NRHS, A, LDA, B, LDB, JPVT, RCOND,     &
3673     &                     RANK, WORK, INFO )
3674         USE LA_PRECISION, ONLY: WP => DP
3675         INTEGER, INTENT(IN) :: NRHS, M, N, LDA, LDB
3676         INTEGER, INTENT(OUT) :: INFO, RANK
3677         INTEGER, INTENT(INOUT) :: JPVT(*)
3678         REAL(WP), INTENT(IN) :: RCOND
3679         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(*)
3680         REAL(WP), INTENT(OUT) :: WORK(*)
3681         INTERFACE
3682           SUBROUTINE DGELSX( M, N, NRHS, A, LDA, B, LDB, JPVT, RCOND,  &
3683     &                        RANK, WORK, INFO )
3684             USE LA_PRECISION, ONLY: WP => DP
3685             INTEGER, INTENT(IN) :: NRHS, M, N, LDA, LDB
3686             INTEGER, INTENT(OUT) :: INFO, RANK
3687             INTEGER, INTENT(INOUT) :: JPVT(*)
3688             REAL(WP), INTENT(IN) :: RCOND
3689             REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
3690             REAL(WP), INTENT(OUT) :: WORK(*)
3691           END SUBROUTINE DGELSX
3692         END INTERFACE
3693         CALL DGELSX( M, N, NRHS, A, LDA, B, LDB, JPVT, RCOND, RANK,    &
3694     &                WORK, INFO )
3695      END SUBROUTINE DGELSX1
3696
3697
3698       SUBROUTINE DGELSS1( M, N, NRHS, A, LDA, B, LDB, S, RCOND, RANK,  &
3699     &                     WORK, LWORK, INFO )
3700         USE LA_PRECISION, ONLY: WP => DP
3701         INTEGER, INTENT(IN) :: NRHS, M, N, LDA, LDB, LWORK
3702         INTEGER, INTENT(OUT) :: INFO, RANK
3703         REAL(WP), INTENT(IN) :: RCOND
3704         REAL(WP), INTENT(INOUT) :: A(LDA,*), B(*)
3705         REAL(WP), INTENT(OUT) :: S(*)
3706         REAL(WP), INTENT(OUT) :: WORK(*)
3707         INTERFACE
3708           SUBROUTINE DGELSS( M, N, NRHS, A, LDA, B, LDB, S, RCOND,     &
3709     &                        RANK, WORK, LWORK, INFO )
3710             USE LA_PRECISION, ONLY: WP => DP
3711             INTEGER, INTENT(IN) :: NRHS, M, N, LDA, LDB, LWORK
3712             INTEGER, INTENT(OUT) :: INFO, RANK
3713             REAL(WP), INTENT(IN) :: RCOND
3714             REAL(WP), INTENT(INOUT) :: A(LDA,*), B(LDB,*)
3715             REAL(WP), INTENT(OUT) :: S(*)
3716             REAL(WP), INTENT(OUT) :: WORK(*)
3717           END SUBROUTINE DGELSS
3718         END INTERFACE
3719         CALL DGELSS( M, N, NRHS, A, LDA, B, LDB, S, RCOND, RANK, WORK, &
3720     &                LWORK, INFO )
3721      END SUBROUTINE DGELSS1
3722
3723       SUBROUTINE DGETRS1( TRANS, N, NRHS, A, LDA, PIV, B, LDB, INFO )
3724          USE LA_PRECISION, ONLY: WP => DP
3725          CHARACTER(LEN=1), INTENT(IN) :: TRANS
3726          INTEGER, INTENT(IN) :: LDA, LDB, NRHS, N
3727          INTEGER, INTENT(OUT) :: INFO
3728          INTEGER, INTENT(IN) :: PIV(*)
3729          REAL(WP), INTENT(IN) :: A(LDA,*)
3730          REAL(WP), INTENT(INOUT) :: B(*)
3731          INTERFACE
3732             SUBROUTINE DGETRS( TRANS, N, NRHS, A, LDA, PIV, B, LDB,    &
3733     &                          INFO )
3734               USE LA_PRECISION, ONLY: WP => DP
3735               CHARACTER(LEN=1), INTENT(IN) :: TRANS
3736               INTEGER, INTENT(IN) :: LDA, LDB, NRHS, N
3737               INTEGER, INTENT(OUT) :: INFO
3738               INTEGER, INTENT(IN) :: PIV(*)
3739               REAL(WP), INTENT(IN) :: A(LDA,*)
3740               REAL(WP), INTENT(INOUT) :: B(LDB,*)
3741            END SUBROUTINE DGETRS
3742          END INTERFACE
3743          CALL DGETRS( TRANS, N, NRHS, A, LDA, PIV, B, LDB, INFO )
3744       END SUBROUTINE DGETRS1
3745
3746       SUBROUTINE DGERFS1( TRANS, N, NRHS, A, LDA, AF, LDAF, PIV, B,    &
3747     &                     LDB, X, LDX, FERR, BERR, WORK, IWORK, INFO )
3748           USE LA_PRECISION, ONLY: WP => DP
3749           CHARACTER(LEN=1), INTENT(IN) :: TRANS
3750           INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, NRHS, N
3751           INTEGER, INTENT(OUT) :: INFO
3752           INTEGER, INTENT(IN) :: PIV(*)
3753           INTEGER, INTENT(OUT) :: IWORK(*)
3754           REAL(WP), INTENT(OUT) :: FERR, BERR
3755           REAL(WP), INTENT(OUT) :: WORK(*)
3756           REAL(WP), INTENT(IN) :: A(LDA,*), AF(LDAF,*), B(*)
3757           REAL(WP), INTENT(INOUT) :: X(*)
3758           INTERFACE
3759              SUBROUTINE DGERFS( TRANS, N, NRHS, A, LDA, AF, LDAF, PIV, &
3760     &                           B, LDB, X, LDX, FERR, BERR, WORK,      &
3761     &                           IWORK, INFO )
3762                 USE LA_PRECISION, ONLY: WP => DP
3763                 CHARACTER(LEN=1), INTENT(IN) :: TRANS
3764                 INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, NRHS, N
3765                 INTEGER, INTENT(OUT) :: INFO
3766                 INTEGER, INTENT(IN) :: PIV(*)
3767                 INTEGER, INTENT(OUT) :: IWORK(*)
3768                 REAL(WP), INTENT(OUT) :: FERR(*), BERR(*)
3769                 REAL(WP), INTENT(OUT) :: WORK(*)
3770                 REAL(WP), INTENT(IN) :: A(LDA,*), AF(LDAF,*), B(LDB,*)
3771                 REAL(WP), INTENT(INOUT) :: X(LDX,*)
3772              END SUBROUTINE DGERFS
3773           END INTERFACE
3774           REAL(WP) FERR1(1), BERR1(1)
3775           CALL DGERFS( TRANS, N, NRHS, A, LDA, AF, LDAF, PIV, B, LDB,  &
3776     &                  X, LDX, FERR1, BERR1, WORK, IWORK, INFO )
3777           FERR = FERR1(1); BERR = BERR1(1)
3778        END SUBROUTINE DGERFS1
3779
3780
3781      SUBROUTINE DGBTRS1( TRANS, N, KL, KU, NRHS, AB, LDAB, IPIV, B,    &
3782     &                    LDB, INFO )
3783         USE LA_PRECISION, ONLY: WP => DP
3784         CHARACTER(LEN=1), INTENT(IN) :: TRANS
3785         INTEGER, INTENT(IN) :: KL, KU, LDAB, LDB, N, NRHS
3786         INTEGER, INTENT(OUT) :: INFO
3787         INTEGER, INTENT(INOUT) :: IPIV(*)
3788         REAL(WP), INTENT(INOUT) :: AB( LDAB,*), B(*)
3789         INTERFACE
3790            SUBROUTINE DGBTRS( TRANS, N, KL, KU, NRHS, AB, LDAB, IPIV,  &
3791     &                         B, LDB, INFO )
3792               USE LA_PRECISION, ONLY: WP => DP
3793               CHARACTER(LEN=1), INTENT(IN) :: TRANS
3794               INTEGER, INTENT(IN) :: KL, KU, LDAB, LDB, N, NRHS
3795               INTEGER, INTENT(OUT) :: INFO
3796               INTEGER, INTENT(INOUT) :: IPIV(*)
3797               REAL(WP), INTENT(INOUT) :: AB( LDAB,*), B(LDB,*)
3798            END SUBROUTINE DGBTRS
3799         END INTERFACE
3800         CALL DGBTRS( TRANS, N, KL, KU, NRHS, AB, LDAB, IPIV, B, LDB,   &
3801     &                INFO )
3802      END SUBROUTINE DGBTRS1
3803
3804      SUBROUTINE DGBRFS1( TRANS, N, KL, KU, NRHS, AB, LDAB, AFB, LDAFB, &
3805     &                    IPIV, B, LDB, X, LDX, FERR, BERR, WORK, IWORK,&
3806     &                    INFO )
3807         USE LA_PRECISION, ONLY: WP => DP
3808         CHARACTER(LEN=1), INTENT(IN) :: TRANS
3809         INTEGER, INTENT(IN) :: KL, KU, LDAB, LDAFB, LDB, LDX, N, NRHS
3810         INTEGER, INTENT(OUT) :: INFO
3811         INTEGER, INTENT(IN) :: IPIV(*)
3812         INTEGER, INTENT(OUT) :: IWORK(*)
3813         REAL(WP), INTENT(OUT) :: BERR, FERR
3814         REAL(WP), INTENT(IN) :: AB( LDAB,*), AFB( LDAFB,*), B(*)
3815         REAL(WP), INTENT(OUT) :: WORK(*)
3816         REAL(WP), INTENT(INOUT) :: X(*)
3817         INTERFACE
3818            SUBROUTINE DGBRFS( TRANS, N, KL, KU, NRHS, AB, LDAB, AFB,   &
3819     &                         LDAFB, IPIV, B, LDB, X, LDX, FERR, BERR, &
3820     &                         WORK, IWORK, INFO )
3821               USE LA_PRECISION, ONLY: WP => DP
3822               CHARACTER(LEN=1), INTENT(IN) :: TRANS
3823               INTEGER, INTENT(IN) :: KL, KU, LDAB, LDAFB, LDB, LDX, N, &
3824     &                                NRHS
3825               INTEGER, INTENT(OUT) :: INFO
3826               INTEGER, INTENT(IN) :: IPIV(*)
3827               INTEGER, INTENT(OUT) :: IWORK(*)
3828               REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
3829               REAL(WP), INTENT(IN) :: AB( LDAB,*), AFB( LDAFB,*),      &
3830     &                                 B( LDB,*)
3831               REAL(WP), INTENT(OUT) :: WORK(*)
3832               REAL(WP), INTENT(INOUT) :: X( LDX,*)
3833            END SUBROUTINE DGBRFS
3834         END INTERFACE
3835         REAL(WP) :: FERR1(1), BERR1(1)
3836         CALL DGBRFS( TRANS, N, KL, KU, NRHS, AB, LDAB, AFB, LDAFB,     &
3837     &                IPIV, B, LDB, X, LDX, FERR1, BERR1, WORK, IWORK,  &
3838     &                INFO )
3839         FERR = FERR1(1); BERR = BERR1(1)
3840      END SUBROUTINE DGBRFS1
3841
3842
3843      SUBROUTINE DGTTRS1( TRANS, N, NRHS, DL, D, DU, DU2, IPIV, B, LDB, &
3844     &                    INFO )
3845         USE LA_PRECISION, ONLY: WP => DP
3846         CHARACTER(LEN=1), INTENT(IN) :: TRANS
3847         INTEGER, INTENT(IN) :: LDB, N, NRHS
3848         INTEGER, INTENT(OUT) :: INFO
3849         INTEGER, INTENT(OUT) :: IPIV(*)
3850         REAL(WP), INTENT(IN) :: D(*), DL(*), DU(*), DU2(*)
3851         REAL(WP), INTENT(INOUT) :: B(*)
3852         INTERFACE
3853            SUBROUTINE DGTTRS( TRANS, N, NRHS, DL, D, DU, DU2, IPIV, B, &
3854     &                         LDB, INFO )
3855               USE LA_PRECISION, ONLY: WP => DP
3856               CHARACTER(LEN=1), INTENT(IN) :: TRANS
3857               INTEGER, INTENT(IN) :: LDB, N, NRHS
3858               INTEGER, INTENT(OUT) :: INFO
3859               INTEGER, INTENT(OUT) :: IPIV(*)
3860               REAL(WP), INTENT(IN) :: D(*), DL(*), DU(*), DU2(*)
3861               REAL(WP), INTENT(INOUT) :: B( LDB,*)
3862            END SUBROUTINE DGTTRS
3863         END INTERFACE
3864         CALL DGTTRS( TRANS, N, NRHS, DL, D, DU, DU2, IPIV, B, LDB,     &
3865     &                INFO )
3866      END SUBROUTINE DGTTRS1
3867
3868      SUBROUTINE DGTRFS1( TRANS, N, NRHS, DL, D, DU, DLF, DF, DUF, DU2, &
3869     &                    IPIV, B, LDB, X, LDX, FERR, BERR, WORK, IWORK,&
3870     &                    INFO )
3871         USE LA_PRECISION, ONLY: WP => DP
3872         CHARACTER(LEN=1), INTENT(IN) :: TRANS
3873         INTEGER, INTENT(IN) :: LDB, LDX, N, NRHS, IPIV(*)
3874         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
3875         REAL(WP), INTENT(OUT) :: BERR, FERR
3876         REAL(WP), INTENT(IN) :: B(*), D(*), DF(*), DL(*), DLF(*),      &
3877     &                           DU(*), DU2(*), DUF(*)
3878         REAL(WP), INTENT(INOUT) :: X(*)
3879         REAL(WP), INTENT(OUT) :: WORK(*)
3880         INTERFACE
3881            SUBROUTINE DGTRFS( TRANS, N, NRHS, DL, D, DU, DLF, DF, DUF, &
3882     &                         DU2, IPIV, B, LDB, X, LDX, FERR, BERR,   &
3883     &                         WORK, IWORK, INFO )
3884               USE LA_PRECISION, ONLY: WP => DP
3885               CHARACTER(LEN=1), INTENT(IN) :: TRANS
3886               INTEGER, INTENT(IN) :: LDB, LDX, N, NRHS, IPIV(*)
3887               INTEGER, INTENT(OUT) :: INFO, IWORK(*)
3888               REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
3889               REAL(WP), INTENT(IN) :: B( LDB,*), D(*), DF(*), DL(*),   &
3890     &                                 DLF(*), DU(*), DU2(*), DUF(*)
3891               REAL(WP), INTENT(INOUT) :: X( LDX,*)
3892               REAL(WP), INTENT(OUT) :: WORK(*)
3893            END SUBROUTINE DGTRFS
3894         END INTERFACE
3895         REAL(WP) :: FERR1(1), BERR1(1)
3896         CALL DGTRFS( TRANS, N, NRHS, DL, D, DU, DLF, DF, DUF, DU2,     &
3897     &                IPIV, B, LDB, X, LDX, FERR1, BERR1, WORK, IWORK,  &
3898     &                INFO )
3899         FERR = FERR1(1); BERR = BERR1(1)
3900      END SUBROUTINE DGTRFS1
3901
3902
3903      SUBROUTINE DPOTRS1( UPLO, N, NRHS, A, LDA, B, LDB, INFO )
3904         USE LA_PRECISION, ONLY: WP => DP
3905         CHARACTER(LEN=1), INTENT(IN) :: UPLO
3906         INTEGER, INTENT(IN) :: LDA, LDB, N, NRHS
3907         INTEGER, INTENT(OUT) :: INFO
3908         REAL(WP), INTENT(IN) :: A( LDA,*)
3909         REAL(WP), INTENT(INOUT) :: B(*)
3910         INTERFACE
3911            SUBROUTINE DPOTRS( UPLO, N, NRHS, A, LDA, B, LDB, INFO )
3912               USE LA_PRECISION, ONLY: WP => DP
3913               CHARACTER(LEN=1), INTENT(IN) :: UPLO
3914               INTEGER, INTENT(IN) :: LDA, LDB, N, NRHS
3915               INTEGER, INTENT(OUT) :: INFO
3916               REAL(WP), INTENT(IN) :: A( LDA,*)
3917               REAL(WP), INTENT(INOUT) :: B( LDB,*)
3918            END SUBROUTINE DPOTRS
3919         END INTERFACE
3920         CALL DPOTRS( UPLO, N, NRHS, A, LDA, B, LDB, INFO )
3921      END SUBROUTINE DPOTRS1
3922
3923
3924      SUBROUTINE DPORFS1( UPLO, N, NRHS, A, LDA, AF, LDAF, B, LDB, X,   &
3925     &                    LDX, FERR, BERR, WORK, IWORK, INFO )
3926         USE LA_PRECISION, ONLY: WP => DP
3927         CHARACTER(LEN=1), INTENT(IN) :: UPLO
3928         INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, N, NRHS
3929         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
3930         REAL(WP), INTENT(OUT) :: BERR, FERR
3931         REAL(WP), INTENT(IN) :: A(*), AF( LDAF,*), B( LDB,*)
3932         REAL(WP), INTENT(INOUT) :: X(*)
3933         REAL(WP), INTENT(OUT) :: WORK(*)
3934         INTERFACE
3935            SUBROUTINE DPORFS( UPLO, N, NRHS, A, LDA, AF, LDAF, B, LDB, &
3936     &                         X, LDX, FERR, BERR, WORK, IWORK, INFO )
3937               USE LA_PRECISION, ONLY: WP => DP
3938               CHARACTER(LEN=1), INTENT(IN) :: UPLO
3939               INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, N, NRHS
3940               INTEGER, INTENT(OUT) :: INFO, IWORK(*)
3941               REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
3942               REAL(WP), INTENT(IN) :: A( LDA,*), AF( LDAF,*),          &
3943     &                                 B( LDB,*)
3944               REAL(WP), INTENT(INOUT) :: X( LDX,*)
3945               REAL(WP), INTENT(OUT) :: WORK(*)
3946            END SUBROUTINE DPORFS
3947         END INTERFACE
3948         REAL(WP) :: BERR1(1), FERR1(1)
3949         CALL DPORFS( UPLO, N, NRHS, A, LDA, AF, LDAF, B, LDB, X, LDX,  &
3950     &                FERR1, BERR1, WORK, IWORK, INFO )
3951         BERR = BERR1(1); FERR = FERR1(1)
3952      END SUBROUTINE DPORFS1
3953
3954
3955      SUBROUTINE DPPTRS1( UPLO, N, NRHS, AP, B, LDB, INFO )
3956         USE LA_PRECISION, ONLY: WP => DP
3957         CHARACTER(LEN=1), INTENT(IN) :: UPLO
3958         INTEGER, INTENT(IN) :: LDB, N, NRHS
3959         INTEGER, INTENT(OUT) :: INFO
3960         REAL(WP), INTENT(IN) :: AP(*)
3961         REAL(WP), INTENT(INOUT) :: B(*)
3962         INTERFACE
3963            SUBROUTINE DPPTRS( UPLO, N, NRHS, AP, B, LDB, INFO )
3964               USE LA_PRECISION, ONLY: WP => DP
3965               CHARACTER(LEN=1), INTENT(IN) :: UPLO
3966               INTEGER, INTENT(IN) :: LDB, N, NRHS
3967               INTEGER, INTENT(OUT) :: INFO
3968               REAL(WP), INTENT(IN) :: AP(*)
3969               REAL(WP), INTENT(INOUT) :: B( LDB,*)
3970            END SUBROUTINE DPPTRS
3971         END INTERFACE
3972         CALL DPPTRS( UPLO, N, NRHS, AP, B, LDB, INFO )
3973      END SUBROUTINE DPPTRS1
3974
3975
3976      SUBROUTINE DPPRFS1( UPLO, N, NRHS, AP, AFP, B, LDB, X, LDX, FERR, &
3977     &                    BERR, WORK, IWORK, INFO )
3978         USE LA_PRECISION, ONLY: WP => DP
3979         CHARACTER(LEN=1), INTENT(IN) :: UPLO
3980         INTEGER, INTENT(IN) :: LDB, LDX, N, NRHS
3981         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
3982         REAL(WP), INTENT(OUT) :: BERR, FERR
3983         REAL(WP), INTENT(IN) :: AFP(*), AP(*), B(*)
3984         REAL(WP), INTENT(INOUT) :: X(*)
3985         REAL(WP), INTENT(OUT) :: WORK(*)
3986         INTERFACE
3987            SUBROUTINE DPPRFS( UPLO, N, NRHS, AP, AFP, B, LDB, X, LDX,  &
3988     &                         FERR, BERR, WORK, IWORK, INFO )
3989               USE LA_PRECISION, ONLY: WP => DP
3990               CHARACTER(LEN=1), INTENT(IN) :: UPLO
3991               INTEGER, INTENT(IN) :: LDB, LDX, N, NRHS
3992               INTEGER, INTENT(OUT) :: INFO, IWORK(*)
3993               REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
3994               REAL(WP), INTENT(IN) :: AFP(*), AP(*), B( LDB,*)
3995               REAL(WP), INTENT(INOUT) :: X( LDX,*)
3996               REAL(WP), INTENT(OUT) :: WORK(*)
3997            END SUBROUTINE DPPRFS
3998         END INTERFACE
3999         REAL(WP) :: BERR1(1), FERR1(1)
4000         CALL DPPRFS( UPLO, N, NRHS, AP, AFP, B, LDB, X, LDX, FERR1,    &
4001     &                BERR1, WORK, IWORK, INFO )
4002         BERR = BERR1(1); FERR = FERR1(1)
4003      END SUBROUTINE DPPRFS1
4004
4005      SUBROUTINE DPBTRS1( UPLO, N, KD, NRHS, AB, LDAB, B, LDB, INFO )
4006         USE LA_PRECISION, ONLY: WP => DP
4007         CHARACTER(LEN=1), INTENT(IN) :: UPLO
4008         INTEGER, INTENT(IN) :: KD, LDAB, LDB, N, NRHS
4009         INTEGER, INTENT(OUT) :: INFO
4010         REAL(WP), INTENT(IN) :: AB( LDAB,*)
4011         REAL(WP), INTENT(INOUT) :: B(*)
4012         INTERFACE
4013            SUBROUTINE DPBTRS( UPLO, N, KD, NRHS, AB, LDAB, B, LDB,     &
4014     &                         INFO )
4015               USE LA_PRECISION, ONLY: WP => DP
4016               CHARACTER(LEN=1), INTENT(IN) :: UPLO
4017               INTEGER, INTENT(IN) :: KD, LDAB, LDB, N, NRHS
4018               INTEGER, INTENT(OUT) :: INFO
4019               REAL(WP), INTENT(IN) :: AB( LDAB,*)
4020               REAL(WP), INTENT(INOUT) :: B( LDB,*)
4021            END SUBROUTINE DPBTRS
4022         END INTERFACE
4023         CALL DPBTRS( UPLO, N, KD, NRHS, AB, LDAB, B, LDB, INFO )
4024      END SUBROUTINE DPBTRS1
4025
4026
4027      SUBROUTINE DPBRFS1( UPLO, N, KD, NRHS, AB, LDAB, AFB, LDAFB, B,   &
4028     &                    LDB, X, LDX, FERR, BERR, WORK, IWORK, INFO )
4029         USE LA_PRECISION, ONLY: WP => DP
4030         CHARACTER(LEN=1), INTENT(IN) :: UPLO
4031         INTEGER, INTENT(IN) ::  KD, LDAB, LDAFB, LDB, LDX, N, NRHS
4032         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
4033         REAL(WP), INTENT(OUT) :: BERR, FERR
4034         REAL(WP), INTENT(IN) ::  AB( LDAB,*), AFB( LDAFB,*), B(*)
4035         REAL(WP), INTENT(INOUT) :: X(*)
4036         REAL(WP), INTENT(OUT) :: WORK(*)
4037         INTERFACE
4038            SUBROUTINE DPBRFS( UPLO, N, KD, NRHS, AB, LDAB, AFB, LDAFB, &
4039     &                         B, LDB, X, LDX, FERR, BERR, WORK, IWORK, &
4040     &                         INFO )
4041               USE LA_PRECISION, ONLY: WP => DP
4042               CHARACTER(LEN=1), INTENT(IN) :: UPLO
4043               INTEGER, INTENT(IN) ::  KD, LDAB, LDAFB, LDB, LDX, N,    &
4044     &                                 NRHS
4045               INTEGER, INTENT(OUT) :: INFO, IWORK(*)
4046               REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
4047               REAL(WP), INTENT(IN) ::  AB( LDAB,*), AFB( LDAFB,*),     &
4048     &                                  B( LDB,*)
4049               REAL(WP), INTENT(INOUT) :: X( LDX,*)
4050               REAL(WP), INTENT(OUT) :: WORK(*)
4051            END SUBROUTINE DPBRFS
4052         END INTERFACE
4053         REAL(WP) :: FERR1(1), BERR1(1)
4054         CALL DPBRFS( UPLO, N, KD, NRHS, AB, LDAB, AFB, LDAFB, B, LDB,  &
4055     &                X, LDX, FERR1, BERR1, WORK, IWORK, INFO )
4056         FERR = FERR1(1); BERR = BERR1(1)
4057      END SUBROUTINE DPBRFS1
4058
4059
4060      SUBROUTINE DPTTRS1( N, NRHS, D, E, B, LDB, INFO )
4061         USE LA_PRECISION, ONLY: WP => DP
4062         INTEGER, INTENT(IN) :: LDB, N, NRHS
4063         INTEGER, INTENT(OUT) :: INFO
4064         REAL(WP), INTENT(IN) :: D(*)
4065         REAL(WP), INTENT(IN) :: E(*)
4066         REAL(WP), INTENT(OUT) :: B(*)
4067         INTERFACE
4068            SUBROUTINE DPTTRS( N, NRHS, D, E, B, LDB, INFO )
4069               USE LA_PRECISION, ONLY: WP => DP
4070               INTEGER, INTENT(IN) :: LDB, N, NRHS
4071               INTEGER, INTENT(OUT) :: INFO
4072               REAL(WP), INTENT(IN) :: D(*)
4073               REAL(WP), INTENT(IN) :: E(*)
4074               REAL(WP), INTENT(OUT) :: B( LDB,*)
4075            END SUBROUTINE DPTTRS
4076         END INTERFACE
4077         CALL DPTTRS( N, NRHS, D, E, B, LDB, INFO )
4078      END SUBROUTINE DPTTRS1
4079
4080
4081      SUBROUTINE DPTRFS1( N, NRHS, D, E, DF, EF, B, LDB, X, LDX, FERR,  &
4082     &                    BERR, WORK, INFO )
4083         USE LA_PRECISION, ONLY: WP => DP
4084         INTEGER, INTENT(IN) :: LDB, LDX, N, NRHS
4085         INTEGER, INTENT(OUT) :: INFO
4086         REAL(WP), INTENT(IN) :: D(*), DF(*)
4087         REAL(WP), INTENT(OUT) :: BERR, FERR
4088         REAL(WP), INTENT(IN) :: B(*), E(*), EF(*)
4089         REAL(WP), INTENT(INOUT) :: X(*)
4090         REAL(WP), INTENT(OUT) :: WORK(*)
4091         INTERFACE
4092            SUBROUTINE DPTRFS( N, NRHS, D, E, DF, EF, B, LDB, X, LDX,   &
4093     &                         FERR, BERR, WORK, INFO )
4094               USE LA_PRECISION, ONLY: WP => DP
4095               INTEGER, INTENT(IN) :: LDB, LDX, N, NRHS
4096               INTEGER, INTENT(OUT) :: INFO
4097               REAL(WP), INTENT(IN) :: D(*), DF(*)
4098               REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
4099               REAL(WP), INTENT(IN) :: B( LDB,*), E(*), EF(*)
4100               REAL(WP), INTENT(INOUT) :: X( LDX,*)
4101               REAL(WP), INTENT(OUT) :: WORK(*)
4102            END SUBROUTINE DPTRFS
4103         END INTERFACE
4104         REAL(WP) FERR1(1), BERR1(1)
4105         CALL DPTRFS( N, NRHS, D, E, DF, EF, B, LDB, X, LDX, FERR1,     &
4106     &                BERR1, WORK, INFO )
4107      FERR = FERR1(1); BERR = BERR1(1)
4108      END SUBROUTINE DPTRFS1
4109
4110      SUBROUTINE DSYTRS1( UPLO, N, NRHS, A, LDA, IPIV, B, LDB, INFO )
4111         USE LA_PRECISION, ONLY: WP => DP
4112         CHARACTER(LEN=1), INTENT(IN) :: UPLO
4113         INTEGER, INTENT(IN) :: LDA, LDB, N, NRHS
4114         INTEGER, INTENT(OUT) :: INFO
4115         INTEGER , INTENT(IN) :: IPIV(*)
4116         REAL(WP), INTENT(IN) :: A( LDA,*)
4117         REAL(WP), INTENT(INOUT) :: B(*)
4118         INTERFACE
4119            SUBROUTINE DSYTRS( UPLO, N, NRHS, A, LDA, IPIV, B, LDB,     &
4120     &                         INFO )
4121               USE LA_PRECISION, ONLY: WP => DP
4122               CHARACTER(LEN=1), INTENT(IN) :: UPLO
4123               INTEGER, INTENT(IN) :: LDA, LDB, N, NRHS
4124               INTEGER, INTENT(OUT) :: INFO
4125               INTEGER , INTENT(IN) :: IPIV(*)
4126               REAL(WP), INTENT(IN) :: A( LDA,*)
4127               REAL(WP), INTENT(INOUT) :: B( LDB,*)
4128            END SUBROUTINE DSYTRS
4129         END INTERFACE
4130         CALL DSYTRS( UPLO, N, NRHS, A, LDA, IPIV, B, LDB, INFO )
4131      END SUBROUTINE DSYTRS1
4132
4133      SUBROUTINE DSYRFS1( UPLO, N, NRHS, A, LDA, AF, LDAF, IPIV, B, LDB,&
4134     &                    X, LDX, FERR, BERR, WORK, IWORK, INFO )
4135         USE LA_PRECISION, ONLY: WP => DP
4136         CHARACTER(LEN=1), INTENT(IN) :: UPLO
4137         INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, N, NRHS
4138         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
4139         INTEGER, INTENT(IN) :: IPIV(*)
4140         REAL(WP), INTENT(OUT) :: BERR, FERR
4141         REAL(WP), INTENT(IN) ::  A( LDA,*), AF( LDAF,*), B(*)
4142         REAL(WP), INTENT(INOUT) :: X(*)
4143         REAL(WP), INTENT(OUT) :: WORK(*)
4144         INTERFACE
4145            SUBROUTINE DSYRFS( UPLO, N, NRHS, A, LDA, AF, LDAF, IPIV, B,&
4146     &                         LDB, X, LDX, FERR, BERR, WORK, IWORK,    &
4147     &                         INFO )
4148               USE LA_PRECISION, ONLY: WP => DP
4149               CHARACTER(LEN=1), INTENT(IN) :: UPLO
4150               INTEGER, INTENT(IN) :: LDA, LDAF, LDB, LDX, N, NRHS
4151               INTEGER, INTENT(OUT) :: INFO, IWORK(*)
4152               INTEGER, INTENT(IN) :: IPIV(*)
4153               REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
4154               REAL(WP), INTENT(IN) ::  A( LDA,*), AF( LDAF,*),         &
4155     &                                  B( LDB,*)
4156               REAL(WP), INTENT(INOUT) :: X( LDX,*)
4157               REAL(WP), INTENT(OUT) :: WORK(*)
4158            END SUBROUTINE DSYRFS
4159         END INTERFACE
4160         REAL(WP) FERR1(1), BERR1(1)
4161         CALL DSYRFS( UPLO, N, NRHS, A, LDA, AF, LDAF, IPIV, B, LDB, X, &
4162     &                LDX, FERR1, BERR1, WORK, IWORK, INFO )
4163         FERR = FERR1(1); BERR = BERR1(1)
4164      END SUBROUTINE DSYRFS1
4165
4166      SUBROUTINE DSPTRS1( UPLO, N, NRHS, AP, IPIV, B, LDB, INFO )
4167         USE LA_PRECISION, ONLY: WP => DP
4168         CHARACTER(LEN=1), INTENT(IN) :: UPLO
4169         INTEGER, INTENT(IN) :: LDB, N, NRHS
4170         INTEGER, INTENT(OUT) :: INFO
4171         INTEGER, INTENT(IN) :: IPIV(*)
4172         REAL(WP), INTENT(IN) :: AP(*)
4173         REAL(WP), INTENT(INOUT) :: B(*)
4174         INTERFACE
4175            SUBROUTINE DSPTRS( UPLO, N, NRHS, AP, IPIV, B, LDB, INFO )
4176               USE LA_PRECISION, ONLY: WP => DP
4177               CHARACTER(LEN=1), INTENT(IN) :: UPLO
4178               INTEGER, INTENT(IN) :: LDB, N, NRHS
4179               INTEGER, INTENT(OUT) :: INFO
4180               INTEGER, INTENT(IN) :: IPIV(*)
4181               REAL(WP), INTENT(IN) :: AP(*)
4182               REAL(WP), INTENT(INOUT) :: B(LDB,*)
4183            END SUBROUTINE DSPTRS
4184         ENDINTERFACE
4185         CALL DSPTRS( UPLO, N, NRHS, AP, IPIV, B, LDB, INFO )
4186      END SUBROUTINE DSPTRS1
4187
4188      SUBROUTINE DSPRFS1( UPLO, N, NRHS, AP, AFP, IPIV, B, LDB, X, LDX, &
4189     &                    FERR, BERR, WORK, IWORK, INFO )
4190         USE LA_PRECISION, ONLY: WP => DP
4191         CHARACTER(LEN=1), INTENT(IN) :: UPLO
4192         INTEGER, INTENT(IN) :: LDB, LDX, N, NRHS
4193         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
4194         INTEGER, INTENT(IN) :: IPIV(*)
4195         REAL(WP), INTENT(OUT) :: BERR, FERR
4196         REAL(WP), INTENT(IN) :: AFP(*), AP(*), B(LDB,*)
4197         REAL(WP), INTENT(INOUT) :: X(LDX,*)
4198         REAL(WP), INTENT(OUT) :: WORK(*)
4199         INTERFACE
4200            SUBROUTINE DSPRFS( UPLO, N, NRHS, AP, AFP, IPIV, B, LDB, X, &
4201     &                         LDX, FERR, BERR, WORK, IWORK, INFO )
4202               USE LA_PRECISION, ONLY: WP => DP
4203               CHARACTER(LEN=1), INTENT(IN) :: UPLO
4204               INTEGER, INTENT(IN) :: LDB, LDX, N, NRHS
4205               INTEGER, INTENT(OUT) :: INFO, IWORK(*)
4206               INTEGER, INTENT(IN) :: IPIV(*)
4207               REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
4208               REAL(WP), INTENT(IN) :: AFP(*), AP(*), B(LDB,*)
4209               REAL(WP), INTENT(INOUT) :: X(LDX,*)
4210               REAL(WP), INTENT(OUT) :: WORK(*)
4211            END SUBROUTINE DSPRFS
4212         END INTERFACE
4213         REAL(WP) :: FERR1(1), BERR1(1)
4214         CALL DSPRFS( UPLO, N, NRHS, AP, AFP, IPIV, B, LDB, X, LDX,     &
4215     &                FERR1, BERR1, WORK, IWORK, INFO )
4216         FERR = FERR1(1); BERR = BERR1(1)
4217      END SUBROUTINE DSPRFS1
4218
4219      SUBROUTINE DTRTRS1( UPLO, TRANS, DIAG, N, NRHS, A, LDA, B, LDB,   &
4220     &                    INFO )
4221         USE LA_PRECISION, ONLY: WP => DP
4222         CHARACTER(LEN=1), INTENT(IN) :: DIAG, TRANS, UPLO
4223         INTEGER, INTENT(IN) :: LDA, LDB, N, NRHS
4224         INTEGER, INTENT(OUT) :: INFO
4225         REAL(WP), INTENT(IN) :: A(LDA,*)
4226         REAL(WP), INTENT(INOUT) :: B(*)
4227         INTERFACE
4228            SUBROUTINE DTRTRS( UPLO, TRANS, DIAG, N, NRHS, A, LDA, B,   &
4229     &                         LDB, INFO )
4230               USE LA_PRECISION, ONLY: WP => DP
4231               CHARACTER(LEN=1), INTENT(IN) :: DIAG, TRANS, UPLO
4232               INTEGER, INTENT(IN) :: LDA, LDB, N, NRHS
4233               INTEGER, INTENT(OUT) :: INFO
4234               REAL(WP), INTENT(IN) :: A(LDA,*)
4235               REAL(WP), INTENT(INOUT) :: B(LDB,*)
4236            END SUBROUTINE DTRTRS
4237         END INTERFACE
4238         CALL DTRTRS( UPLO, TRANS, DIAG, N, NRHS, A, LDA, B, LDB,       &
4239     &                INFO )
4240      END SUBROUTINE DTRTRS1
4241
4242      SUBROUTINE DTRRFS1( UPLO, TRANS, DIAG, N, NRHS, A, LDA, B, LDB, X,&
4243     &                    LDX, FERR, BERR, WORK, IWORK, INFO )
4244         USE LA_PRECISION, ONLY: WP => DP
4245         CHARACTER(LEN=1), INTENT(IN) :: DIAG, TRANS, UPLO
4246         INTEGER, INTENT(IN) :: LDA, LDB, LDX, N, NRHS
4247         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
4248         REAL(WP), INTENT(OUT) :: BERR, FERR
4249         REAL(WP), INTENT(IN) :: A(LDA,*), B(*)
4250         REAL(WP), INTENT(INOUT) :: X(*)
4251         REAL(WP), INTENT(OUT) :: WORK(*)
4252         INTERFACE
4253            SUBROUTINE DTRRFS( UPLO, TRANS, DIAG, N, NRHS, A, LDA, B,   &
4254     &                         LDB, X, LDX, FERR, BERR, WORK, IWORK,    &
4255     &                         INFO )
4256               USE LA_PRECISION, ONLY: WP => DP
4257               CHARACTER(LEN=1), INTENT(IN) :: DIAG, TRANS, UPLO
4258               INTEGER, INTENT(IN) :: LDA, LDB, LDX, N, NRHS
4259               INTEGER, INTENT(OUT) :: INFO, IWORK(*)
4260               REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
4261               REAL(WP), INTENT(IN) :: A(LDA,*), B(LDB,*)
4262               REAL(WP), INTENT(INOUT) :: X(LDX,*)
4263               REAL(WP), INTENT(OUT) :: WORK(*)
4264            END SUBROUTINE DTRRFS
4265         END INTERFACE
4266         REAL(WP) FERR1(1), BERR1(1)
4267         CALL DTRRFS( UPLO, TRANS, DIAG, N, NRHS, A, LDA, B, LDB, X,    &
4268     &                LDX, FERR1, BERR1, WORK, IWORK, INFO )
4269         FERR = FERR1(1); BERR = BERR1(1)
4270      END SUBROUTINE DTRRFS1
4271
4272      SUBROUTINE DTPTRS1( UPLO, TRANS, DIAG, N, NRHS, AP, B, LDB,       &
4273     &                    INFO )
4274         USE LA_PRECISION, ONLY: WP => DP
4275         CHARACTER(LEN=1), INTENT(IN) :: DIAG, TRANS, UPLO
4276         INTEGER, INTENT(IN) :: LDB, N, NRHS
4277         INTEGER, INTENT(OUT) :: INFO
4278         REAL(WP), INTENT(IN) :: AP(*)
4279         REAL(WP), INTENT(INOUT) :: B(*)
4280         INTERFACE
4281            SUBROUTINE DTPTRS( UPLO, TRANS, DIAG, N, NRHS, AP, B, LDB,  &
4282     &                         INFO )
4283               USE LA_PRECISION, ONLY: WP => DP
4284               CHARACTER(LEN=1), INTENT(IN) :: DIAG, TRANS, UPLO
4285               INTEGER, INTENT(IN) :: LDB, N, NRHS
4286               INTEGER, INTENT(OUT) :: INFO
4287               REAL(WP), INTENT(IN) :: AP(*)
4288               REAL(WP), INTENT(INOUT) :: B(LDB,*)
4289            END SUBROUTINE DTPTRS
4290         END INTERFACE
4291         CALL DTPTRS( UPLO, TRANS, DIAG, N, NRHS, AP, B, LDB, INFO )
4292      END SUBROUTINE DTPTRS1
4293
4294      SUBROUTINE DTPRFS1( UPLO, TRANS, DIAG, N, NRHS, AP, B, LDB, X,    &
4295     &                    LDX, FERR, BERR, WORK, IWORK, INFO )
4296         USE LA_PRECISION, ONLY: WP => DP
4297         CHARACTER(LEN=1), INTENT(IN) :: DIAG, TRANS, UPLO
4298         INTEGER, INTENT(IN) :: LDB, LDX, N, NRHS
4299         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
4300         REAL(WP), INTENT(OUT) :: BERR, FERR
4301         REAL(WP), INTENT(IN) :: AP(*), B(*), X(*)
4302         REAL(WP), INTENT(OUT) :: WORK(*)
4303         INTERFACE
4304            SUBROUTINE DTPRFS( UPLO, TRANS, DIAG, N, NRHS, AP, B, LDB,  &
4305     &                         X, LDX, FERR, BERR, WORK, IWORK, INFO )
4306               USE LA_PRECISION, ONLY: WP => DP
4307               CHARACTER(LEN=1), INTENT(IN) :: DIAG, TRANS, UPLO
4308               INTEGER, INTENT(IN) :: LDB, LDX, N, NRHS
4309               INTEGER, INTENT(OUT) :: INFO, IWORK(*)
4310               REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
4311               REAL(WP), INTENT(IN) :: AP(*), B(LDB,*), X(LDX,*)
4312               REAL(WP), INTENT(OUT) :: WORK(*)
4313            END SUBROUTINE DTPRFS
4314         END INTERFACE
4315         REAL(WP) FERR1(1), BERR1(1)
4316         CALL DTPRFS( UPLO, TRANS, DIAG, N, NRHS, AP, B, LDB, X, LDX,   &
4317     &                FERR1, BERR1, WORK, IWORK, INFO )
4318         FERR = FERR1(1); BERR = BERR1(1)
4319      END SUBROUTINE DTPRFS1
4320
4321      SUBROUTINE DTBTRS1( UPLO, TRANS, DIAG, N, KD, NRHS, AB, LDAB, B,  &
4322     &                    LDB, INFO )
4323         USE LA_PRECISION, ONLY: WP => DP
4324         CHARACTER(LEN=1), INTENT(IN) :: DIAG, TRANS, UPLO
4325         INTEGER, INTENT(IN) :: KD, LDAB, LDB, N, NRHS
4326         INTEGER, INTENT(OUT) :: INFO
4327         REAL(WP), INTENT(IN) :: AB(LDAB,*)
4328         REAL(WP), INTENT(INOUT) :: B(*)
4329         INTERFACE
4330            SUBROUTINE DTBTRS( UPLO, TRANS, DIAG, N, KD, NRHS, AB, LDAB,&
4331     &                         B, LDB, INFO )
4332               USE LA_PRECISION, ONLY: WP => DP
4333               CHARACTER(LEN=1), INTENT(IN) :: DIAG, TRANS, UPLO
4334               INTEGER, INTENT(IN) :: KD, LDAB, LDB, N, NRHS
4335               INTEGER, INTENT(OUT) :: INFO
4336               REAL(WP), INTENT(IN) :: AB(LDAB,*)
4337               REAL(WP), INTENT(INOUT) :: B(LDB,*)
4338            END SUBROUTINE DTBTRS
4339         END INTERFACE
4340         CALL DTBTRS( UPLO, TRANS, DIAG, N, KD, NRHS, AB, LDAB, B, LDB, &
4341     &                INFO )
4342      END SUBROUTINE DTBTRS1
4343
4344      SUBROUTINE DTBRFS1( UPLO, TRANS, DIAG, N, KD, NRHS, AB, LDAB, B,  &
4345     &                    LDB, X, LDX, FERR, BERR, WORK, IWORK, INFO )
4346         USE LA_PRECISION, ONLY: WP => DP
4347         CHARACTER(LEN=1), INTENT(IN) :: DIAG, TRANS, UPLO
4348         INTEGER, INTENT(IN) :: KD, LDAB, LDB, LDX, N, NRHS
4349         INTEGER, INTENT(OUT) :: INFO, IWORK(*)
4350         REAL(WP), INTENT(OUT) :: BERR, FERR
4351         REAL(WP), INTENT(IN) :: AB(LDAB,*), B(*), X(*)
4352         REAL(WP), INTENT(IN) :: WORK(*)
4353         INTERFACE
4354            SUBROUTINE DTBRFS( UPLO, TRANS, DIAG, N, KD, NRHS, AB, LDAB,&
4355     &                         B, LDB, X, LDX, FERR, BERR, WORK, IWORK, &
4356     &                         INFO )
4357               USE LA_PRECISION, ONLY: WP => DP
4358               CHARACTER(LEN=1), INTENT(IN) :: DIAG, TRANS, UPLO
4359               INTEGER, INTENT(IN) :: KD, LDAB, LDB, LDX, N, NRHS
4360               INTEGER, INTENT(OUT) :: INFO, IWORK(*)
4361               REAL(WP), INTENT(OUT) :: BERR(*), FERR(*)
4362               REAL(WP), INTENT(IN) :: AB(LDAB,*), B(LDB,*), X(LDX,*)
4363               REAL(WP), INTENT(IN) :: WORK(*)
4364            END SUBROUTINE DTBRFS
4365         END INTERFACE
4366         REAL(WP) FERR1(1), BERR1(1)
4367         CALL DTBRFS( UPLO, TRANS, DIAG, N, KD, NRHS, AB, LDAB, B, LDB, &
4368     &                X, LDX, FERR1, BERR1, WORK, IWORK, INFO )
4369         FERR = FERR1(1); BERR = BERR1(1)
4370      END SUBROUTINE DTBRFS1
4371
4372
4373
4374      END MODULE F77_LAPACK
4375