Most Popular

1500 questions
6
votes
1 answer

Optimal Energy Charging/discharging Scheduling Problem

I'm new to IBM CP optimizer. I want to make charging / discharging scheduling based on cost (value will change on time) and my objective function…
JG.K
  • 61
  • 1
6
votes
0 answers

Semi-definite Programming, non standard notation

The usual way to define a semi-definite program (SDP), e.g., as given in Boyd and Vandenberghe's convex optimization book, is: $$ \begin{array}{cl} \min & c^\top x \\ \mathrm{s.t.} & 0 \succeq x_1 F_1+ \ldots+x_nF_n + G \\ & Ax =…
independentvariable
  • 3,980
  • 10
  • 36
6
votes
1 answer

assigning values to IntVar if and only if BoolVar, else zero [or-tools]

If I have an IntVar s[j] stored in a vector s, is it possible to iterate for (a period of time) t and create a BoolVar b such that b[t] is true if and only if s[j]==t? I tried setting some restrictions: for (int j = 0; j < nbTasks; ++j) { …
6
votes
0 answers

OptionalIntervalVar enforced but not working OR-TOOLS

I'm using OptionalIntervalVar and then maximizing the starts. The optimal solution is not affecting the other variables that creates the OptionalIntervalVar (i mean the constraint starts[j]+sizes[j]==ends[j]), so I suppose that there are not…
6
votes
2 answers

Optimising the current model

After developing the MIP model I noticed that solver is taking a lot of time to reach the solution. So, how should I approach to optimize the current model? Are there any visualization tools or any tools that are helpful in optimizing the model.
ooo
  • 1,589
  • 4
  • 12
6
votes
0 answers

Benefits of removing slack variables during presolve

I was reading Tobias Achterberg's thesis, and on page 138 he mentions the following presolving technique for linear equations (I'm slightly paraphrasing Example 10.2): Consider the equation $4x_1+7x_2+3x_3+s=20$ with $s\geq0$, and assume that $s$…
Nikos Kazazakis
  • 12,121
  • 17
  • 59
6
votes
0 answers

Can demand be modeled by a limited amount of probability distributions?

In stochastic inventory control, it is very important to model the demand appropriate to set e.g. order levels. Demand can be fit to a certain probability distribution via many means (e.g. a goodness of fit test). However, following common…
Steven01123581321
  • 1,043
  • 6
  • 12
6
votes
1 answer

How to propagate time using linear inequalities?

I have an adjacency matrix $G_{i,j}$ that tells the distance between $i$ to $j$ (between 0 to 1) if there is no edge between $i$ to $j$ I am putting a large integer $100$. This is my previous question related to it. I am trying to linearize the…
ooo
  • 1,589
  • 4
  • 12
6
votes
1 answer

How to write a constraint for a directed graph?

I'm working on an optimization problem regarding a directed acyclic graph. The constraint looks in pyomo like this: model.K = RangeSet(0,n_edges) model.con_part=ConstraintList() for k in model.K: …
teshim
  • 61
  • 1
6
votes
2 answers

Assignment problem where assignments must be done sequentially

I have a weird planning problem. I think it falls under the assignment category, but I'm not sure because I'm not familiar with assignment problems, and also because there is a "temporal" angle to it, which maybe makes it a bit different from…
DeltaIV
  • 255
  • 1
  • 6
6
votes
0 answers

Modelling issue with precedence constraint in OR-Tools

I'm trying to solve an RCPSPDc model It is infeasible, although Ilog Cplex solves it, so I think I have a modelling issue. I have more constraints but the precedence is the one that makes it infeasible. //Inicializar Modelo CpModelBuilder…
6
votes
1 answer

Linearizing objective function with absolute differences

I want to turn this objective function $$\max \sum_{i=1}^{N-1} \sum_{j=i+1}^N |TX_i^T - TX_j^T|$$ where $T$ is just a vector with increasing integers (e.g $[1 \ 2]$) and $X_i$ is a vector with $n$ variables like $[x_{11} \ x_{12}]$. Is there…
T K.
  • 61
  • 1
6
votes
1 answer

Gurobi stuck at start - 16GB RAM exhausted

I'm solving a large instance using Gurobi 7.0, 64-bit version on machine with 16GB of RAM. Gurobi is stuck at the start and all the memory is exhausted. Here is the output: 5378534 variables, all binary 16140318 constraints, all linear; 319218593…
lazar
  • 73
  • 3
6
votes
0 answers

Data Formulation for Mixed-Integer-Programming Models

Until now, I have used the Gurobi, CPLEX and OR-Tools (GCO) interface to formulate mixed-integer-programming models. Recently, I have discovered MiniZinc and want to utilize it to formulate big models. With GCO I would only initialize the decision…
Georgios
  • 1,193
  • 5
  • 21
6
votes
0 answers

Demonstrating a given solution is basic for a MCFP?

Given a minimum-cost flow problem, how could I go about demonstrating that a specific solution (as sets of basic and non-basic (!) arcs that build a rooted spanning tree for a given graph) is basic and feasible for the problem? Update: the MCF…
Johnny Bueti
  • 253
  • 2
  • 5