Modeling Objective function using mixed integer programming formulation

55 Views Asked by At

I have the following objective function

max 2x1 -2f(x2), where
f(x2) = 3 if x2 = 0
and f(x2) = 2-5x2 if x2 > 0;

can anyone help me formulate it using binary variables?