Promblem with the function vec


there is problem with the code bb = w’aaw
Why the problem happen?
Function ‘vec’ has an incorrect number or type of inputs or outputs.

Apparently there is a different an incompatible version of vec also on your system than the vec which is included with CVX.

What is the output of
which -all vec

If so, that might be resolved by moving the CVX directories to before the other vec in your MATLAB path.

Thank you for your help. According to what you said, I successfully solved the problem.