# question on showing transitivity of a relation

Define a relation on Z as xRy if |x−y|<1.

I have shown this relation is symetric and reflexive and i am pretty sure its transitive because this is the equality relation isnt it? thats my first question and my second is how to show it is transitive.

I attempted a direct proof but i dont know how to link the two inequalities together to get that |x−z|<1 (im trying to show if xRy and yRz then xRz).

Any help would be appreciated, thanks! I am looking for the proof of this last property (transitivity).

• Thanks, but its a relation on z so only for integer values – Carlos Bacca Dec 3 '18 at 4:14
• There are no integers satisfying this relation. – user58697 Dec 3 '18 at 4:41
• what about x=4 y=4? – Carlos Bacca Dec 3 '18 at 4:43
• Sorry I forgot to say distinct. Modulo is non-negative; the only non-negative less than 1 is 0. – user58697 Dec 3 '18 at 4:49
• So is it transitive? – Carlos Bacca Dec 3 '18 at 4:53

If your relation is in fact on $$\Bbb{Z}$$, then $$xRy$$ is the same as writing $$x=y$$ because if $$x\ne y$$ then the distance between x and y is obviously larger than 1.
If $$x\ne y$$ then $$y = x+k$$, with $$k\in \Bbb{Z}^*$$
And $$|x-y| = |k| \ge 1$$, thus no two distinct integers verify this relation
If $$xRy$$ and $$yRz$$ that means that $$x=y=z$$ thus $$xRz$$ also. So yes the relation is transistive