Graph simplification algo working again