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
1
vote
1 answer

CVXOPT seemingly provides non-optimal result for this simple quadratic program

I am trying to solve a simple quadratic program using CVXOPT and am troubled by the fact that I can guess a feasible solution better than the optimum provided by the solver. The optimisation is of the form: I will provide the definitions of…
N. Mao
  • 499
  • 1
  • 10
  • 19
1
vote
1 answer

inputting specific constraints into cvxopt QP

I have a rather complex quadratic problem that I am trying to solve in python, however, for the sake of this question - i am significantly simplifying the problem at hand. I have the following quadratic function I am trying to minimize while…
yungpadewon
  • 237
  • 3
  • 10
1
vote
0 answers

Python - Dual infeasible error SVM Quadratic problem OSQP

I need to implement a SVM for a school projet. But I'm facing a problem when I'm trying to solve a Quadratic problem in Python using the OSQP library. The problem is my constraints are: alpha >= 0 matrix Y.transpose() * alpha = 0 The matrix is…
Nicolas Roche
  • 105
  • 1
  • 1
  • 14
1
vote
1 answer

What is the difference between Integer Quadratic Programming versus Mixed Integer Quadratic Programming?

I am new to the optimization problem of Quadratic programming. In equation 8 of the following paper: here , there is an equation: The authors state that this is an 'Integer Quadratic Programming (IQP)' formula. Alternatively, in another website:…
user121
  • 849
  • 3
  • 21
  • 39
1
vote
1 answer

Mixed Integer Quadratic Programming with linear constraints in Matlab calling Gurobi

I have some troubles to understand how to implement the following MIQP (Mixed Integer Quadratic Programming) with linear constraints in Matlab calling Gurobi. Let me explain in a schematic way my setting. (1) x is the unknown and it is a column…
1
vote
1 answer

QPmat: Amat and dvec are incompatible

I am new to quadratic programming and having trouble running the function QPmat in the package popbio, which uses a matrix of stage class counts to calculate stage class transition probabilities. The code I am running: ####Create a matrix of time…
Peter B
  • 71
  • 4
1
vote
0 answers

svm negative(positive) semidefinite matrix in Rmosek

I tried to set up the svm by using Rmosek package, and I got a problem about using Rmosek. ## SET UP THE "negative semidefinite matrix" ## K is the kernel ## m=nrow(X) qy1=t(matrix(Y,m,m)) qy2=matrix(Y,m,m) Q=qy1*qy2*K*-1 At this…
Amy Chang
  • 23
  • 3
1
vote
1 answer

quadratic programming in R matrix form

I'm using R software quadprog. to solve the following optimization: Dmat <- matrix(c(1,1.5,1.5,5),nrow=2,ncol=2) dvec <- c(0.5,0) Amat <- -matrix(c(3,15,2,-3),nrow=2,ncol=2) bvec <- matrix(c(-2,1),nrow=2,ncol=1) solve.QP(Dmat,dvec,Amat,bvec) the…
forecaster
  • 1,084
  • 1
  • 14
  • 35
1
vote
1 answer

CPLEX quadratic objective CPLEX Error 1017: Not available for mixed-integer problems

I'm trying to solve the following linear program using cplex: def generate_linear_program(self): problem = cplex.Cplex() problem.objective.set_sense(problem.objective.sense.minimize) for index, track in enumerate(self.tracks): …
Paghillect
  • 822
  • 1
  • 11
  • 30
1
vote
0 answers

Large Scale Constrained Quadratic Programming?

I'm working on a large CQP problem, with 1.5M integer variables (actually with continous relaxation), and ~200 binary constrains (used to select variables so that their sum is [= | <] b) plus the non-negative constrains for all vars. My obj function…
1
vote
1 answer

ROI package doesn't give a solution (qpoases solver) for an unconstrained QP

I'm setting up a simple QP to test the ROI R package. However, the package isn't able to give a wrong solution to a simple toy problem when it is unconstrained. Example, # Maximize -1/2 x^2 + x, no constraints > x <- OP(Q_objective(as.matrix(-1),…
1
vote
0 answers

LASSO objective function in b'Qb + c'b form

I'm trying to minimize the LASSO objective function using the Rcplex package in R. The help page of Rcplex shows that the objective function should be written in b'Qb + c'b form. How do I rewrite To something that has the form b'Qb +c'b or is there…
Muki
  • 31
  • 3
1
vote
1 answer

Matlab CPLEX: add multiple SOCP constraints in cplexmiqcp

I have written my problem in MATLAB, using CPLEX as the solver. Due issues that are beyond my control (it is feasible), the CPLEX class API screws up when solving my problem. So, based on post found elsewhere on the internet, I am trying to solve…
Cynthia W
  • 13
  • 2
1
vote
0 answers

Microsoft Solver Foundation - Results Are Not Good Enough ( Stock Portfolio Optimization )

I'm trying to code a markowitz optimization class in C# but the optimization results not good enough. Portfolio weights are differing from matlab's and excel's solutions by average 0.2%. I checked my covariance matrix calculation and the other…
1
vote
2 answers

How to minimize an quadratic objective function with constraint violation using penalty method

I have compared many Quadratic Programming(QP) solvers like cvxopt, qpoases and osqp and found that osqp works faster and better for my application. Now, I want to minimize an indefinite quadratic function with both equality and inequality…