alpar@1
|
1 |
/* glpbfx.h (basis factorization interface, bignum arithmetic) */
|
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 GLPBFX_H
|
alpar@1
|
26 |
#define GLPBFX_H
|
alpar@1
|
27 |
|
alpar@1
|
28 |
#include "glpgmp.h"
|
alpar@1
|
29 |
|
alpar@1
|
30 |
#ifndef GLPBFX_DEFINED
|
alpar@1
|
31 |
#define GLPBFX_DEFINED
|
alpar@1
|
32 |
typedef struct { double _opaque_bfx; } BFX;
|
alpar@1
|
33 |
#endif
|
alpar@1
|
34 |
|
alpar@1
|
35 |
#define bfx_create_binv _glp_bfx_create_binv
|
alpar@1
|
36 |
#define bfx_is_valid _glp_bfx_is_valid
|
alpar@1
|
37 |
#define bfx_invalidate _glp_bfx_invalidate
|
alpar@1
|
38 |
#define bfx_factorize _glp_bfx_factorize
|
alpar@1
|
39 |
#define bfx_ftran _glp_bfx_ftran
|
alpar@1
|
40 |
#define bfx_btran _glp_bfx_btran
|
alpar@1
|
41 |
#define bfx_update _glp_bfx_update
|
alpar@1
|
42 |
#define bfx_delete_binv _glp_bfx_delete_binv
|
alpar@1
|
43 |
|
alpar@1
|
44 |
BFX *bfx_create_binv(void);
|
alpar@1
|
45 |
/* create factorization of the basis matrix */
|
alpar@1
|
46 |
|
alpar@1
|
47 |
int bfx_is_valid(BFX *binv);
|
alpar@1
|
48 |
/* check if factorization is valid */
|
alpar@1
|
49 |
|
alpar@1
|
50 |
void bfx_invalidate(BFX *binv);
|
alpar@1
|
51 |
/* invalidate factorization of the basis matrix */
|
alpar@1
|
52 |
|
alpar@1
|
53 |
int bfx_factorize(BFX *binv, int m, int (*col)(void *info, int j,
|
alpar@1
|
54 |
int ind[], mpq_t val[]), void *info);
|
alpar@1
|
55 |
/* compute factorization of the basis matrix */
|
alpar@1
|
56 |
|
alpar@1
|
57 |
void bfx_ftran(BFX *binv, mpq_t x[], int save);
|
alpar@1
|
58 |
/* perform forward transformation (FTRAN) */
|
alpar@1
|
59 |
|
alpar@1
|
60 |
void bfx_btran(BFX *binv, mpq_t x[]);
|
alpar@1
|
61 |
/* perform backward transformation (BTRAN) */
|
alpar@1
|
62 |
|
alpar@1
|
63 |
int bfx_update(BFX *binv, int j);
|
alpar@1
|
64 |
/* update factorization of the basis matrix */
|
alpar@1
|
65 |
|
alpar@1
|
66 |
void bfx_delete_binv(BFX *binv);
|
alpar@1
|
67 |
/* delete factorization of the basis matrix */
|
alpar@1
|
68 |
|
alpar@1
|
69 |
#endif
|
alpar@1
|
70 |
|
alpar@1
|
71 |
/* eof */
|