As of May 31, 2023, we have updated our Code of Conduct.

Questions tagged [constraint]

For questions related to constraints, i.e. any restriction or relation a set of decision variables has to satisfy.

21 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
5 votes
0 answers

Substituting inequality by equality constraints

Let $\mathbf{A}=\left(a_{ij}\right)$ be a $n\times J$ matrix with $a_{ij}\geq 0$, $n>J$ and such that no row or column has all its entries equal to zero. Let also $\mathbf{k}=\left(k_j\right)$ be a ...
Patricio's user avatar
  • 591
4 votes
0 answers

Confused in how to insert a slack variable in a constraint inequality

According to my understanding, we should put a slack variable to equate an inequality constraint by inserting the slack variable in the side that is less than the other side. For example, if we have $...
John adams's user avatar
3 votes
0 answers

constrained optimization with decreasing constraint thresholds -Literature tips

consider a constrained optimization problem (typically c=0), with f highly nonlinear: \begin{equation} \text{minimize}_x f(x) \\\\ s.t \ \ \ \ g(x) \leq c \end{equation} I experimented a bit and found ...
Lukas Schroth's user avatar
3 votes
0 answers

Projected Gradient Ascent for linear programming

I need to find a reasonable maximum for a linear programming problem, for which standard solvers for linear programming are just too slow. I was thinking of using projected gradient ascent, but do not ...
Carol Eisen's user avatar
3 votes
0 answers

Two binding constraints - Linear Programming

I'm having some troubles to continue solving my system, I'm used to solve such systems but with "one" binding constraint, if someone could give me some helpful hints so I can solve it I will ...
user.mokho's user avatar
3 votes
0 answers

SDP relaxation with greater-than and less-than inequalities at the same time

I am dealing with the following nonconvex fractional quadratic optimization problem \begin{align} & \min_{\boldsymbol{x}} && \max_{t \in \mathcal{T}} \frac{\boldsymbol{a}_t^T \boldsymbol{...
Antonio Albanese's user avatar
2 votes
0 answers

OR constraint in Gurobi - Python

I'm new to Gurobi in Python and I am wondering if there is way to code the following constraints: 1- $\sum x_i =0$ for all $i\in A$ OR for all $i \in B$ where A and B are distinch sets of integers ...
M.Badaoui's user avatar
  • 185
2 votes
0 answers

How to write the constraint matrix for this blending problem?

Below is a model for maximizing a utility function, a blending of, 3 ingredients $(A, B,C)$ to obtain 3 mixes of fertilizer, with the recipe given as proportions. Ingredients cost $A=130,\ B=150,\ C=...
Evion's user avatar
  • 21
2 votes
0 answers

How to linearize this multiplicative constraint?

I have a constraint in the form $\sqrt{|\sum_{c\in C}{h_cw_c}|^2}\ge\sqrt{x}\zeta$ Here, $h_c$ is s row vector (know), $w_c$ is a column vector (variable). $x$ and $\zeta$ are also optimization ...
KGM's user avatar
  • 2,191
1 vote
2 answers

How to linearize a chain of if-then constraints?

How can I express the process of converting a series of if-then constraints into a linear form? Let's assume that we have integer variable $x_i$, non-negative variables $y_i^d$, and binary variables $\...
linkho's user avatar
  • 175
1 vote
0 answers

How to speed up state of charge constraint in Pyomo model

Context: I am working on a small electricity market model in Pyomo. It optimizes the capacity of different technologies and generation in at least 43800 hours. One of the technologies is a battery. ...
funkypenguin's user avatar
1 vote
0 answers

Minimize cost given working days/hours/required hours per job/start & end dates

I am trying to solve an optimization problem on Excel or Python. My constraints are the available number of employees (=20), the number of working days/month (=20), the number of working hours/day (=8)...
confused_zoomer's user avatar
1 vote
0 answers

How can I reformulate an LP whose variables are linked to other LPs?

I consider an LP ($LP^*$) having an objective function defined as follows: $$\max_{x, y} \sum_{i \in I} p_i(x_i) - \sum_{j \in J} q_j(y_j)$$ where $x_i = \sum_{k \in [m]} x_{ik}$ and $y_j = \sum_{l \...
user12632521's user avatar
1 vote
0 answers

Simplification of nonlinear constraint for optimization

I solve a nonlinear optimization problem with constraint $$ \sum_{j=1}^S \ln \Bigg( \Big(1 -x_j c_k + y_j d_k\Big)^2 + \Big( x_j d_k + y_j c_k \Big)^2 \Bigg) \leq 0, \: k = 1, \dots , K $$ where the ...
Dan Doe's user avatar
  • 297
1 vote
0 answers

Minimizing total number of banners used in the cover buildings problem modelled

I was watching a video about Google OR-Tools where they were solving this cover building problem from Codility challenges using constraint programming. In short, you have a list of building heights, e....
dabadaba's user avatar
  • 111
1 vote
0 answers

vehicle routing optimization, Big M method of reformulation of constraints

Please excuse me for the long question, if I dont prrovide this info. my post gets removed! The following optimization problem is called Mixed-Integer Quadratically Constrained Programming (MIQCP) ...
Jose_Peeterson's user avatar
1 vote
0 answers

Adding sequence constraints to the assignment problem- Python

This is an online assignment problem and yet can be considered as an assignment problem with a sequence. Assume that workers are coming into the system sequentially and I want to assign a task to them ...
Dr. Turkuaz's user avatar
1 vote
0 answers

Question on quadratically constrained quadratic program

If the constrained optimization problem is a quadratically constrained quadratic program of the form \begin{align}\min&\quad x^HQx-a(x+x^H)+b|z^Hx|^2\\\text{s.t.}&\quad\|x\|^2\le1\end{align} ...
Kali's user avatar
  • 19
0 votes
1 answer

Meaning difference between SUMMATION and not in the MIP model

I'm asking you a question because I was confused about MIP while reading the paper. This paper is about dual crane optimization. In the MIP model of the paper, equations (7) and (8) are used to model ...
Kim's user avatar
  • 1
0 votes
0 answers

Looking for correction in pyomo constraint

I am working on two graphs having nodes and edges. Graph1: VNF Graph with node demand and bandwidth demand. Graph2: Server Graph with node capacity and bandwidth capacity. The nodes and links of ...
Waqas Swati's user avatar
0 votes
0 answers

Products distribution planning model

I have a problem of planning the distribution of products for a month. I have different unique products. A Mandate is provided for each product, and the Mandated quantity for each product is to be ...
MarcM's user avatar
  • 119