Questions tagged [cvxopt]

A Python package for convex optimization, including solvers for linear programming, quadratic programming, semidefinite programming and more.

There is an official web site of the CVXOPT package. The official description of the package is given there as follows:

CVXOPT is a free software package for convex optimization based on the Python programming language. It can be used with the interactive Python interpreter, on the command line by executing Python scripts, or integrated in other software via Python extension modules. Its main purpose is to make the development of software for convex optimization applications straightforward by building on Python’s extensive standard library and on the strengths of Python as a high-level programming language.

227 questions
0
votes
1 answer

Defining variables: problems with program logical flow

I'm currently trying to implement the following algorithm for finding max.-margin decision boundaries (for use in an SVM): let D = {(x1, y1), (x2, y2), . . . , (xl, yl )} ⊂ Rn ×{+1,−1} r ← max{|x| | (x, y) ∈ D} q ← 1000 let w∗ and b∗ be…
covariance
  • 6,833
  • 7
  • 23
  • 24
0
votes
1 answer

convex optimization in python/cvxopt

I am trying to do a constrained optimization (maximization) problem with a linear objective function and convex constraint, using the cvxopt library in python. Currently, the constraint is quadratic, but I want to do it eventually with a general…
qua
  • 972
  • 1
  • 8
  • 22
0
votes
2 answers

Min cut using matlab cvx

I am trying to detect communities using binary min cut on users' graph. For this purpose I am trying to use a variant of Fiedler method as shown in this paper. This is how they have formalized it: Now, I am trying to do this using the CVX package…
Koustav
  • 733
  • 1
  • 6
  • 21
0
votes
1 answer

How to find argmax in a cvx block in matlab?

I am trying to find the argmax inside a cvx block in matlab. This is just to find the optimal policy for the Bellman equation using linear programming. In the code below if I just do: k = max(Q) It finds the maximum of the list Q and works fine,…
Sheerberenj
  • 155
  • 2
  • 8
0
votes
2 answers

Problems on installing cvxopt

I am trying to install cvxopt on windows, I use a 2.7 Python Enthought distribution. I followed the instructions here, http://abel.ee.ucla.edu/cvxopt/install/ The error I run into is the follows, ./liblapack.a: could not read symbols: Archive has…
ganesh reddy
  • 1,842
  • 7
  • 23
  • 38
-1
votes
1 answer

python in the function solve.QP for investment portfolio optimization, how do you set the constraint for long short strategy?

Let's say we have 6 assets a b c d e f, we want to long a b c d and short e f, how to set the constraints by using the solver.qp? I am using the import cvxopt from cvxopt import matrix, solvers
s Murasame
  • 11
  • 3
-1
votes
2 answers

Quadratic programming with equal constraint and lower and upper bound

Please tell me how can I solve my problem with the below variables. Which solver is better? Objective function = x^T Q x + C^T x Q is diagonal matrix with Q(i,i)>=0 x.shape=(n,1) Equal constraint : Aeq.x =beq Aeq.shape=(n,n) and…
-1
votes
1 answer

ValueError in linear program with cvxopt (Rank(A) < p or Rank([G; A]) < n)

I try to solve the following linear program using the cvxopt package in python and wonder how to fix the stated ValueError. I guess it's a modeling mistake taking into consideration that I am a complete rookie using cvxopt. The following displays…
-1
votes
1 answer

Get an X(std) value of efficient frontier from a given Y(mean) value with cvxopt?

I'm trying to do portfolio optimization with cvxopt (Python), I'm able to get the efficient frontier with the following code, however, I'm not able to specify a Y value (mean or return) and get a corresponding X value (std or risk), if anyone has…
-1
votes
1 answer

CVXOPT solar + battery w/ price charge/discharge optimization glpk

I have the following df. battery can only charge from solar, and prefer to pick up teh curtailed/free solar as that sets the new limit on how much can leave the system. I'm having a diffuclt time splitting the model into energy_in and energy_out of…
-1
votes
1 answer

Linear programming (optimization)

I would like to ask you regarding on the Linear program for optimization. I have an objective function, and constraint functions as below, Variables (x1, x2, x3, x4, x5, and x6) are quantities of the products, and the quantities of products have to…
Jay Kim
  • 7
  • 1
-1
votes
1 answer

Linear Programming with cvxpy

I would like to ask you regarding on the Linear Program for optimization. I have an objective function, and constraint functions as below, variables(x1, x2, x3, x4, x5, x6) are quantities of the products, and the quantities of products have to be…
Jay Kim
  • 7
  • 1
-1
votes
1 answer

Does anyone know how to do convex optimization in Python with CVXOPT module?

I want to maximize Ax = b where A is an m-by-n matrix and x is an n-vector. The constraints on x are that its entries sum to 1 and that A x >= 0.
Jesica
  • 15
  • 1
  • 8
-1
votes
1 answer

How can I find correct parameters in cvxopt.solvers.qp() for SVM?

I have some data and I want to classification like svm with cvxopt function. In documentation of cvxopt.solvers.qp, there were some matrixes with vectorized and transposed. How can I find correct params (P, q, G, h, A, b) when I know n_samples and…
Lazyer
  • 917
  • 1
  • 6
  • 16
-1
votes
1 answer

begging letters about the installation of cvxopt-1.1.9-cp36-cp36m-win_amd64.whl

when I installed the 'cvxopt-1.1.9-cp36-cp36m-win_amd64.whl',problems are always going on. I'm using the win7 system, anoconda with python3.6.1. The installation process was held by 'pip install cvxopt-1.1.9-cp36-cp36m-win_amd64.whl' on cmd window.…
1 2 3
15
16