Cancel
Showing results for 
Search instead for 
Did you mean: 

Count number of days worked

Valued Contributor
Valued Contributor

I am creating a model in which I have source producing 3 parts (namely A, B & C). At source I need to produce fixed quantity of oart A & B daily while C part only on 4th consecutive working day. So I am planning to create 2 sources viz. source 1 producing A & B part and source 2 producing A, B & C. I am planning to lock exit of source 1 on every 4th consecutive day and similarly locking exit of source 2 for rest 3 days. So in my method How do I count number of Working days only (i.e. I am using Shift calendar and have holiday on sunday. so I need not count sunday in working days.)

 

PS: I fyou are providing plant simulation model please provide ver 10.1 model as I don't have plant simulation ver. 11

3 REPLIES

Re: Count number of days worked

Gears Esteemed Contributor Gears Esteemed Contributor
Gears Esteemed Contributor

you can read the day with:

dayOfWeek(eventController.absSimTime) --> see help

 

For part C you could also control the source using a Trigger (See Help Trigger - Source) and here: http://www.bangsow.de/detail.php?id=531 an example.

Steffen Bangsow
freelance simulation specialist  
web: www.bangsow.eu
mail: steffen@bangsow.net

Re: Count number of days worked

Valued Contributor
Valued Contributor

Hi,

 

I've created the model as per your requiremnet but in different way.

I used only one Source it is operated by two tables.

 

Please find the attachment. 

 

 

 

 

 

Re: Count number of days worked

Valued Contributor
Valued Contributor

Thanks a lot. Smiley Happy

This helped me greatly as I don't have triggers supported in my license.Smiley Happy