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