optimize timetable operation and caching