-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathmain.cpp
More file actions
60 lines (41 loc) · 1 KB
/
main.cpp
File metadata and controls
60 lines (41 loc) · 1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
#include "Problem.h"
#include "RF.h"
int main(int argc, char* argv[]) {
if (argc < 1)
return 0;
const char* instancia = argv[1];
const char* saida = argv[2];
int estrategia = -1,
k = -1,
divisao_tempo = -1;
double BUDGET = 3600.0;
if (argc > 3)
estrategia = atoi(argv[3]);
if (argc > 4) {
k = atoi(argv[4]);
}
if (argc > 5) {
BUDGET = stod(argv[5]);
}
if (argc > 6) {
divisao_tempo = atoi(argv[6]);
}
double capacidade = 1;
if (argc > 7) {
capacidade = stod(argv[7]);
}
double capacidade_total = 0;
if (argc > 8) {
capacidade_total = stod(argv[8]);
}
capacidade /= 100;
RF Teste(instancia);
//Teste.FIX_AND_OPTIMIZE(Teste.RELAX_AND_FIX(estrategia, k, true));
//cout << "Executando :" << estrategia << "," << saida << "," << k << "," << BUDGET << endl;
Teste.RELAX_AND_FIX(estrategia, saida, k, BUDGET, divisao_tempo, capacidade, capacidade_total);
capacidade_total = Teste.capa_max;
capacidade_total--;
Teste.~RF();
//Teste.imprimirdadosgerais();
return 0;
}