an Open Source MATLAB- Based Optimization Tool By Amila - - PowerPoint PPT Presentation

an open source matlab
SMART_READER_LITE
LIVE PREVIEW

an Open Source MATLAB- Based Optimization Tool By Amila - - PowerPoint PPT Presentation

CVX an Open Source MATLAB- Based Optimization Tool By Amila Tharaperiya Gamage Winter 2012 1 About CVX CVX is an open source MATLAB-based modeling tool. The optimization problem has to be a convex optimization problem. E.g.,


slide-1
SLIDE 1

CVX an Open Source MATLAB- Based Optimization Tool

By Amila Tharaperiya Gamage Winter 2012

1

slide-2
SLIDE 2

About CVX

 CVX is an open source MATLAB-based

modeling tool.

 The optimization problem has to be a

convex optimization problem.

 E.g.,

  • linear programs (LPs)
  • quadratic programs (QPs)
  • entropy maximization, etc

 CVX is not for large scale problems.

2

CVX: http://cvxr.com/cvx/

slide-3
SLIDE 3

About CVX

 Core solvers used in CVX:

  • SeDuMi (http://sedumi.ie.lehigh.edu/ )
  • SDPT3

(http://www.math.nus.edu.sg/~mattohkc/sdpt3.html)

 Both are open-source interior-point solvers

based on MATLAB.

 CVX converts the problem into a format

accepted by those solvers and call them to solve the problem.

3

slide-4
SLIDE 4

Disciplined Convex Programming (DCP)

 DCP is a methodology for constructing

convex optimization problems in a suitable format for CVX.

 DCP imposes a set of rules.  Problems has to be written such that

those rules are satisfied. Otherwise, problem will be rejected, even when the problem is convex.

4

slide-5
SLIDE 5

Functions

 Convexity or concavity has to be followed

from some DCP rules.

  • Write the functions in terms of CVX recognized

functions.

 Valid compositions of functions must be

used (refer to CVX user guide for details)

 Product of variables is not convex.

However, geometric mean of variables is a concave function.

  • geo_mean([x1 , x2 , x3])= (x1x2x3)1/3

5

User guide: http://web.cvxr.com/cvx/cvx_usrguide.pdf

slide-6
SLIDE 6

Constraints

 Equality == :Both left- and right-hand

sides should be affine functions of the

  • ptimization variables.

 Less-than <= :Expression in left-hand

side should be convex, and the right-hand expression should be concave.

 Constraints are imposed elementwise for

arrays and matrices.

6

affine: f(ax + (1 − a)y)= af(x) + (1 − a )f(y)

slide-7
SLIDE 7

What are the problems CVX could not handle well?

 Log(x), exp(x), log(exp x1+· · ·+exp xn)  CVX uses successive approximation

method for solving these problems, and the results may not be accurate.

 Solution: try to convert the problem to

some other form if possible

7

slide-8
SLIDE 8

Some Useful Conversions

 Use Max sqrt(x1x2) instead of Max log(x1)+log(x2)

 Max log(1+xy/(x+y))

subject to x,y>0 :

8

Max 1+t Subject to sqrt[(x-t)(y-t)] >= t x,y,t>0 : Max log(1+t) Subject to sqrt[(x-t)(y-t)] >= t x,y,t>0 :

xy/(x+y) >= t

slide-9
SLIDE 9

CVX commands

 cvx_optval: provide the optimum value of

the objective function

 cvx_slvtol: the tolerance level achieved by

the solver

 cvx_slvitr: the number of iterations taken

by the solver

 cvx_precision: modify the tolerances of

the solver

9

slide-10
SLIDE 10

System Model for Demo

Macrocell network Macrocell user

FAP Relay-1 Relay-2 Destination-1 Destination-2

10

slide-11
SLIDE 11

Thank you

11