Assignment 1 CE-407 Simulation & Modeling

You might also like

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 4

Roll#: ___________2017-CE-155__________Section: __C _

Name:_Areeba Ashraf___

Department:-Computer Engineering Program:B.S- Computer Engineering

Assignment 1

CE-407 Simulation & Modeling

Announced date:1-8-2020 Due Date:20-8-2020 Total Marks =01

Teacher Name: Dr. Shakil Ahmed, Ms. Huma, Ms. Kiran & Ms. Safina

(CLO_1)(Cognitive Level C2 e.g., Understanding) (PLO_1:Engineering Knowledge)

Q1:Name several entities,attributes,activities,events,and state variables for the following


systems.
i. A cafeteria,
ii. A grocery store,
iii. A hospital emergency room,
iv. A Taxicab company with 10 taxis.

ANSWER:
i. A CAFETERIA :
Entities : customers, waiter, cashiers
Attributes : hungry, skillful, fast, responsible
Activities : take orders, collect orders, dispatch orders
Events : arrival and departure of customers
State Variables : number of occupied tables, no of orders per table, no of customers
in the waiting list.

ii. A GROCERY STORE :

Entities : customers, cashiers, sales person


Attributes : skillful, fast, responsible, honest
Activities : sell products, organize carts in the store
Events : arrival and departure of customers, lack of products
State Variables : number of products sold per day, no of customers in the waiting
list.

iii. A HOSPTAL EMERGENCY ROOM :

Entities : patients, doctors, nurses


Attributes : experienced, responsible, intelligent
Activities : heeling the patients, feeding patients, monitoring patients
Events : arrival and departure of patients, lack of medicines, lack of equipments
State Variables : number of patients, no of beds, no of occupied beds, no of cases

iv. A TAXICAB WITH 10 TAXIS :

Entities : taxi, taxi driver, customers


Attributes : safe driver, responsible, reliable, good condition of taxi
Activities : picking and dropping customers, collecting payments
Events : taxi cab with mechanical fault, absence of driver, detained taxi
State Variables : number of customers, amount of mileage per taxi in a day, amount
gained per day

Q2: A baker is trying to figure out how many dozens of bagels to bake each day. The probability
distribution of the number of bagel customers is as follows

Number of 8 10 12 14
Customers/day
Probability 0.30 0.35 0.20 0.15

Customers order 1, 2, 3, or 4 dozen bagels according to the following probability distribution.


Number of Dozen 1 2 3 4
ordered/
customer
Probability 0.4 0.3 0.2 0.1

Bagels sell for $8.40 per dozen. They cost $5.80 per dozen to make. All bagels not sold at the
end of the day are sold at half-price to a local grocery store. Based on 5 days of simulation, how
many dozens (to the nearest 5 dozen) bagels should be baked each day?

ANSWER :

Number of Probability Cumulative Random-Digit


Customers/ Day Probability Assignment
8 0.30 0.30 1—30
10 0.35 0.65 31—65
12 0.20 0.85 66—85
14 0.15 1 86—00

Customers order 1, 2, 3, or 4 dozen bagels according to the following probability distribution.


Number Of Dozen Probability Cumulative Random-Digit
Ordered/ Customer Probability Assignment
1 0.4 0.4 1—40
2 0.3 0.7 41—70
3 0.2 0.9 71—90
4 0.1 1 91—100

Day Number of RD for Dozen Revenue from


Customers Demand Ordered Retails $
1 6 3 2 16.80
9 4 33.60
4 1 8.40
5 3 25.20
8 2 16.80
12 2 16.80
Total 41 14 117.60
2 8 2 3 25.20
8 4 33.60
5 1 8.40
9 2 16.80
4 4 33.60
6 1 8.40
9 3 25.20
4 4 33.60
Total 47 22 184.80
3 4 7 3 25.20
2 3 25.20
9 2 16.80
4 4 33.60
Total 22 12 100.80
4 7 8 4 33.60
3 4 33.60
5 2 16.80
9 1 8.40
2 3 25.20
4 3 25.20
5 1 8.40
Total 36 17 151.20
`5 5 9 2 16.80
4 1 8.40
3 4 33.60
6 3 25.20
5 2 16.80
Total 27 12 100.80

RESULT :
Average = 15.4 dozens/day should be baked.

You might also like