Code cleanup: Added function computeCuts