SDPSem2T03DynamicModel

5
 SDP Dynamic modelling Tu torial Instructions: Wo rk in groups (preferably your cw groups). Exercise 1 (20 minutes) The Cofee Shop -- Modelling Interaction Role play Consider the working of a coffee shop: Customers come to the coffee shop to have a coffee/drink and sometimes something to eat as well. A waiter greets the customer and sits him/her at an appropriate table. When the customer is ready, the waiter takes the order and passes it to the cook and a copy to the cashier. Once the order is ready, the cook passes the food/drink to the waiter who brings it to the customer. When the customer wants to go, he/she asks the waiter for the bill. The waiter then takes the table number to the cashier who produces a bill that the waiter brings to the customer. The customer gives his payment to the waiter who then passes it to the cashier and takes the change back. Step 1: Each person in the g roup will have to take one of the following roles: Customer  Waiter  Cook  Cashier  Facilitator !bserver ( only if you have a " th  member in your group) Step 2: #pend some time (" min) to think and talk about the problem. Each person needs to write down the following information about his or h er role on a piece o f paper: 1. !"a t do I ne ed to #no$ to perform my role$% 2. !"o m do I need t o #no $ to perform my role$% %. !"at do I nee d to &e a &le to do to perform my role$% Step %: &lay the interaction scenarios (se'uences of events) from the moment a customer sits at the table. he facilitatorobserver looks for mistakesinconsistencies. 'ou are not allowed to speak to each other. epeat the same interaction passing post*it notes (which will be provided). +ou are only allowed to pass information you know (your  personal role note). he facilitatorobserver looks for i nconsistencies. Step : (Whole class) ,iscuss and compare your findings. -ny problems have to be iro ned out by dis cus sio n wit hin the whole group. For mul ate thi s int era cti on in an interaction diagram such event tracing diagram.

description

moodel

Transcript of SDPSem2T03DynamicModel

The Coffee Shop

SDP Dynamic modelling Tutorial

Instructions: Work in groups (preferably your cw groups).

Exercise 1 (20 minutes)The Coffee Shop -- Modelling Interaction Role play

Consider the working of a coffee shop:Customers come to the coffee shop to have a coffee/drink and sometimes something to eat as well. A waiter greets the customer and sits him/her at an appropriate table. When the customer is ready, the waiter takes the order and passes it to the cook and a copy to the cashier. Once the order is ready, the cook passes the food/drink to the waiter who brings it to the customer. When the customer wants to go, he/she asks the waiter for the bill. The waiter then takes the table number to the cashier who produces a bill that the waiter brings to the customer. The customer gives his payment to the waiter who then passes it to the cashier and takes the change back.

Step 1: Each person in the group will have to take one of the following roles: Customer Waiter Cook Cashier Facilitator /Observer ( only if you have a 5th member in your group)

Step 2: Spend some time (5 min) to think and talk about the problem. Each person needs to write down the following information about his or her role on a piece of paper:1. What do I need to know to perform my role?2. Whom do I need to know to perform my role?3. What do I need to be able to do to perform my role?

Step 3: Play the interaction scenarios (sequences of events) from the moment a customer sits at the table. The facilitator/observer looks for mistakes/inconsistencies. You are not allowed to speak to each other. Repeat the same interaction passing post-it notes (which will be provided). You are only allowed to pass information you know (your personal role note). The facilitator/observer looks for inconsistencies.

Step 4: (Whole class) Discuss and compare your findings. Any problems have to be ironed out by discussion within the whole group. Formulate this interaction in an interaction diagram such event tracing diagram.

Some points for discussion: Is timing important? If yes, how? Who starts a scenario? Is there something special about him/her? Ask your tutor for help if needed

Have Fun!

Exercise 2 (25 minutes) - this will be finished the following tutorial

Lift (Elevator) Simulation Case Study

The University of Greenwich has announced its intention to build a new campus library and a home for its School of Architecture & Construction. The development will be based in Greenwich town centre. The campus manager, Christine, is concerned about the number and the efficiency of the lifts proposed in the architects plans. Elena, the architect in charge of the construction has proposed creating a computer simulation of various options for the building lifts configuration, running different scenarios for each option. Elena specified the initial system requirements in a brief memo to the SE Ltd (aka your company) software consultancy firm:

The purpose of the simulation is to predict passenger queuing during the day. Various lift configurations and passenger arrival distributions are to be modelled.

Once a passenger arrives at a floor, he/she joins the queue for the lifts. Once a lift arrives at a floor, all passengers destined for this floor will exit and then queuing passengers at this floor will enter the lift, not exceeding the specified safe capacity.

The software system is to allow the user to define: the number of floors, the number of lifts and inter-floor times for each lift, the distribution over time of passenger arrivals at each floor, and the distribution of destination floors for passengers arriving at each floor. (This requirement can be waived for the first prototype system, assuming initially an equal distribution)

The simulation results should be available to produce statistics such as the average time between a passenger joining a queue and arriving at a destination, average queuing time, the longest queue and peak times. The system should also support visualisation of the whole process. Furthermore, the system should be adaptable to provide a real-time simulation facility as well.

Elena, even if she is a building architect, had a go at software architecture and came up with a basic Use Case Diagram and Conceptual Class Diagram (please see the appendix). She needs your help to take over and finish the UML modelling process. These exact tasks that you are expected to complete

Tasks :1. Discuss the given Use Case Diagram, identifying actors and the Use Cases they are involved in. Discuss ways how to improve it. You can use this part of the analysis to elicit requirements from your tutor. 2. Discuss the conceptual class diagram provided. Identify the objects involved and discuss their need for the system. 3. Develop the dynamic behaviour of the Lift system by creating the sequence diagrams. How many should they be?

Appendix:

Use case diagram (first-cut) for Lifts

The Conceptual diagram

This is just one possible solution for the conceptual diagram.