Most Popular

1500 questions
5
votes
0 answers

All optimal solutions

I have a following problem: If I have some function $aX+bY+cZ+mD+nF$ and I want to maximize it and have some constraints, how can I find ALL solutions for this maximum value of the function? To sum up: I have a function value (e.g. $100$) and I have…
5
votes
1 answer

How to minimize a weighted sum of RMSE-like terms?

I am trying to solve the following problem: \begin{align} \min&\quad f(x) = \sum_{i=1}^{n}{a_ix_i} + \sum_{i=1}^{n}{b_i\sqrt{\sum_{j=1}^{m}{\left(y_{i,j}-x_i\right)^2}}}\\\text{s.t.}&\quad x_{i+1}\geq x_i \quad\forall i \in \{1,\dots,n-1\}…
Quarint
  • 61
  • 3
5
votes
1 answer

Preemptive Goal programming by fixing nonbasic variables with non-zero reduced costs

I have been using the method of fixing nonbasic variables with non-zero reduced costs to do preemptive goal programming. It works for the most part. But I have recently noticed in a certain instance of the problem, few variables have solution of 0,…
5
votes
2 answers

How to model If $A \le B$ then $Y = 1$, otherwise $Y = 0$

Somehow I don't get it right. I would like to model the following conditional: If $A\le B$ then $Y=1$ otherwise $Y=0$ where $A, B$ are reals and $Y$ is binary. I can model as follows: $Y \cdot A \le B$ and linearise this, but then I get into trouble…
Clement
  • 2,252
  • 7
  • 13
5
votes
3 answers

Solving continuous Minimax Optimization problem

I want to solve a linear programming minimax problem here mathematically without using software: $$\begin{align*} \text{min}\ \text{max} \quad & \{x_1,x_2,x_3\} \\ \text{s.t.} \quad & x_1 + x_2 + x_3 = 15 \end{align*}$$ Or it can be…
user123
  • 51
  • 3
5
votes
2 answers

Trade off between number of constraints and bounds of a variable

I am not familiar with the inner working of the solvers. I mostly use the python pulp or IBM CPLEX solver. For fast execution time, what should be the priority, fewer constraints and loosely bounded variables or more constraints and tightly bounded…
ooo
  • 1,589
  • 4
  • 12
5
votes
2 answers

AMPL implement constraint

I'm trying to implement the following in AMPL: $$ i \in [N], j \in[N] \backslash \{i\}, t \in [T] $$ I have so far written the following: subject to Con{i in PP,t in TT, j in PP : j != i}: but it does not feel correct, is it? I also have a question…
5
votes
1 answer

Tolerance for equality in GAMS/CPLEX

Is there an option in GAMS that sets the tolerance for declaring two real numbers to equal? For example, how can I tell GAMS or GAMS/CPLEX that $0.999100 = 0.99909$? Thank you for your help!
Clement
  • 2,252
  • 7
  • 13
5
votes
3 answers

Reducing number of suppliers for product portfolio

I have the following matrix of suppliers who are able to make a certain product, against all products in my portfolio. What is the best way of finding the solution to "the least suppliers necessary to deliver the whole portfolio" - and "which…
Roman
  • 151
  • 3
5
votes
2 answers

How to formulate case distinctions in AMPLs objective function?

This is my first real optimization problem I formulated and now trying to solve by using AMPL. The following objective function is from a linear 0-1 LP means all variables $x_i^b\in\{0,1\}$, with $i\in[1,n]$ and $b$ referring to the type of the…
baxbear
  • 319
  • 1
  • 7
5
votes
0 answers

Convexity of the projection of a convex set

Question: A set $S \subset \mathbb{R}^m \times \mathbb{R}^n$ is convex. Using the fact that affine maps preserves convexity prove that $S(y) = \{x \in \mathbb{R}^m\mid (x,y)\in S \}$ and $\hat{S} = \{ x \in \mathbb{R}^m \mid \exists y \in…
independentvariable
  • 3,980
  • 10
  • 36
5
votes
1 answer

Cumulative Constraint OR-Tools

I'm trying to solve an rcpsp model. I can't find documentation for the AddCumulative function of OR-Tools. How should this function be used? I want to write this constraint in C++: $$\forall k \in R,\quad\text{cumulative}(s, p_{j}, [r_{jk}\mid j\in…
5
votes
4 answers

MIP for similar production percentages in production planning

As a task, I want to produce three products $x,y,z$ in different quantities $a,b,c>0$ respectively. It is not always possible to produce the full amount of each product, because of a lack of resources. Now I want to set an objective keeping the…
Georgios
  • 1,193
  • 5
  • 21
5
votes
2 answers

What is the technique of branch-and-bound used in Knitro to solve MINLP?

I am using Knitro to solve an MINLP using branch-and-bound and I want to know about the reference or technique they are adopting to code their algorithm. I know that there are many applications of branch-and-bound to tackle MINLP but I couldn't find…
5
votes
1 answer

CPLEX Python API

I am trying to run the following optimization problem at Python by using the CPLEX API: $$\min \{x_1 + x_2\ | \ x_1 \geq 3, x_2 \geq 2, 2x_1 + x_2 \geq 9\} $$ I just want to give a matrix of coefficients and implement the problem as simple as…
independentvariable
  • 3,980
  • 10
  • 36