Definition Zaway x := if Rlt_bool x 0 then Zfloor x else Zceil x.

(* Specifications: *)
Theorem Zaway_Z2R :
forall n,
Zaway (Z2R n) = n.
Theorem Zaway_ceil :
forall x,
(0 <= x)%R ->
Zaway x = Zceil x.
Theorem Zaway_floor :
forall x,
(x <= 0)%R ->
Zaway x = Zfloor x.
Theorem Zaway_le :
forall x y, (x <= y)%R ->
(Zaway x <= Zaway y)%Z.
Theorem Zaway_opp :
forall x,
Zaway (- x) = Zopp (Zaway x).
Theorem Zaway_abs :
forall x,
Zaway (Rabs x) = Zabs (Zaway x).