fix severe bug in reachability-graph-calculation