When the convex optimization method is used to solve the problem, the optimization variable can be in the form of a matrix

I have seen that some papers use the form of optimization variables as matrices, but from the concept and online learning, the optimization variables are in the form of vectors. I’m confused

A vector is a standard form of optimization variable in much of optimization theory and software. However, some problem formulations use matrices and vectors, and scalars. CVX can use any combination of these, as well as higher dimensional arrays. Under the hood, optimization modeling systems, such as CVX, convert the variables into whatever form is needed by the solver they call, which in many cases are vectors. However,matrix variables might be more convenient for the user, so CVX allows them and does any necessary conversions “under the hood”.