Fixed bug in transitive hull function.