[Math] If else statement in Linear programming with same variable

linear programming

Is it possible to write the following if else condition in Linear Programming with big M method?

"if $x < 1$ then $x = 0$".

"$x$" is a positive variable.

PS: This is part of a bigger optimization problem where "x" should only appear if this is profitable but it should have a value no less than 1. Otherwise if should not exist ($x=0$)

Best Answer

Use $x$ (not $a$) for variables. The constraints are $x \geq My$ and $x \leq -(1+\varepsilon)y$, with $y$ binary variable and $M$ a lower bound on $x$.