added control time to retiming functions to discretize times