Merge release-4-6 into master
[alexxy/gromacs.git] / src / gromacs / linearalgebra / gmx_lapack.h
1 /*
2  * 
3  *                This source code is part of
4  * 
5  *                 G   R   O   M   A   C   S
6  * 
7  *          GROningen MAchine for Chemical Simulations
8  * 
9  * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others.
10  * Copyright (c) 1991-2000, University of Groningen, The Netherlands.
11  * Copyright (c) 2001-2008, The GROMACS development team,
12  * check out http://www.gromacs.org for more information.
13  
14  * This program is free software; you can redistribute it and/or
15  * modify it under the terms of the GNU General Public License
16  * as published by the Free Software Foundation; either version 2
17  * of the License, or (at your option) any later version.
18  * 
19  * If you want to redistribute modifications, please consider that
20  * scientific software is very special. Version control is crucial -
21  * bugs must be traceable. We will be happy to consider code for
22  * inclusion in the official distribution, but derived work must not
23  * be called official GROMACS. Details are found in the README & COPYING
24  * files - if they are missing, get the official version at www.gromacs.org.
25  * 
26  * To help us fund GROMACS development, we humbly ask that you cite
27  * the papers on the package - you can find them in the top README file.
28  * 
29  * For more info, check our website at http://www.gromacs.org
30  * 
31  * And Hey:
32  * Gallium Rubidium Oxygen Manganese Argon Carbon Silicon
33  */
34 /*! \internal \file
35  * \brief
36  * Header definitions for the standard LAPACK library.
37  *
38  * This is the subset of LAPACK routines used for the
39  * linear algebra operations in Gromacs. Most of the execution time
40  * will be spent in the BLAS routines, which you hopefully have an
41  * optimized version of. Gromacs includes reference implementations
42  * of both BLAS and LAPACK so it compiles everywhere, but you should
43  * really try to find a vendor or otherwise optimized version at least
44  * of BLAS for better performance.
45  *
46  * Do NOT use this code for other purposes - we only provide this as a 
47  * simple fallback/reference implementation when no optimized BLAS 
48  * is present. If you need an implementation for your own code 
49  * there are several much faster versions out there.
50  *
51  * All routines are compatible with the LAPACK/BLAS reference implementations,
52  * meaning they assume fortran-style matrix row/column organization.
53  *
54  * There is plenty of documentation for these routines available
55  * at http://www.netlib.org/lapack , so there is no point in repeating
56  * it here.
57  */
58 #ifndef GMX_LAPACK_H
59 #define GMX_LAPACK_H
60
61 /*! \cond */
62
63 #ifdef HAVE_CONFIG_H
64 #include "config.h"
65 #endif
66 #ifndef F77_FUNC
67 #define F77_FUNC(name,NAME) name ## _
68 #endif
69
70 /* Suppress Cygwin compiler warnings from using newlib version of
71  * ctype.h */
72 #ifdef GMX_CYGWIN
73 #undef toupper
74 #endif
75
76 #ifdef __cplusplus
77 extern "C" {
78 #endif
79 #if 0
80 }
81 #endif
82
83 /* Double precision */
84
85 void
86 F77_FUNC(dbdsdc,DBDSDC)(const char *uplo, const char *compq, int *n, double *d, double *e, double *u, 
87         int *ldu, double *vt, int *ldvt, double *q, int *iq, double *work, 
88         int *iwork, int *info);
89
90 void
91 F77_FUNC(dgetf2,DGETF2)(int *m, int *n, double *a, int *lda, int *ipiv, int *info);
92
93 void
94 F77_FUNC(dlamrg,DLAMRG)(int *n1, int *n2, double *a, int *dtrd1, int *dtrd2, int *index);
95
96 void
97 F77_FUNC(dlarnv,DLARNV)(int *idist, int *iseed, int *n, double *x);
98
99 void 
100 F77_FUNC(dlasd0,DLASD0)(int *n, int *sqre, double *d, double *e, double *u, 
101         int *ldu, double *vt, int *ldvt, int *smlsiz, int *iwork, 
102         double *work, int *info);
103
104 void 
105 F77_FUNC(dlasda,DLASDA)(int *icompq, int *smlsiz, int *n, int *sqre, double *d, double *e, 
106         double *u, int *ldu, double *vt, int *k, double *difl, double *difr, 
107         double *z, double *poles, int *givptr, int *givcol, int *ldgcol, 
108         int *perm, double *givnum, double *c, double *s, 
109         double *work, int *iwork, int *info);
110
111 void 
112 F77_FUNC(dlasq6,DLASQ6)(int *i0, int *n0, double *z, int *pp, double *dmin, double *dmin1, 
113         double *dmin2, double *dn, double *dnm1, double *dnm2);
114
115 void
116 F77_FUNC(dorgl2,DORGL2)(int *m, int *n, int *k, double *a, int *lda, 
117         double *tau, double *work, int *info);
118
119 void
120 F77_FUNC(dbdsqr,DBDSQR)(const char *uplo, int *n, int *ncvt, int *nru, int *ncc, double *d, 
121         double *e, double *vt, int *ldvt, double *u, int *ldu,
122         double *c, int *ldc, double *work, int *info);
123
124 void
125 F77_FUNC(dgetrf,DGETRF)(int *m, int *n, double *a, int *lda, int *ipiv, int *info);
126
127 void
128 F77_FUNC(dgetri,DGETRI)(int *n, double *a, int *lda, int *ipiv, double *work, 
129         int *lwork, int *info);
130
131 void
132 F77_FUNC(dgetrs,DGETRS)(const char *trans, int *n, int *nrhs,   double *a, int *lda, int *ipiv,
133         double *b, int *ldb, int *info);
134
135 void
136 F77_FUNC(dtrtri,DTRTRI)(const char *uplo, const char *diag, int *n, double *a, int *lda, int *info);
137
138 void
139 F77_FUNC(dtrti2,DTRTI2)(const char *uplo, const char *diag, int *n, double *a, int *lda, int *info);
140
141 double
142 F77_FUNC(dlange,DLANGE)(const char *norm, int *m, int *n, double *a, int *lda, double *work);
143
144 void
145 F77_FUNC(dlarrbx,DLARRBX)(int *n, double *d, double *l, double *ld, double *lld, int *ifirst,
146          int *ilast, double *rtol1, double *rtol2, int *offset, double *w,
147          double *wgap, double *werr, double *work, int *iwork, int *info);
148
149 void 
150 F77_FUNC(dlasd1,DLASD1)(int *nl, int *nr, int *sqre, double *d, double *alpha, double *beta, 
151         double *u, int *ldu, double *vt, int *ldvt, int *idxq, int *iwork, 
152         double *work, int *info);
153
154 void
155 F77_FUNC(dlasdq,DLASDQ)(const char *uplo, int *sqre, int *n, int *ncvt, int *nru, int *ncc,
156         double *d, double *e, double *vt, int *ldvt, double *u, int *ldu, 
157         double *c, int *ldc, double *work, int *info);
158
159 void 
160 F77_FUNC(dlasr,DLASR)(const char *side, const char *pivot, const char *direct, int *m, int *n, double *c, 
161        double *s, double *a, int *lda);
162
163 void 
164 F77_FUNC(dorglq,DORGLQ)(int *m, int *n, int *k, double *a, int *lda, 
165         double *tau, double *work, int *lwork, int *info);
166
167 void
168 F77_FUNC(dormtr,DORMTR)(const char *side, const char *uplo, const char *trans, int *m, int *n, double *a, 
169         int *lda, double *tau, double *c, int *ldc,
170         double *work, int *lwork, int *info);
171
172 void
173 F77_FUNC(dgebd2,DGEBD2)(int *m, int *n, double *a, int *lda, double *d, double *e,
174         double *tauq, double *taup, double *work, int *info);
175
176 void 
177 F77_FUNC(dlabrd,DLABRD)(int *m, int *n, int *nb, double *a, int *lda, double *d,
178         double *e, double *tauq, double *taup, double *x,
179         int *ldx, double *y, int *ldy);
180
181 double
182 F77_FUNC(dlanst,DLANST)(const char *norm, int *n, double *d, double *e);
183
184 double
185 F77_FUNC(dlansy,DLANSY)(const char *norm, const char *uplo, int *n, double *a, int *lda, double *work);
186
187 void
188 F77_FUNC(dlarrex,DLARREX)(const char *range, int *n, double *vl, double *vu, int *il, int *iu,
189          double *d, double *e, double *tol, int *nsplit, 
190          int *isplit, int *m, double *w, int *iblock, int *indexw,
191          double *gersch, double *work, int *iwork, int *info);
192
193 void 
194 F77_FUNC(dlasd2,DLASD2)(int *nl, int *nr, int *sqre, int *k, double *d, double *z, 
195         double *alpha, double *beta, double *u, int *ldu, double *vt, 
196         int *ldvt, double *dsigma, double *u2, int *ldu2, double *vt2, 
197         int *ldvt2, int *idxp, int *idx, int *idxc, 
198         int *idxq, int *coltyp, int *info);
199
200 void
201 F77_FUNC(dlasdt,DLASDT)(int *n, int *lvl, int *nd, int *inode, int *ndiml, 
202         int *ndimr, int *msub);
203
204 void 
205 F77_FUNC(dlasrt,DLASRT)(const char *id, int *n, double *d, int *info);
206
207 void
208 F77_FUNC(dlasrt2,DLASRT2)(const char *id, int *n, double *d, int *key, int *info);
209
210 void
211 F77_FUNC(ilasrt2,ILASRT2)(const char *id, int *n, int *d, int *key, int *info);
212
213 void 
214 F77_FUNC(dorgqr,DORGQR)(int *m, int *n, int *k, double *a, int *lda, double *tau, 
215         double *work, int *lwork, int *info);
216
217 void
218 F77_FUNC(dstebz,DSTEBZ)(const char *range, const char *order, int *n, double *vl, double *vu, 
219         int *il, int *iu, double *abstol, double *d, double *e, 
220         int *m, int *nsplit, double *w, int *iblock, int *isplit, 
221         double *work, int *iwork, int *info);
222
223 void
224 F77_FUNC(dsteqr,DSTEQR)(const char *compz, int *n, double *d__, double *e, 
225         double *z__,  int *ldz, double *work, int *info);
226
227 void
228 F77_FUNC(dgebrd,DGEBRD)(int *m, int *n, double *a, int *lda, double *d, double *e,
229         double *tauq, double *taup, double *work, int *lwork, int *info);
230
231 void
232 F77_FUNC(dlacpy,DLACPY)(const char *uplo, int *m, int *n, double *a, int *lda, double *b, int *ldb);
233
234 double
235 F77_FUNC(dlapy2,DLAPY2)(double * x, double * y);
236
237
238 void
239 F77_FUNC(dlarrfx,DLARRFX)(int *n, double *d, double *l, double *ld, double *lld, int *ifirst,
240         int *ilast, double *w, double *sigma, double *dplus, double *lplus,
241         double *work, int *info);
242
243 void 
244 F77_FUNC(dlasd3,DLASD3)(int *nl, int *nr, int *sqre, int *k, double *d, double *q, int *ldq, 
245         double *dsigma, double *u, int *ldu, double *u2, int *ldu2, 
246         double *vt, int *ldvt, double *vt2, int *ldvt2, int *idxc, 
247         int *ctot, double *z, int *info);
248
249 void
250 F77_FUNC(dlaset,DLASET)(const char *uplo, int *m, int *n, double *alpha, 
251         double *beta, double *a, int *lda);
252
253 void
254 F77_FUNC(dlassq,DLASSQ)(int *n, double *x, int *incx, double *scale, double *sumsq);
255
256 void
257 F77_FUNC(dorm2l,DORM2L)(const char *side, const char *trans, int *m, int *n, int *k, double *a, int *lda, 
258         double *tau, double *c, int *ldc, double *work, int *info);
259
260 void
261 F77_FUNC(dstegr,DSTEGR)(const char *jobz, const char *range, int *n, double *d, double *e, double *vl, 
262         double *vu, int *il, int *iu, double *abstol, int *m, double *w, 
263         double *z, int *ldz, int *isuppz, double *work, 
264         int *lwork, int *iwork, int *liwork, int *info);
265
266 void
267 F77_FUNC(ssteqr,SSTEQR)(const char *compz, int *n, float *d__, float *e, 
268         float *z__,  int *ldz, float *work, int *info);
269
270 void
271 F77_FUNC(dgelq2,DGELQ2)(int *m, int *n, double *a, int *lda, double *tau, double *work, int *info);
272
273 void
274 F77_FUNC(dlae2,DLAE2)(double *a, double *b, double *c, double *rt1, double *rt2);
275
276 void
277 F77_FUNC(dlaev2,DLAEV2)(double *a, double *b, double *c, double *rt1, double *rt2,
278         double *cs1, double *cs2);
279
280 void
281 F77_FUNC(dlar1vx,DLAR1VX)(int *n, int *b1, int *bn, double *sigma, double *d, double *l, double *ld, 
282                           double *lld, double *eval, double *gersch, double *z, double *ztz, double *mingma, 
283                           int *r, int *isuppz, double *work);
284
285 void
286 F77_FUNC(dlarrvx,DLARRVX)(int *n, double *d, double *l, int *isplit, int *m, double *w, 
287          int *iblock, int *indexw, double *gersch, double *tol, double *z, int *ldz, 
288          int *isuppz, double *work, int *iwork, int *info);
289
290 void 
291 F77_FUNC(dlasd4,DLASD4)(int *n, int *i, double *d, double *z, double *delta, 
292         double *rho, double *sigma, double *work, int *info);
293
294 void
295 F77_FUNC(dlasq1,DLASQ1)(int *n, double *d, double *e, double *work, int *info);
296
297
298 void 
299 F77_FUNC(dlasv2,DLASV2)(double *f, double *g, double *h, double *ssmin, double *ssmax, 
300         double *snr, double *csr, double *snl, double *csl);
301
302 void 
303 F77_FUNC(dorm2r,DORM2R)(const char *side, const char *trans, int *m, int *n, int *k, double *a, 
304         int *lda, double *tau, double *c, int *ldc, double *work, int *info);
305
306 void
307 F77_FUNC(dstein,DSTEIN)(int *n, double *d, double *e, int *m, double *w, int *iblock, int *isplit, 
308         double *z, int *ldz, double *work, int *iwork, int *ifail, int *info);
309
310 void
311 F77_FUNC(dgelqf,DGELQF)(int *m, int *n, double *a, int *lda, double *tau,
312         double *work, int *lwork, int *info);
313
314 void
315 F77_FUNC(dlaebz,DLAEBZ)(int *ijob, int *nitmax, int *n, int *mmax, int *minp, int *nbmin,
316         double *abstol, double *reltol, double *pivmin, double *d, double *e,
317         double *e2, int *nval, double *ab, double *c, int *mout, int *nab,
318         double *work, int *iwork, int *info);
319
320 void
321 F77_FUNC(dlarf,DLARF)(const char *side, int *m, int *n, double *v, int *incv, double *tau,
322        double *c, int *ldc, double *work);
323
324 void
325 F77_FUNC(dlartg,DLARTG)(double *f, double *g, double *cs, double *sn, double *r);
326
327 void 
328 F77_FUNC(dlasd5,DLASD5)(int *i, double *d, double *z, double *delta, 
329         double *rho, double *dsigma, double *work);
330
331 void 
332 F77_FUNC(dlasq2,DLASQ2)(int *n, double *z, int *info);
333
334 void 
335 F77_FUNC(dlasq3,DLASQ3)(int *i0, int *n0, double *z, int *pp, double *dmin, 
336         double *sigma, double *desig, double *qmax, int *nfail, 
337         int *iter, int *ndiv, int *ieee);
338
339 void
340 F77_FUNC(dlaswp,DLASWP)(int *n, double *a, int *lda, int *k1, int *k2, int *ipiv, int *incx);
341
342 void 
343 F77_FUNC(dormbr,DORMBR)(const char *vect, const char *side, const char *trans, int *m, int *n, int *k, 
344         double *a, int *lda, double *tau, double *c, int *ldc, double *work,
345         int *lwork, int *info);
346
347 void
348 F77_FUNC(dsterf,DSTERF)(int *n, double *d, double *e, int *info);
349
350 void
351 F77_FUNC(dgeqr2,DGEQR2)(int *m, int *n, double *a, int *lda, double *tau, 
352         double *work, int *info);
353
354 void 
355 F77_FUNC(dlaed6,DLAED6)(int *kniter, int *orgati, double *rho, double *d, 
356         double *z, double *finit, double *tau, int *info);
357
358 void 
359 F77_FUNC(dlarfb,DLARFB)(const char *side, const char *trans, const char *direct, const char *storev, int *m, int *n, 
360         int *k, double *v, int *ldv, double *t, int *ldt, double *c,
361         int *ldc, double *work, int *ldwork);
362
363 void
364 F77_FUNC(dlaruv,DLARUV)(int *iseed, int *n, double *x);
365
366 void 
367 F77_FUNC(dlasd6,DLASD6)(int *icompq, int *nl, int *nr, int *sqre, double *d, double *vf, 
368         double *vl, double *alpha, double *beta, int *idxq, int *perm, 
369         int *givptr, int *givcol, int *ldgcol, double *givnum, int *ldgnum, 
370         double *poles, double *difl, double *difr, double *z, int *k, 
371         double *c, double *s, double *work, int *iwork, int *info);
372
373 void
374 F77_FUNC(dlatrd,DLATRD)(const char *uplo, int *n, int *nb, double *a, int *lda, double *e, 
375         double * tau, double *w, int *ldw);
376
377 void
378 F77_FUNC(dorml2,DORML2)(const char *side, const char *trans, int *m, int *n, int *k, double *a,
379         int *lda, double *tau, double *c, int *ldc, double *work, int *info);
380
381 void
382 F77_FUNC(dstevr,DSTEVR)(const char *jobz, const char *range, int *n, double *d, double *e, double *vl, 
383         double *vu, int *il, int *iu, double *abstol, int *m, double *w, 
384         double *z, int *ldz, int *isuppz, double *work, 
385         int *lwork, int *iwork, int *liwork, int *info);
386
387 void
388 F77_FUNC(dsytrd,DSYTRD)(const char *uplo, int *n, double *  a, int *lda, double *d, 
389         double *e, double *tau, double *work, int *lwork, int *info);
390
391 void
392 F77_FUNC(dsyevr,DSYEVR)(const char *jobz, const char *range, const char *uplo, int *n, 
393         double *a, int *lda, double *vl, double *vu, int *
394         il, int *iu, double *abstol, int *m, double *w, 
395         double *z__, int *ldz, int *isuppz, double *work, 
396         int *lwork, int *iwork, int *liwork, int *info);
397
398 void
399 F77_FUNC(dormql,DORMQL)(const char *side, const char *trans, int *m, int *n, 
400         int *k, double *a, int *lda, double *tau, double *
401         c, int *ldc, double *work, int *lwork, int *info);
402
403 void 
404 F77_FUNC(dormqr,DORMQR)(const char *side, const char *trans, int *m, int *n, int *k, double *a, 
405         int *lda, double *tau, double *c, int *ldc, 
406         double *work, int *lwork, int *info);
407
408 void
409 F77_FUNC(dorgbr,DORGBR)(const char *vect, int *m, int *n, int *k, double *a, int *lda,
410         double *tau, double *work, int *lwork, int *info);
411
412 void
413 F77_FUNC(dlasq5,DLASQ5)(int *i0, int *n0, double *z, int *pp, double *tau, double *dmin, 
414         double *dmin1, double *dmin2, double *dn, double *dnm1, 
415         double *dnm2, int *ieee);
416
417 void 
418 F77_FUNC(dlasd8,DLASD8)(int *icompq, int *k, double *d, double *z, double *vf, double *vl, 
419         double *difl, double *difr, int *lddifr, double *dsigma, 
420         double *work, int *info);
421
422 void
423 F77_FUNC(dlascl,DLASCL)(const char *type, int *kl, int *ku, double *cfrom, double *cto, int *m, 
424         int *n, double *a, int *lda, int *info);
425
426 void 
427 F77_FUNC(dlarft,DLARFT)(const char *direct, const char *storev, int *n, int *k, double *v, 
428         int *ldv, double *tau, double *t, int *ldt);
429
430 void
431 F77_FUNC(dlagts,DLAGTS)(int *job, int *n, double *a, double *b, double *c, double *d, 
432         int *in, double *y, double *tol, int *info);
433
434 void 
435 F77_FUNC(dgesdd,DGESDD)(const char *jobz, int *m, int *n, double *a, int *lda, double *s, double *u, 
436         int *ldu, double *vt, int *ldvt, double *work, int *lwork, 
437         int *iwork, int *info);
438
439 void
440 F77_FUNC(dsytd2,DSYTD2)(const char *uplo, int *n, double *a, int *lda, double *d, 
441         double *e, double *tau, int *info);
442
443 void 
444 F77_FUNC(dormlq,DORMLQ)(const char *side, const char *trans, int *m, int *n, int *k, double *a, int *lda, 
445         double *tau, double *c, int *ldc, double *work, int *lwork, int *info);
446
447 void
448 F77_FUNC(dorg2r,DORG2R)(int *m, int *n, int *k, double *a, int *lda, double *tau,
449         double *work, int *info);
450
451 void 
452 F77_FUNC(dlasq4,DLASQ4)(int *i0, int *n0, double *z, int *pp, int *n0in, double *dmin, 
453         double *dmin1, double *dmin2, double *dn, double *dn1, 
454         double *dn2, double *tau, int *ttype);
455
456 void 
457 F77_FUNC(dlasd7,DLASD7)(int *icompq, int *nl, int *nr, int *sqre, int *k, double *d, double *z,
458         double *zw, double *vf, double *vfw, double *vl, double *vlw,
459         double *alpha, double *beta, double *dsigma, int *idx, int *idxp,
460         int *idxq, int *perm, int *givptr, int *givcol, int *ldgcol, 
461         double *givnum, int *ldgnum, double *c, double *s, int *info);
462
463 void
464 F77_FUNC(dlas2,DLAS2)(double *f, double *g, double *h, double *ssmin, double *ssmax);
465
466 void
467 F77_FUNC(dlarfg,DLARFG)(int *n, double *alpha, double *x, int *incx, double *tau);
468
469 void
470 F77_FUNC(dlagtf,DLAGTF)(int *n, double *a, double *lambda, double *b, double *c, 
471         double *tol, double *d, int *in, int *info);
472
473 void 
474 F77_FUNC(dgeqrf,DGEQRF)(int *m, int *n, double *a, int *lda, double *tau,
475         double *work, int *lwork, int *info);
476
477
478
479 /* Single precision */
480
481 void
482 F77_FUNC(sbdsdc,SBDSDC)(const char *uplo, const char *compq, int *n, float *d, float *e, float *u, 
483         int *ldu, float *vt, int *ldvt, float *q, int *iq, float *work, 
484         int *iwork, int *info);
485
486 void
487 F77_FUNC(sgetf2,SGETF2)(int *m, int *n, float *a, int *lda, int *ipiv, int *info);
488
489 void
490 F77_FUNC(slamrg,SLAMRG)(int *n1, int *n2, float *a, int *dtrd1, int *dtrd2, int *index);
491
492 void
493 F77_FUNC(slarnv,SLARNV)(int *idist, int *iseed, int *n, float *x);
494
495 void 
496 F77_FUNC(slasd0,SLASD0)(int *n, int *sqre, float *d, float *e, float *u, 
497         int *ldu, float *vt, int *ldvt, int *smlsiz, int *iwork, 
498         float *work, int *info);
499
500 void 
501 F77_FUNC(slasda,SLASDA)(int *icompq, int *smlsiz, int *n, int *sqre, float *d, float *e, 
502         float *u, int *ldu, float *vt, int *k, float *difl, float *difr, 
503         float *z, float *poles, int *givptr, int *givcol, int *ldgcol, 
504         int *perm, float *givnum, float *c, float *s, 
505         float *work, int *iwork, int *info);
506
507 void 
508 F77_FUNC(slasq6,SLASQ6)(int *i0, int *n0, float *z, int *pp, float *dmin, float *dmin1, 
509         float *dmin2, float *dn, float *dnm1, float *dnm2);
510
511 void
512 F77_FUNC(sorgl2,SORGL2)(int *m, int *n, int *k, float *a, int *lda, 
513         float *tau, float *work, int *info);
514
515 void
516 F77_FUNC(sbdsqr,SBDSQR)(const char *uplo, int *n, int *ncvt, int *nru, int *ncc, float *d, 
517         float *e, float *vt, int *ldvt, float *u, int *ldu,
518         float *c, int *ldc, float *work, int *info);
519
520 void
521 F77_FUNC(sgetrf,SGETRF)(int *m, int *n, float *a, int *lda, int *ipiv, int *info);
522
523 void
524 F77_FUNC(sgetri,SGETRI)(int *n, float *a, int *lda, int *ipiv, float *work, 
525         int *lwork, int *info);
526
527 void
528 F77_FUNC(sgetrs,SGETRS)(const char *trans, int *n, int *nrhs,   float *a, int *lda, int *ipiv,
529         float *b, int *ldb, int *info);
530
531 void
532 F77_FUNC(strtri,STRTRI)(const char *uplo, const char *diag, int *n, float *a, int *lda, int *info);
533
534 void
535 F77_FUNC(strti2,STRTI2)(const char *uplo, const char *diag, int *n, float *a, int *lda, int *info);
536
537 float
538 F77_FUNC(slange,SLANGE)(const char *norm, int *m, int *n, float *a, int *lda, float *work);
539
540 void
541 F77_FUNC(slarrbx,SLARRBX)(int *n, float *d, float *l, float *ld, float *lld, int *ifirst,
542          int *ilast, float *rtol1, float *rtol2, int *offset, float *w,
543          float *wgap, float *werr, float *work, int *iwork, int *info);
544
545 void 
546 F77_FUNC(slasd1,SLASD1)(int *nl, int *nr, int *sqre, float *d, float *alpha, float *beta, 
547         float *u, int *ldu, float *vt, int *ldvt, int *idxq, int *iwork, 
548         float *work, int *info);
549
550 void
551 F77_FUNC(slasdq,SLASDQ)(const char *uplo, int *sqre, int *n, int *ncvt, int *nru, int *ncc,
552         float *d, float *e, float *vt, int *ldvt, float *u, int *ldu, 
553         float *c, int *ldc, float *work, int *info);
554
555 void 
556 F77_FUNC(slasr,SLASR)(const char *side, const char *pivot, const char *direct, int *m, int *n, float *c, 
557        float *s, float *a, int *lda);
558
559 void 
560 F77_FUNC(sorglq,SORGLQ)(int *m, int *n, int *k, float *a, int *lda, 
561         float *tau, float *work, int *lwork, int *info);
562
563 void
564 F77_FUNC(sormtr,SORMTR)(const char *side, const char *uplo, const char *trans, int *m, int *n, float *a, 
565         int *lda, float *tau, float *c, int *ldc,
566         float *work, int *lwork, int *info);
567
568 void
569 F77_FUNC(sgebd2,SGEBD2)(int *m, int *n, float *a, int *lda, float *d, float *e,
570         float *tauq, float *taup, float *work, int *info);
571
572 void 
573 F77_FUNC(slabrd,SLABRD)(int *m, int *n, int *nb, float *a, int *lda, float *d,
574         float *e, float *tauq, float *taup, float *x,
575         int *ldx, float *y, int *ldy);
576
577 float
578 F77_FUNC(slanst,SLANST)(const char *norm, int *n, float *d, float *e);
579
580 float
581 F77_FUNC(slansy,SLANSY)(const char *norm, const char *uplo, int *n, float *a, int *lda, float *work);
582
583 void
584 F77_FUNC(slarrex,SLARREX)(const char *range, int *n, float *vl, float *vu, int *il, int *iu,
585          float *d, float *e, float *tol, int *nsplit, 
586          int *isplit, int *m, float *w, int *iblock, int *indexw,
587          float *gersch, float *work, int *iwork, int *info);
588
589 void 
590 F77_FUNC(slasd2,SLASD2)(int *nl, int *nr, int *sqre, int *k, float *d, float *z, 
591         float *alpha, float *beta, float *u, int *ldu, float *vt, 
592         int *ldvt, float *dsigma, float *u2, int *ldu2, float *vt2, 
593         int *ldvt2, int *idxp, int *idx, int *idxc, 
594         int *idxq, int *coltyp, int *info);
595
596 void
597 F77_FUNC(slasdt,SLASDT)(int *n, int *lvl, int *nd, int *inode, int *ndiml, 
598         int *ndimr, int *msub);
599
600 void 
601 F77_FUNC(slasrt,SLASRT)(const char *id, int *n, float *d, int *info);
602
603 void
604 F77_FUNC(slasrt2,SLASRT2)(const char *id, int *n, float *d, int *key, int *info);
605
606 void 
607 F77_FUNC(sorgqr,SORGQR)(int *m, int *n, int *k, float *a, int *lda, float *tau, 
608         float *work, int *lwork, int *info);
609
610 void
611 F77_FUNC(sstebz,SSTEBZ)(const char *range, const char *order, int *n, float *vl, float *vu, 
612         int *il, int *iu, float *abstol, float *d, float *e, 
613         int *m, int *nsplit, float *w, int *iblock, int *isplit, 
614         float *work, int *iwork, int *info);
615
616 void
617 F77_FUNC(sgebrd,SGEBRD)(int *m, int *n, float *a, int *lda, float *d, float *e,
618         float *tauq, float *taup, float *work, int *lwork, int *info);
619
620 void
621 F77_FUNC(slacpy,SLACPY)(const char *uplo, int *m, int *n, float *a, int *lda, float *b, int *ldb);
622
623 float
624 F77_FUNC(slapy2,SLAPY2)(float * x, float * y);
625
626 void
627 F77_FUNC(slarrfx,SLARRFX)(int *n, float *d, float *l, float *ld, float *lld, int *ifirst,
628         int *ilast, float *w, float *sigma, float *dplus, float *lplus,
629         float *work, int *info);
630
631 void 
632 F77_FUNC(slasd3,SLASD3)(int *nl, int *nr, int *sqre, int *k, float *d, float *q, int *ldq, 
633         float *dsigma, float *u, int *ldu, float *u2, int *ldu2, 
634         float *vt, int *ldvt, float *vt2, int *ldvt2, int *idxc, 
635         int *ctot, float *z, int *info);
636
637 void
638 F77_FUNC(slaset,SLASET)(const char *uplo, int *m, int *n, float *alpha, 
639         float *beta, float *a, int *lda);
640
641 void
642 F77_FUNC(slassq,SLASSQ)(int *n, float *x, int *incx, float *scale, float *sumsq);
643
644 void
645 F77_FUNC(sorm2l,SORM2L)(const char *side, const char *trans, int *m, int *n, int *k, float *a, int *lda, 
646         float *tau, float *c, int *ldc, float *work, int *info);
647
648 void
649 F77_FUNC(sstegr,SSTEGR)(const char *jobz, const char *range, int *n, float *d, float *e, float *vl, 
650         float *vu, int *il, int *iu, float *abstol, int *m, float *w, 
651         float *z, int *ldz, int *isuppz, float *work, 
652         int *lwork, int *iwork, int *liwork, int *info);
653
654 void
655 F77_FUNC(sgelq2,SGELQ2)(int *m, int *n, float *a, int *lda, float *tau, float *work, int *info);
656
657 void
658 F77_FUNC(slae2,SLAE2)(float *a, float *b, float *c, float *rt1, float *rt2);
659
660 void
661 F77_FUNC(slaev2,SLAEV2)(float *a, float *b, float *c, float *rt1, float *rt2,
662         float *cs1, float *cs2);
663
664 void
665 F77_FUNC(slar1vx,SLAR1VX)(int *n, int *b1, int *bn, float *sigma, float *d, float *l, float *ld, 
666         float *lld, float *eval, float *gersch, float *z, float *ztz, float *mingma, 
667         int *r, int *isuppz, float *work);
668
669 void
670 F77_FUNC(slarrvx,SLARRVX)(int *n, float *d, float *l, int *isplit, int *m, float *w, 
671          int *iblock, int *indexw, float *gersch, float *tol, float *z, int *ldz, 
672          int *isuppz, float *work, int *iwork, int *info);
673
674 void 
675 F77_FUNC(slasd4,SLASD4)(int *n, int *i, float *d, float *z, float *delta, 
676         float *rho, float *sigma, float *work, int *info);
677
678 void
679 F77_FUNC(slasq1,SLASQ1)(int *n, float *d, float *e, float *work, int *info);
680
681
682 void 
683 F77_FUNC(slasv2,SLASV2)(float *f, float *g, float *h, float *ssmin, float *ssmax, 
684         float *snr, float *csr, float *snl, float *csl);
685
686 void 
687 F77_FUNC(sorm2r,SORM2R)(const char *side, const char *trans, int *m, int *n, int *k, float *a, 
688         int *lda, float *tau, float *c, int *ldc, float *work, int *info);
689
690 void
691 F77_FUNC(sstein,SSTEIN)(int *n, float *d, float *e, int *m, float *w, int *iblock, int *isplit, 
692         float *z, int *ldz, float *work, int *iwork, int *ifail, int *info);
693
694 void
695 F77_FUNC(sgelqf,SGELQF)(int *m, int *n, float *a, int *lda, float *tau,
696         float *work, int *lwork, int *info);
697
698 void
699 F77_FUNC(slaebz,SLAEBZ)(int *ijob, int *nitmax, int *n, int *mmax, int *minp, int *nbmin,
700         float *abstol, float *reltol, float *pivmin, float *d, float *e,
701         float *e2, int *nval, float *ab, float *c, int *mout, int *nab,
702         float *work, int *iwork, int *info);
703
704 void
705 F77_FUNC(slarf,SLARF)(const char *side, int *m, int *n, float *v, int *incv, float *tau,
706        float *c, int *ldc, float *work);
707
708 void
709 F77_FUNC(slartg,SLARTG)(float *f, float *g, float *cs, float *sn, float *r);
710
711 void 
712 F77_FUNC(slasd5,SLASD5)(int *i, float *d, float *z, float *delta, 
713         float *rho, float *dsigma, float *work);
714
715 void 
716 F77_FUNC(slasq2,SLASQ2)(int *n, float *z, int *info);
717
718 void 
719 F77_FUNC(slasq3,SLASQ3)(int *i0, int *n0, float *z, int *pp, float *dmin, 
720         float *sigma, float *desig, float *qmax, int *nfail, 
721         int *iter, int *ndiv, int *ieee);
722
723 void
724 F77_FUNC(slaswp,SLASWP)(int *n, float *a, int *lda, int *k1, int *k2, int *ipiv, int *incx);
725
726 void 
727 F77_FUNC(sormbr,SORMBR)(const char *vect, const char *side, const char *trans, int *m, int *n, int *k, 
728         float *a, int *lda, float *tau, float *c, int *ldc, float *work,
729         int *lwork, int *info);
730
731 void
732 F77_FUNC(ssterf,SSTERF)(int *n, float *d, float *e, int *info);
733
734 void
735 F77_FUNC(sgeqr2,SGEQR2)(int *m, int *n, float *a, int *lda, float *tau, 
736         float *work, int *info);
737
738 void 
739 F77_FUNC(slaed6,SLAED6)(int *kniter, int *orgati, float *rho, float *d, 
740         float *z, float *finit, float *tau, int *info);
741
742 void 
743 F77_FUNC(slarfb,SLARFB)(const char *side, const char *trans, const char *direct, const char *storev, int *m, int *n, 
744         int *k, float *v, int *ldv, float *t, int *ldt, float *c,
745         int *ldc, float *work, int *ldwork);
746
747 void
748 F77_FUNC(slaruv,SLARUV)(int *iseed, int *n, float *x);
749
750 void 
751 F77_FUNC(slasd6,SLASD6)(int *icompq, int *nl, int *nr, int *sqre, float *d, float *vf, 
752         float *vl, float *alpha, float *beta, int *idxq, int *perm, 
753         int *givptr, int *givcol, int *ldgcol, float *givnum, int *ldgnum, 
754         float *poles, float *difl, float *difr, float *z, int *k, 
755         float *c, float *s, float *work, int *iwork, int *info);
756
757 void
758 F77_FUNC(slatrd,SLATRD)(const char *uplo, int *n, int *nb, float *a, int *lda, float *e, 
759         float * tau, float *w, int *ldw);
760
761 void
762 F77_FUNC(sorml2,SORML2)(const char *side, const char *trans, int *m, int *n, int *k, float *a,
763         int *lda, float *tau, float *c, int *ldc, float *work, int *info);
764
765 void
766 F77_FUNC(sstevr,SSTEVR)(const char *jobz, const char *range, int *n, float *d, float *e, float *vl, 
767         float *vu, int *il, int *iu, float *abstol, int *m, float *w, 
768         float *z, int *ldz, int *isuppz, float *work, 
769         int *lwork, int *iwork, int *liwork, int *info);
770
771 void
772 F77_FUNC(ssytrd,SSYTRD)(const char *uplo, int *n, float *  a, int *lda, float *d, 
773         float *e, float *tau, float *work, int *lwork, int *info);
774
775 void
776 F77_FUNC(ssyevr,SSYEVR)(const char *jobz, const char *range, const char *uplo, int *n, 
777         float *a, int *lda, float *vl, float *vu, int *
778         il, int *iu, float *abstol, int *m, float *w, 
779         float *z__, int *ldz, int *isuppz, float *work, 
780         int *lwork, int *iwork, int *liwork, int *info);
781
782 void
783 F77_FUNC(sormql,SORMQL)(const char *side, const char *trans, int *m, int *n, 
784         int *k, float *a, int *lda, float *tau, float *
785         c, int *ldc, float *work, int *lwork, int *info);
786
787 void 
788 F77_FUNC(sormqr,SORMQR)(const char *side, const char *trans, int *m, int *n, int *k, float *a, 
789         int *lda, float *tau, float *c, int *ldc, 
790         float *work, int *lwork, int *info);
791
792 void
793 F77_FUNC(sorgbr,SORGBR)(const char *vect, int *m, int *n, int *k, float *a, int *lda,
794         float *tau, float *work, int *lwork, int *info);
795
796 void
797 F77_FUNC(slasq5,SLASQ5)(int *i0, int *n0, float *z, int *pp, float *tau, float *dmin, 
798         float *dmin1, float *dmin2, float *dn, float *dnm1, 
799         float *dnm2, int *ieee);
800
801 void 
802 F77_FUNC(slasd8,SLASD8)(int *icompq, int *k, float *d, float *z, float *vf, float *vl, 
803         float *difl, float *difr, int *lddifr, float *dsigma, 
804         float *work, int *info);
805
806 void
807 F77_FUNC(slascl,SLASCL)(const char *type, int *kl, int *ku, float *cfrom, float *cto, int *m, 
808         int *n, float *a, int *lda, int *info);
809
810 void 
811 F77_FUNC(slarft,SLARFT)(const char *direct, const char *storev, int *n, int *k, float *v, 
812         int *ldv, float *tau, float *t, int *ldt);
813
814 void
815 F77_FUNC(slagts,SLAGTS)(int *job, int *n, float *a, float *b, float *c, float *d, 
816         int *in, float *y, float *tol, int *info);
817
818 void 
819 F77_FUNC(sgesdd,SGESDD)(const char *jobz, int *m, int *n, float *a, int *lda, float *s, float *u, 
820         int *ldu, float *vt, int *ldvt, float *work, int *lwork, 
821         int *iwork, int *info);
822
823 void
824 F77_FUNC(ssytd2,SSYTD2)(const char *uplo, int *n, float *a, int *lda, float *d, 
825         float *e, float *tau, int *info);
826
827 void 
828 F77_FUNC(sormlq,SORMLQ)(const char *side, const char *trans, int *m, int *n, int *k, float *a, int *lda, 
829         float *tau, float *c, int *ldc, float *work, int *lwork, int *info);
830
831 void
832 F77_FUNC(sorg2r,SORG2R)(int *m, int *n, int *k, float *a, int *lda, float *tau,
833         float *work, int *info);
834
835 void 
836 F77_FUNC(slasq4,SLASQ4)(int *i0, int *n0, float *z, int *pp, int *n0in, float *dmin, 
837         float *dmin1, float *dmin2, float *dn, float *dn1, 
838         float *dn2, float *tau, int *ttype);
839
840 void 
841 F77_FUNC(slasd7,SLASD7)(int *icompq, int *nl, int *nr, int *sqre, int *k, float *d, float *z,
842         float *zw, float *vf, float *vfw, float *vl, float *vlw,
843         float *alpha, float *beta, float *dsigma, int *idx, int *idxp,
844         int *idxq, int *perm, int *givptr, int *givcol, int *ldgcol, 
845         float *givnum, int *ldgnum, float *c, float *s, int *info);
846
847 void
848 F77_FUNC(slas2,SLAS2)(float *f, float *g, float *h, float *ssmin, float *ssmax);
849
850 void
851 F77_FUNC(slarfg,SLARFG)(int *n, float *alpha, float *x, int *incx, float *tau);
852
853 void
854 F77_FUNC(slagtf,SLAGTF)(int *n, float *a, float *lambda, float *b, float *c, 
855         float *tol, float *d, int *in, int *info);
856
857 void 
858 F77_FUNC(sgeqrf,SGEQRF)(int *m, int *n, float *a, int *lda, float *tau,
859         float *work, int *lwork, int *info);
860
861
862 #ifdef __cplusplus
863 }
864 #endif
865
866 /*! \endcond */
867
868 #endif /* GMX_LAPACK_H */