3e_solve.gms 1.58 KB
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
$ontext
This file is part of Backbone.

Backbone is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

Backbone is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License
along with Backbone.  If not, see <http://www.gnu.org/licenses/>.
$offtext

18
19
20
* =============================================================================
* --- Solve Commands ----------------------------------------------------------
* =============================================================================
21

22
    if (mSolve('schedule'),
23
        schedule.holdfixed = 1; // Enable holdfixed, which makes the GAMS compiler convert fixed variables into parameters for the solver.
24
        schedule.OptFile = 1;
25
        solve schedule using mip minimizing v_obj;
26
    ); // END IF SCHEDULE
27

28
    if (mSolve('building'),
Topi Rasku's avatar
Topi Rasku committed
29
        building.holdfixed = 1;
30
        building.OptFile = 1;
31
32
        solve building using mip minimizing v_obj;
    ); // END IF BUILDING
33

34
    if (mSolve('invest'),
35
        invest.holdfixed = 1; // Enable holdfixed, which makes the GAMS compiler convert fixed variables into parameters for the solver.
36
        invest.OptFile = 1;
37
        solve invest using mip minimizing v_obj;
38
    ); // END IF INVEST
39
40
41