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