Finished the calcTargets and findAllTargets method