PIPS
iproblem.h
Go to the documentation of this file.
1 /* ========================================================================= */
2 /* SIMPLEXE for integer variables */
3 /* ALL-INTEGER METHODS */
4 /* Jean Claude SOGNO */
5 /* Projet CHLOE -- INRIA ROCQUENCOURT */
6 /* Juin 1994 */
7 /* ========================================================================= */
8 
9 /* ========================================================================= */
10 /* Duong NGUYEN QUE */
11 /* Adaption to abstract computation: janusvalue */
12 /* CRI-ENSMP */
13 /* ========================================================================= */
14 
15 typedef struct problem
16 { int result;
17  int jinfini; /* column in case of infinite vale of function */
18  int nvar; /* nombre de variables originales */
19  int mcontr; /* nombre de fonctions et contraintes originales */
20  int nvpos; /* nombre de variables originales contraintes (rangees en
21  tete). Usuellement =0 en calcul de dependances */
22  FILE *ftrace; /* numero "file system" pour "trace" */
23  /**** options solveur * entre parentheses: choix "recommande".
24  Parfois plusieurs choix plus ou moins equivalents */
25  int dyn;
26  int dyit;
27  int ntrace; /* niveau "trace" (execution accompagnee de commentaires)
28  0: aucune impression
29  >= 1: volume d'information croit avec le niveau
30  4: comportement probleme decrit en "latex" */
31  int ntrac2;
32  int ntrac3;
33  int fourier; /* (3) elimination FOURIER-MOTZKIN
34  0: elimination non appliquee
35  1: cas triviaux (
36  >= 2: lorsque le nombre d'inequations decroit
37  >= 3: lorsque le nombre d'inequations n'augmente pas */
38  int varc ; /* (0-1) introduction variables contraintes
39  0 "strategie simplexe"
40  1 pivot unitaire sinon "strategie simplexe"
41  2 pivot unitaire sinon variable unique ajoutee
42  >= 3 mise au point */
43  int forcer; /* in any case non negative variables */
44  int remove; /* redundant inequalities are removed */
45  int meth; /* (0-1) methode finale de resolution */
48  int choixpiv; /* (0-1) choix du pivot (simplexe dual)
49  0 plus petit pivot
50  1 plus grand pivot */
51  int choixprim; /* (-) choix du pivot (simplexe primal)*/
52 
53 #define MAXCOLONNES 200 /*108 variables 10-10 */
54 #define MAXLIGNES 500 /*250 contraintes 10-10 */
55 #define MAXNX MAXCOLONNES+9
56 #define MAXMX MAXLIGNES+9
57 #define AKCOLONNES MAXNX+1
58 #define AKLIGNES MAXMX+1
59  /***************** tableaux de donnees du probleme ******************/
60  /* nature contraintes
61  0 egalite
62  1 inequation <=
63  -1 inequation >=
64  2 fonction a minimiser
65  -2 fonction a maximiser
66  3 fonction d'accompagnement */
67  /*int e[MAXLIGNES+1] ;*/
68  /*int d[MAXLIGNES+1] ;*/ /* rhs */
69  /*int a[MAXLIGNES+1][MAXCOLONNES+1] ;*/ /* matrix coefficients */
70 /* ........... local data .............................................*/
71  int negal;
72  int icout;
73  int minimum;
74  int mx,nx,ic1;
75  int tmax;
76  int niter;
78  int numero,numax;//Value?DN
79  int lastfree;
80  int nub;
81  int ntp;
82  int vdum;
83  int nturb;
86  int b[AKCOLONNES+1];
87  int g[AKLIGNES];/* note g[0] inutilise */
95  Value tturb[30][AKCOLONNES] ;//DN
96  Value dturb[30];//DN
97  int jturb[30];
100  float rrbest;
101 /* ........... visualization local data ....................................*/
103 /********** temporary data *************************************/
104  int itemp; float ftemp;
105 /********** pour statistiques *************************************/
106  /*int croix;*/
108  int niveau;
110 #define MTDAI 0 /* methode DUAL ALL INTEGERS */
111 #define MTDI2 1 /* methode surrogate uniforme dual all integers */
112 /* ..................... resultat du solveur ....................... */
113 #define VRFIN 0 /* solution finie */
114 #define VRVID 1 /* polyedre vide */
115 #define VRINF 2 /* solution infinie */
116 #define VRINS 3 /* nombre de pivotages insuffisant, bouclage possible */
117 #define VRDEB 4 /* debordement de tableaux */
118 #define VRCAL 5 /* appel errone */
119 #define VRBUG 6 /* bug */
120 #define VROVF 7 /* overflow */
121 typedef struct initpb
122 {
123  Value a[MAXLIGNES+1][MAXCOLONNES+1] ; /* matrix coefficients */
124  Value d[MAXLIGNES+1] ; /* rhs */
125  int e[MAXLIGNES+1] ;
int Value
#define MAXLIGNES
Definition: iproblem.h:54
#define AKLIGNES
Definition: iproblem.h:58
struct initpb * Pinitpb
struct problem problem
#define MAXCOLONNES
(-) choix du pivot (simplexe primal)
Definition: iproblem.h:53
struct initpb initpb
struct problem * Pproblem
=========================================================================
#define AKCOLONNES
Definition: iproblem.h:57
Value d[MAXLIGNES+1]
matrix coefficients
Definition: iproblem.h:124
int e[MAXLIGNES+1]
rhs
Definition: iproblem.h:125
Value a[MAXLIGNES+1][MAXCOLONNES+1]
Definition: iproblem.h:123
=========================================================================
Definition: iproblem.h:16
int nredun
Definition: iproblem.h:77
int mcdeb
nt croix;
Definition: iproblem.h:107
int remove
in any case non negative variables
Definition: iproblem.h:44
int met8
Definition: iproblem.h:46
int nvpos
nombre de fonctions et contraintes originales
Definition: iproblem.h:20
int ntrac3
Definition: iproblem.h:32
int state
Definition: iproblem.h:98
int lastfree
Definition: iproblem.h:79
int met3
Definition: iproblem.h:46
int majstep
Definition: iproblem.h:102
Value bestup
Definition: iproblem.h:99
int cu
Definition: iproblem.h:98
int niter
Definition: iproblem.h:76
int met4
Definition: iproblem.h:46
int itemp
Definition: iproblem.h:104
int vbest
Definition: iproblem.h:98
int mcfin
Definition: iproblem.h:107
Value decrement
Definition: iproblem.h:99
int met7
Definition: iproblem.h:46
int frequency[AKCOLONNES+1+AKLIGNES]
Definition: iproblem.h:94
Value ilbound[AKCOLONNES+1+AKLIGNES]
Definition: iproblem.h:90
int lu
Definition: iproblem.h:98
int nxdeb
Definition: iproblem.h:107
int jturb[30]
Definition: iproblem.h:97
int critermax
Definition: iproblem.h:47
float rbound[AKCOLONNES+1+AKLIGNES]
Definition: iproblem.h:92
int nxfin
Definition: iproblem.h:107
int tilt
Definition: iproblem.h:98
int numax
Definition: iproblem.h:78
int dyn
numero "file system" pour "trace"
Definition: iproblem.h:25
int turbo
Definition: iproblem.h:47
Value ibound[AKCOLONNES+1+AKLIGNES]
Definition: iproblem.h:89
int vredun[AKLIGNES]
note g[0] inutilise
Definition: iproblem.h:88
int mx
Definition: iproblem.h:74
int jinfini
Definition: iproblem.h:17
int ntrac2
niveau "trace" (execution accompagnee de commentaires) 0: aucune impression >= 1: volume d'informatio...
Definition: iproblem.h:31
int ntp
Definition: iproblem.h:81
int g[AKLIGNES]
Definition: iproblem.h:87
int result
Definition: iproblem.h:16
int repere
Definition: iproblem.h:98
float rrbest
Definition: iproblem.h:100
int minimum
Definition: iproblem.h:73
Value ak[AKLIGNES][AKCOLONNES]
Definition: iproblem.h:84
int nstep
..........
Definition: iproblem.h:102
int b[AKCOLONNES+1]
Definition: iproblem.h:86
int met5
Definition: iproblem.h:46
int tmax
Definition: iproblem.h:75
float rlbound[AKCOLONNES+1+AKLIGNES]
Definition: iproblem.h:93
int dyit
Definition: iproblem.h:26
int icout
Definition: iproblem.h:72
int marque
Definition: iproblem.h:98
int meth
redundant inequalities are removed
Definition: iproblem.h:45
int bloquer
Definition: iproblem.h:98
int choixprim
(0-1) choix du pivot (simplexe dual) 0 plus petit pivot 1 plus grand pivot
Definition: iproblem.h:51
int ntrace
Definition: iproblem.h:27
int varc
(3) elimination FOURIER-MOTZKIN 0: elimination non appliquee 1: cas triviaux ( >= 2: lorsque le nombr...
Definition: iproblem.h:38
int utilb[AKCOLONNES+1+AKLIGNES]
Definition: iproblem.h:91
int nvar
column in case of infinite vale of function
Definition: iproblem.h:18
Value dk[AKLIGNES]
Definition: iproblem.h:85
Value bestlow
Definition: iproblem.h:99
Value dturb[30]
Definition: iproblem.h:96
int nturb
Definition: iproblem.h:83
int choixpiv
Definition: iproblem.h:48
FILE * ftrace
nombre de variables originales contraintes (rangees en tete).
Definition: iproblem.h:22
int mcontr
nombre de variables originales
Definition: iproblem.h:19
int nx
Definition: iproblem.h:74
int vdum
Definition: iproblem.h:82
float ftemp
Definition: iproblem.h:104
int forcer
(0-1) introduction variables contraintes 0 "strategie simplexe" 1 pivot unitaire sinon "strategie sim...
Definition: iproblem.h:43
int niveau
Definition: iproblem.h:108
int negal
nature contraintes 0 egalite 1 inequation <= -1 inequation >= 2 fonction a minimiser -2 fonction a ma...
Definition: iproblem.h:71
int itdirect
Definition: iproblem.h:77
int numero
Definition: iproblem.h:78
int met6
Definition: iproblem.h:46
Value tturb[30][AKCOLONNES]
Definition: iproblem.h:95
int fourier
Definition: iproblem.h:33
int met2
(0-1) methode finale de resolution
Definition: iproblem.h:46
int ic1
Definition: iproblem.h:74
int nub
Definition: iproblem.h:80