fix for eliminateBetti
fix for eliminateBetti