The more typical way to do this is
to alternate between 2 commands in
your loop: displace_box and minimize.
If you want to displace really far (which is
somewhat odd) then you still need to
worry about resetting xy yourself to a negative
value. You could probably right a variable
formula to do this.
Alternatively you could use a run command with
fix deform as you are now, but let it run longer
than 1 step. In this case the run should do
the box flip to reset large xy values whenever
it exceeds the value that fix deform discusses.
Is there a way to to shear
step-by-step and have the automatic particle remapping (i.e keeping
Xy always within some interval)?
Alternatively you could use a run command with
fix deform as you are now, but let it run longer
than 1 step. In this case the run should do
the box flip to reset large xy values whenever
it exceeds the value that fix deform discusses.
In case someone is ever using this, it turns out that the box flip is
performed or not depending on the choice of the delta in fix_deform
and of the number of run steps (even if the latter is > 1).
I wasn't able to figure out how to determine the parameters that
ensure the flip to be always performed for my geometry though.