Download & install

CVX: Matlab Software for
Disciplined Convex Programming

Version 1.2 (June 2008, Build 667)
Michael Grant, Stephen Boyd, Yinyu Ye

Downloads

The CVX package includes the program files, the users’ guide, and the complete example library. To download it, use one of these links.

To download the user guide alone, select this link:

Installation instructions

For most platforms, installation is relatively simple:

  1. If you already have an earlier version of CVX installed, remove it or move it out of the way. Do not install this version on top of the old.

  2. Unpack the distribution wherever you like. It will create a directory called cvx/.

  3. Start Matlab.

  4. At the Matlab prompt, type cd <cvxroot>, where <cvxroot> is the cvx/ directory that was created when the software was unpacked.

  5. Important: Run the command cvx_setup to configure the software.

  6. When cvx_setup completes, it may ask you to save the current path so that cvx will automatically be available when you start Matlab. If you do not do so, you will have to re-run cvx_setup every time you start Matlab.

For more detailed installation instructions, see Appendix A of the user’s guide.

System requirements

CVX is built using Matlab, and requires version 6.1 or later of Matlab to run. It is built using both native Matlab code and C MEX files. It currently supports two solvers, SDPT3 and SeDuMi, with SDTP3 as the default. Both solvers are also built using a combination of Matlab and C MEX files. Precompiled binaries for Windows, 32-bit Linux, and Intel Mac OS X are supplied with the distribution, but it should work fine with any platform that supports Matlab 6.1 or later and at least one of the solvers. See Appendix A of the user’s guide for more detials.

Note for 64-bit MATLAB users: SeDuMi is currently not supported for the 64-bit versions of Matlab 7.3 and later. This is due to a change made to Matlab’s internal data structures between versions 7.2 and 7.3. When the SeDuMi authors release a new version of SeDuMi with an appropriate fix, we will update the CVX distribution accordingly. Until then, SDPT3 is the only solver available for those platforms.

Note for users of MATLAB 7.0: Versions 7.0.x of MATLAB (R14, R14SP1, R14SP2) reject certain CVX models, issuing syntax errors that are simply not correct. Numerical problems with version 7.0.0 and SDPT3 have also been reported. See section A.4 of the user’s guide for more details; but in short we recommend that versions 7.0.x be avoided, at least when using CVX.