fixed calculation of remaining effort