Speed calculate fix