First run of the improved collision function