Steady vortex flows obtained from a constrained variational problem