Use Days/Weeks duration type when you define a schedule as a sequence of calendar dates and times, but with nonweekly recurrence - when the schedule has recurrence of several days or weeks.
For instance, you define a daily pattern of pedestrian arrival rate. One more example - you define a shift schedule, e.g. 48 hours on, 48 hours off - such schedule has 4-day recurrence.
Let's study how to define a schedule with N days/weeks recurrence by this example of shifts. Assume that the working time lasts from 10AM to 6PM, without lunch time.
You may delete any intervals from the table and move them in the table up and down (in this case you should contain the schedule integrity by yourself). This can be done by selecting the row in the table and using the corresponding buttons , and to the right of the table.
That's all - we have finished defining this very simple schedule! Now we will pay attention to some advanced features of the Days/Weeks schedule that enable users to configure schedules for their needs.
First, you may define exceptions - particular time intervals when the value defined by this schedule should have other values, differing from the ones specified in the schedule. The most frequent use cases of exceptions are national holidays and workday transfers caused by the holidays.
Actually it is evident that there should be one more shift that works in the complementary schedule: when the first shift is working, the second one is off and vice versa. This can be easily implemented by creating a copy of the existing schedule and setting that it should start working not from the first day of the simulation, but from the third one.
This can be done with the Snap to option: just go to the Snap to option of the cloned schedule and choose there the day that is two days after the day specified in the Snap to option of the original schedule.
If you define a work schedule for some resources, you should tell your ResourcePool object that it should use this specific schedule as a work timetable.
Go to the properties of the required ResourcePool object and choose By schedule from the Capacity defined drop-down list. This is the way we tell the object that the number of available resources will be defined by the schedule. Type the name of your schedule in the Capacity schedule field below (you can use code completion).
Usually this option (Capacity schedule) is used when the number of available resources changes in time (there are more options than just 0 and 5 as in our example). In case the number of resources is alwaysconstant and only the status changes (i.e. all resources are either available or not), you may explicitly define the number of resources once in the Capacity parameter of ResourcePool and use on/off Type of value in your schedule. In this case you will need to choose the option By "on/off" schedule from the Capacity defined drop-down list and specify the name of the schedule in the On/off schedule parameter of ResourcePool.
Please note that when you choose weeks in the Repeat every control, the option Week starts from is shown to the right. This option makes sense only in the case the schedule duration is several weeks.
The reason is that in some countries (e.g. USA) the first day of the week is Sunday, while in some other (e.g. Russia) - Monday. Therefore if you will define a schedule with N-weekly recurrence considering that the first day of the week is Sunday and then send the model to the user from some other country, where the week starts from Monday, the schedule will be misinterpreted.
So if you expect that your model will be used in other countries too, please define explicitly the first day of the week in your schedule so that this schedule will be locale-independent. And please do it before defining the schedule intervals, because all interval data in the table are deleted when you change the Weeks start from setting.
Schedule with no calendar mapping