Use Warshall's transitive closure algorithm in deduce_alpha_implications

Unlike the existing algorithm, this correctly handles implications of
arbitrary depth, like a -> b, b -> c, c -> d, d -> e ==> a -> e.  It also
simplifies the algorithm quite a bit.