Refinement of Statemachines

From Event-B
Revision as of 23:24, 17 June 2009 by imported>Colin (→‎Refinement of Statemachines)
Jump to navigationJump to search

Refinement of Statemachines

INCOMPLETE - UNDER CONSTRUCTION

This example of an ATM (automated teller machine) shows the techniques used to make a refinement of a state machine. The example uses a machine-level state machine (i.e. not in a class). The state machines use the state-sets translation which, since there are no class instances, results in each state being represented by a boolean variable.

create a machine called ATM_A, open its class diagram and then add a statemachine called atm_sm to the canvas. Open the state machine and draw the state machine shown in the diagram below.

Atm1.jpg

Return to the package diagram, select the machine, ATM_M, and click on "Make a refinement of this Machine..." Call the refinement ATM_R.

Atm2.jpg


Open the class diagram of ATM_R and you should find a 'refined state machine' which is a clone of 'atm_sm'. Open the state machine.