Linked Questions

2 votes
0 answers
2k views

How can one model the following condition in an integer linear program? $$ y = \begin{cases} 1 & \text{if } x > 0\\ 0 & \text{otherwise}\end{cases} $$ Where $y \in \{0,1\}$ and $x \in \...
Swaz's user avatar
  • 21
44 votes
6 answers
26k views

Linear programming (LP) is in P and integer programming (IP) is NP-hard. But since computers can only manipulate numbers with finite precision, in practice a computer is using integers for linear ...
Sasha the Noob's user avatar
15 votes
3 answers
4k views

I want to express the following constraint, in an integer linear program: $$y = \begin{cases} 0 &\text{if } x=0\\ 1 &\text{if } x\ne 0. \end{cases}$$ I already have the integer variables $x,...
D.W.'s user avatar
  • 169k
4 votes
5 answers
10k views

How can one model the following condition in an integer linear program? $$A = \begin{cases} 1 & \text{if } B > C\\ 0 & \text{otherwise}\end{cases}$$ where $A \in \{0,1\}$ and $B, C \in \...
Salah's user avatar
  • 91
15 votes
2 answers
927 views

Since Integer Linear Programming is NP-complete, there is a Karp reduction from any problem in NP to it. I thought this implied that there is always a polynomial-sized ILP formulation for any problem ...
andy's user avatar
  • 263
3 votes
1 answer
4k views

Karp's 21 NP-complete problems show that 0-1 integer linear programming is NP-hard. That is, an integer linear program with binary variables. If we set the $c^T$ vector of the objective $\text {...
Mat's user avatar
  • 522
1 vote
1 answer
5k views

I have two variables $A$ and $B$, with $A$ being binary and $B$ is a real number where $B \ge 0$. My conditions are: if B > 0 A = 1 else A = 0 ...
asm_nerd1's user avatar
  • 229
2 votes
1 answer
4k views

I have liner programme with set of $x_{3n}$ variables where $x_{ij}$ are {0,1}. I am solving this linear programme using LP-Solve. Using these variables, I want to form following constraint : $max(...
Abhay's user avatar
  • 123
3 votes
1 answer
3k views

I have a constraint in a linear programming formulation with two variables: $X \ge Y$ To which I want to apply the following if-else conditions: ...
asm_nerd1's user avatar
  • 229
5 votes
2 answers
916 views

Consider the low-rank matrix completion problem: Given an integer $k$ and a subset of entries of some $n \times n$ matrix, fill in the rest of the entries so that the resulting matrix has rank at ...
Csabo E.'s user avatar
3 votes
1 answer
4k views

In our current project we need to model the following if-statement in linear programming: If T1 < b < T2 then z = s else z = 0 where T1 and T2 are two ...
piwa's user avatar
  • 33
0 votes
1 answer
3k views

In the below post, it is explained how to express xor of two variables as linear inequalities. Express boolean logic operations in zero-one integer linear programming (ILP) Naturally, the xor of ...
Ahmed's user avatar
  • 1
5 votes
1 answer
1k views

I'm looking for an algorithm that is closely related to the 2-dimensional nesting problem (also known as lay planning, bin packing, and the cutting stock problem). The main differences between this ...
bjornte's user avatar
  • 151
5 votes
2 answers
490 views

Given integers $n,m$, I want to find a $m \times n$ binary matrix $X$ such that there does not exist any non-zero vector $y \in \{-1,0,1\}^n$ with $Xy=0$ (all operations performed over $\mathbb{Z}$). ...
marshall's user avatar
  • 143
4 votes
2 answers
911 views

I'm attempting to create an automatic scheduler from a list of tasks I have available. Here are the key points: Each task has been given a priority beforehand and the algorithm should try to maximize ...
Lindenk's user avatar
  • 143

15 30 50 per page
1
2 3 4 5