Adjusts algorithm again