On the existence of a competitive equilibrium with utilityfunction: a variational approach