Permutation like matrix variable

I have a matrix A \in \mathbb{R}^{m \times n} where m>n. I want to create a variable matrix variable P that is comprised of the canonical unit vectors related to the rows I want to extract from A to form A'(see below). Is there a way to define this matrix variable P in CVX?

Example of extracting columns 2,3

n = 3;
m = 5;
A = randn(m,n);
I = eye(m);
e2 = I(:,2);
e3 = I(:,3);
P = [e2, e3];
Aprime = P.' * A;

Of course, this is not a complete optimization problem, but this is a necessary building block for what I am working on that I am wondering if it can be done in CVX

It’s not clear to me what is an optimization variable and what is input data.

You say P is a variable, but it sounds like you want to consider it to be input data. If so, and if A is a CVX (optimization variable), then P.' * A is an affine CVX expression of the variable A, and can be used according to standard CVX rules. Because P.' * A is formed all at once, rather than through indexing, it need not be declared as an expression in CVX.

Note, writing P.'*A rather than P'*A just seems unnecessarily confusing,. because the . before the ' does nothing, rather than making it into an element-wise (Hadamard) multiplication.

if you mean something else, you will have to clarify. And of course it needs to be a convex optimization problem (or perhaps Mixed-Integer convex)

If you want the rows to be selected per the value of some integer variables, I think you’ll need some kind of Big M modeling to select those rows.

Thanks for the reply!

In my case, I eventually want to form G = \left(A'\right)^T A' and minimize G's condition number. However, I understand this is a quasiconvex function of G and can’t be handled directly in CVX. I have a way to address this using the bisection method.

The focus of my question is can I formulate P as a variable in CVX? My intuitive idea is that I want to extract the rows of A that minimize the condition number of G. So P needs to be a matrix that is like a permutation matrix, but not square.

As for .', this is simply a habit of mine to use MATLAB transpose and not conjugate transpose.

I still don’t know what is a CVX variable and what is input data. If A is input data and the contents of P are determined by a CVX integer variable, i.e., you want to index into A to select rows according to some integer optimization variable, I think you will need some kind of Big M modeling.

I found that this paper is related. I think this will get me going for now!

This is a sensor selection problem, which is a non-convex problem. However, we can approximate it with a convex relaxation. The part pertaining to my question is they use

\sum_{i=1}^m z_i a_i a_i^T

where a_i^T is a row vector with length n and z_i\in\mathbb{R}^n is a boolean/binary variable to pick out rows (z_i=1) or exclude rows (z_i=0) of some matrix A = \left[a_1, \cdots, a_m \right]^T.