0S W1-LAB IS - 331 MUST Modeling and Simulation
0S W1-LAB IS - 331 MUST Modeling and Simulation
3
Simulation Examples
4
Example 3
R. Observations
(6, 3, 5, 0, 8) (T, H, T, H, T)
Example 3: Solution (6, 3, 5, 0, 8)
R. Observations
(6, 3, 5, 0, 8) (6, 3, 5, reject, reject)
Example 3: Solution (6, 3, 5, 0, 8)
R. Observations
So (6, 3, 5, 0, 8) (Red, Green, Red ,Green, Red)
Example 4: A news boy
Demand Types of new days
A news boy buys paper for 15 P.T.
Good Typical Poor
each and sells them for 25 P.T. each. Unsold
papers have no value in analyzing past sells, it 40 0.05
is found that three demand distribution exist, 50 0.20 0.03
depending on news events in the papers. A 60 0.41 0.07
good interesting news day yield to many 70 0.26 0.28
potential customer, typical and poor days yield 80 0.08 0.30 0.02
to less interest. Historically 20% of days have 90 0.25 0.15
been “good”, 50% “typical”, 30% “Poor”, The 100 0.07 0.28
demand distributions are summarized :
110 0.24
Simulate 10 days period and determine main
120 0.12
daily profit, max profit, min profit if he decides
130 0.09
to buy 80 papers each day. Use the following
R.N :- 140 0.06
09 65 69 66 57 64 84 24 92 22 150 0.04
49 50 61 01 45 48 48 45 52 35
Example 4: Solution (A news boy)
Demand Types of new days
Good 00 --> 19 Typical 20 --> 69 Poor 70 --> 99
40 0.05 00 --> 04
50 0.20 05 --> 25 0.03 00 --> 02
60 0.41 26--> 67 0.07 03--> 09
70 0.26 68 --> 94 0.28 10 --> 37
80 0.06 95 --> 99 0.3 38 --> 67 0.02 00 --> 01
90 0.25 68 --> 92 0.15 02 --> 16
100 0.07 93--> 99 0.28 17 --> 44
110 0.24 45 --> 68
120 0.12 69 --> 80
130 0.09 81 --> 89
140 0.06 90 --> 95
150 0.04 96 --> 99
Example 4: Solution (A news boy)
Use the following R.N :-
09 65 69 66 57 64 84 24 92 22
49 50 61 01 45 48 48 45 52 35
1st Day:
RN 09 --> Good
RN 65 --> demand = 60
Profit = 60*25 – 80*15 = 300 P.T
2nd Day:
RN 69 --> Typical
RN 66 --> demand = 80
Profit = 80*25 – 80*15 = 800 P.T
3rd Day:
RN 57 --> Typical
RN 64 --> demand = 80
Profit = 80*25 – 80*15 = 800 P.T
4th Day:
RN 84 --> poor
RN 24 --> demand = 100
Profit = 80*25 – 80*15 = 800 P.T ; we calculate with demand 80 NOT
100 as the newsboy buy only 80 news paper each day.
30/07/2022
Use the following R.N :-
09 65 69 66 57 64 84 24 92 22
49 50 61 01 45 48 48 45 52 35
30/07/2022
Example 5: The owner of car renting company, pays a penalty for
each accident according to the following distribution:
Amount of money/accident Probability
50 L.E 0.30
100 L.E 0.30
150 L.E 0.25
200 L.E 0.15
The accidents occur with the probability of 30% (number of accidents per
day is up to 6). Number of accidents per day has the following distribution:
Number of accidents Probability
2 0.05
3 0.15
4 0.40
5 0.25
6 0.15
30/07/2022
Example 5: The owner of car renting company
Based on the above simulation :- The minimum money the owner must have to cover
the penalties occurred per day (The maximum paid money in all days) = 650 L.E
END