rev |
line source |
alpar@9
|
1 /* glpbfd.h (LP basis factorization driver) */
|
alpar@9
|
2
|
alpar@9
|
3 /***********************************************************************
|
alpar@9
|
4 * This code is part of GLPK (GNU Linear Programming Kit).
|
alpar@9
|
5 *
|
alpar@9
|
6 * Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008,
|
alpar@9
|
7 * 2009, 2010, 2011 Andrew Makhorin, Department for Applied Informatics,
|
alpar@9
|
8 * Moscow Aviation Institute, Moscow, Russia. All rights reserved.
|
alpar@9
|
9 * E-mail: <mao@gnu.org>.
|
alpar@9
|
10 *
|
alpar@9
|
11 * GLPK is free software: you can redistribute it and/or modify it
|
alpar@9
|
12 * under the terms of the GNU General Public License as published by
|
alpar@9
|
13 * the Free Software Foundation, either version 3 of the License, or
|
alpar@9
|
14 * (at your option) any later version.
|
alpar@9
|
15 *
|
alpar@9
|
16 * GLPK is distributed in the hope that it will be useful, but WITHOUT
|
alpar@9
|
17 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
alpar@9
|
18 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
|
alpar@9
|
19 * License for more details.
|
alpar@9
|
20 *
|
alpar@9
|
21 * You should have received a copy of the GNU General Public License
|
alpar@9
|
22 * along with GLPK. If not, see <http://www.gnu.org/licenses/>.
|
alpar@9
|
23 ***********************************************************************/
|
alpar@9
|
24
|
alpar@9
|
25 #ifndef GLPBFD_H
|
alpar@9
|
26 #define GLPBFD_H
|
alpar@9
|
27
|
alpar@9
|
28 #ifndef GLPBFD_PRIVATE
|
alpar@9
|
29 typedef struct { double _opaque_bfd[100]; } BFD;
|
alpar@9
|
30 #endif
|
alpar@9
|
31
|
alpar@9
|
32 /* return codes: */
|
alpar@9
|
33 #define BFD_ESING 1 /* singular matrix */
|
alpar@9
|
34 #define BFD_ECOND 2 /* ill-conditioned matrix */
|
alpar@9
|
35 #define BFD_ECHECK 3 /* insufficient accuracy */
|
alpar@9
|
36 #define BFD_ELIMIT 4 /* update limit reached */
|
alpar@9
|
37 #define BFD_EROOM 5 /* SVA overflow */
|
alpar@9
|
38
|
alpar@9
|
39 #define bfd_create_it _glp_bfd_create_it
|
alpar@9
|
40 BFD *bfd_create_it(void);
|
alpar@9
|
41 /* create LP basis factorization */
|
alpar@9
|
42
|
alpar@9
|
43 #define bfd_set_parm _glp_bfd_set_parm
|
alpar@9
|
44 void bfd_set_parm(BFD *bfd, const void *parm);
|
alpar@9
|
45 /* change LP basis factorization control parameters */
|
alpar@9
|
46
|
alpar@9
|
47 #define bfd_factorize _glp_bfd_factorize
|
alpar@9
|
48 int bfd_factorize(BFD *bfd, int m, const int bh[], int (*col)
|
alpar@9
|
49 (void *info, int j, int ind[], double val[]), void *info);
|
alpar@9
|
50 /* compute LP basis factorization */
|
alpar@9
|
51
|
alpar@9
|
52 #define bfd_ftran _glp_bfd_ftran
|
alpar@9
|
53 void bfd_ftran(BFD *bfd, double x[]);
|
alpar@9
|
54 /* perform forward transformation (solve system B*x = b) */
|
alpar@9
|
55
|
alpar@9
|
56 #define bfd_btran _glp_bfd_btran
|
alpar@9
|
57 void bfd_btran(BFD *bfd, double x[]);
|
alpar@9
|
58 /* perform backward transformation (solve system B'*x = b) */
|
alpar@9
|
59
|
alpar@9
|
60 #define bfd_update_it _glp_bfd_update_it
|
alpar@9
|
61 int bfd_update_it(BFD *bfd, int j, int bh, int len, const int ind[],
|
alpar@9
|
62 const double val[]);
|
alpar@9
|
63 /* update LP basis factorization */
|
alpar@9
|
64
|
alpar@9
|
65 #define bfd_get_count _glp_bfd_get_count
|
alpar@9
|
66 int bfd_get_count(BFD *bfd);
|
alpar@9
|
67 /* determine factorization update count */
|
alpar@9
|
68
|
alpar@9
|
69 #define bfd_delete_it _glp_bfd_delete_it
|
alpar@9
|
70 void bfd_delete_it(BFD *bfd);
|
alpar@9
|
71 /* delete LP basis factorization */
|
alpar@9
|
72
|
alpar@9
|
73 #endif
|
alpar@9
|
74
|
alpar@9
|
75 /* eof */
|