! MPEC formulation for ABS function ! y = ABS(x) returns a value y, where: ! y = x if the corresponding element of X is > than zero ! y = -x if the corresponding element of X is < than zero Parameters x = -2 End Parameters Variables y s_a >= 0 s_b >= 0 End Variables Equations ! test abs operator, y = abs(x) x = s_b - s_a y = s_a + s_b minimize s_a*s_b End Equations