In reply to dori.

You can use the VECH function on the transpose:
v = vech(M`);

You could also use the ideas in this post:
idx = loc(row(M)< =col(M));
v = M[idx];