How to convert this problem to cvx form

That doesn’t look particularly convex to me. I will declare it non-convex unless and until you show otherwise.