changed makePlan function, also add new structure TimeWindow. renderGrid needs to be re-implemented