# Questions tagged [cvxpy]

CVXPY is a Python-embedded modeling language for convex optimization problems.

38 questions
Filter by
Sorted by
Tagged with
77 views

### Convex approximation of an expression with fraction for CVX

I have the optimization problem $$\underset{\mathbf{x} \in \Bbb C^N}{\max} \left| \frac{\mathbf{x}a-b}{\mathbf{x}c+b} \right|^2$$ where $a$, $b$ and $c$ are some scalars. I want to solve this ...
1 vote
69 views

### MOSEK via fusion vs API vs CVXPY

In Python, I would like to solve a collection of problems, that are all solvable via MOSEK's conic optimization solvers (ExpCone, SOCP, etc.) I have tried CVXPY. I get very robust and reliable results,...
214 views

### Convex approximation of an expression

I am trying to transform an expression given by $$\operatorname{trace} \left( {\bf{X} } \right) + \left( \sum_{n=1}^N \mathcal{R}(x_n) \right)$$ into convex from where $\mathbf{x}$ is complex in ...
473 views

### How to write this objective in CVXPY for quasiconvex programming?

I have the following objective that I want to maximize: \begin{equation} \max_{U_T\in \mathbb{R}, x\in\mathbb{R}^T} J_\alpha(U_T) = \frac{\alpha}{\alpha-1}\log\left(\frac{\cosh(U_T)}{\cosh(\alpha U_T)^...
195 views

### Quadratic optimisation with $\ell_1$ constraints with CVXPY

Crossposted on Mathematics SE I seek to minimize a convex quadratic objective subject to linear and $\ell_1$-based equality constraints. When I turn to CVXPY, an error is raised indicating that it ...
28 views

### Handling Variable Division in CVXPY for Calculating Annualized Rate of Change

I am working with a dataset that contains multiple entries for different IDs across various years. Some IDs might have a gap of years between entries. My goal is to solve an optimization problem using ...
67 views

### CVXPY stuck in Compilation step during solving linear program

I'm trying to solve a linear program with 869532 variables and 8869 constraints in CVXPY. The CVXPY gets stuck in the Compilation session right before passing the problem to the solver. Here's the ...
61 views

283 views

### Maximizing a Ratio/Percent

I'm using cvxpy to model a problem. Inside a very large and complex LP, I create two continuous, affine (unconstrained) expressions: $x$ and $y$. Due to how they ...
470 views

### Portfolio optimization with indicator function constraint in CVXPY

I have the following portfolio optimization problem that I want to solve using CVXPY: \begin{align}\min_w&\quad w^\top\Pi\\\text{s.t.}&\quad\sum_{i=1}^nw_i=1\\&\quad w^\top\Sigma w\le\...
1k views

### Mixed integer quadratic programming (MIQP) in CVXPY

There's something I don't understand about CVXPY's example on its MIQP use. It says that the algorithm returns a solution $x \in \mathbb{Z}^n$ but I thought in general the point of MIQP algorithms was ...