Questions tagged [quadratic-programming]

Quadratic programming (QP) is a special type of mathematical optimization problem. It is the problem of optimizing (minimizing or maximizing) a quadratic function of several variables subject to linear constraints on these variables.

Quadratic programming (QP) is a special type of mathematical optimization problem. It is the problem of optimizing (minimizing or maximizing) a quadratic function of several variables subject to linear constraints on these variables.

237 questions
0
votes
1 answer

Linear programming with Scipy fails but quadratic programming succeeds in finding a solution

I am trying to solve a linear programming problem with Python. Ling program fails to find a solution. But quad program works. I do not understand why, and I am not sure my formulation of the program in linprog and quad program are equivalent. The…
0
votes
2 answers

Solve underdetermined linear equation Ax + By = C where y is constrained by x

I am new to optimization and have been struggling to solve for variable x and y in linear equation Ax +By = C, while y is constrained by the solution of x. An example of the problem can be: A = np.random.rand(20,100) B = np.random.rand(20,200) C =…
Susie
  • 287
  • 1
  • 13
0
votes
2 answers

Quadratic Programming with a large number of variables using CVXOPT

I am new to CVXOPT. I have tried out the example quadratic program (with 2 variables) in CVXOPT documentation, and I am able to understand it. Now I need to solve a quadratic programming problem with a large number of variables (eg: 100 variables).…
NandyGirl
  • 33
  • 4
0
votes
1 answer

How to only use the lower bounds and upper bounds for quadratic solver qpsolve from Scilab?

I have a simple question. How do I use the command qpsolve from Scilab if I only want to use the lower bounds and upper bounds limit? ci <= x <= cs The command can be used as this: [x [,iact [,iter [,f]]]] = qpsolve(Q,p,C,b,ci,cs,me) But I…
euraad
  • 2,467
  • 5
  • 30
  • 51
0
votes
0 answers

How to identify all minima in a non-PSD quadratic program (QP)?

I have linearly constrained QP problems with multiple disjoint global optima (not PSD). I'd like to make a QP solver characterize all of the globally optimal solutions. Here is a very simple example of the sort of case that arises: minimize…
0
votes
1 answer

How to linearize a quadratic objective function

I have an optimization problem. The objective is defined as follows: Max∑(k=1)∑(t=1)(r_k (t))^2 enter image description here constraints are linear How to linearize this objective function?
sorayya
  • 11
  • 2
0
votes
0 answers

Quadratic Programming in Julia

Well, I have a quadratic programming optimization problem, well structured in Matlab. For instance, With x a n*1 vector, we have x = argmin (1/2*x'*H*x+f'*x) s.t. A*x <= b x_lb<=x<=x_ub Of course, A is a matrix and b, x_lb, x_ub are…
0
votes
0 answers

sequential quadratic programming: implementing a directional step size similar to Matlab Minizers in python

what I want to do is essentially to understand how to implement a custom step taking routine to include in the take_step parameter of the basinhopping algorithm of the scipy library…
0
votes
1 answer

solve quadratic programming for matrix instead of vectors

I am working on a quadratic programming problem. So I got two matrices A and B (time series actually), and I wanna find the matrix X, s.t. A*X is closest to B, on the condition that X contains all positive values. (so X can be seen as a weight…
0
votes
0 answers

Cplex quadratic constraints in python, sparepair and sparsetriple

I am using Cplex in Python to solve an SVM problem with reduced dimensions. As a part of my algorithm, I have to add quadratic constraints to my objective function. So to say, I want to add something like "(w1+w2)^2
0
votes
1 answer

Constrained portfolio optimisation with quadratic solving

I'm trying to grapple with portfolio optimisation in R and I'm struggling to find consensus about how to code constraints etc using solve.QP. Essentially I have already calculated the covariance matrix of returns of n assets, which I understand to…
0
votes
1 answer

Difference between Matlab's fmincon and quadprog case for linear case

I am trying to convert my quadprog linear quadratic problem over to fmincon so that later I can add nonlinear constraints. I am having difficulty when I compare my solutions using the two methods (for the same problem). The odd thing is that I get…
0
votes
1 answer

Gurobi optimizer (Python): Linearize quadratic constraint?

Question: How I may linearize the following constraint (joined figure), where r[x][y], c[y,j], a[j,t] and p[x,t+l] are binary variables. Could someone help me please ? Best Quadratic constraint
0
votes
1 answer

Constrain variable to be in one of two disjoint ranges in quadratic programming

How do I solve a quadratic optimization problem with the following constraints: Minimize (1/2)X^TQX + C^TX Subject to -0.01 < x_i < 0.01 or 0.05 < x_i < 0.20, for any x_i in X Where Q is matrix, C, X are vectors. It seems that I can't…
mpp
  • 959
  • 1
  • 6
  • 4
0
votes
1 answer

what is the method to call this C function(libqp_gsmo.c) from R?

I have large scale QP problem, so I'm using a Gurobi optimizer in R. However, I hope to use a generalized sequential minimal optimization algorithm, but I couldn't find it in R packages. So I'm attempting to call this C function but failed so far.…