Let's say we have the following simple transaction-schedule:
T1 | T2 | T3
-----+------+-----
w(x)| |
| w(x) |
| | w(x)
T1 comes before T2, so in the precedence graph, we draw an arrow from T1 to T2. T2 comes before T3, so we draw an arrow from T2 to T3.
My question is: is it also necessary to draw an arrow from T1 to T3? T1 comes before T3, and the definition of a precedence graph says nothing about not drawing a line from Tx to Ty if there is some arbitrary Tz inbetween.
On the other hand, T1 -> T2 -> T3 implies T1 -> T3, and as the graph gets larger things will get a bit messy. Is it okay to 'reduce' a precedence graph?
If the answer to the above question is yes, here is a follow up - consider the following schedule:
T1 | T2 | T3
-----+------+-----
w(x)| |
w(y)| |
| w(x) |
| w(z) |
| | w(y)
| | w(z)
In the precedence graph, for the operations on x we draw an arrow from T1 to T2, for y an arrow from T1 to T3, and for z an arrow from T2 to T3. Would you be allowed to omit the arrow 'caused' by element z?