While transitive closure is not hard to write, the links within the residual program are quite complicated, so that once I got the link traversal
mostly correct, I had to restructure my dfs-based transitive closure. It should now be more correct when there are complex paths involving
both positive and negative links.
Hopefully this will be most of what is needed at least for the transitivity check, although there may be an optimization or two I can add.