Briefly, have the following problem: \begin{equation} ( max [ F( \bar x ), 0 ] )^2 \rightarrow min, \end{equation} where $ F( \bar x ) $ is a linear function. It is possible to write an equal Quadratic Programming problem, such as $$ ( G( \bar x ) )^2 \rightarrow min \\\\ s.t. \\\\ G( \bar x ) \geq {\bf 0} \\\\ G( \bar x ) \geq F( \bar x ) $$ which can be solved very efficiently with an appropriate numerical method. Unfortunately in my particular case such conversion doesn't work: it adds a lot of new restrictions, and that appropriate numerical method doesn't converge. I tried to figure out another equal QPP, which adds fewer new constraints, but nothing came across my mind. Is there another way?