realized my algorithm was a failure. implemented solution finding that will break cycles although not always optimally