1. Given an ATM machine, assume the maximum case withdraw per day is $500. Define the operation of withdraw using correc
-
- Site Admin
- Posts: 899603
- Joined: Mon Aug 02, 2021 8:13 am
1. Given an ATM machine, assume the maximum case withdraw per day is $500. Define the operation of withdraw using correc
Power set: Ã
Change/update of database: Dbook
No update of database: Xbook
First Order Logic:
Quantifiers:
There is at least one element p in theset of patron: $ p Î patron.
For all elements b in the set ofbook: " b Î book.
Schema:
Borrow-Success
D patron
{< “Prof.”, Yujian Fu, 10111111, l, 0, l>, … }
/* set declaration is here */
/* constraints are defined here */
X ¹ ∆ " $ Î £ ³ Ù Ú
1. Given an ATM machine, assume the maximum case withdraw per day is $500. Define the operation of withdraw using correct Z notation. (Hint: you need to define the necessary data and initial schemas for the ATM machine. For the operation of withdraw, you need to specify operation successful or failure, respectively.) Given an online DVD rental system (e.g. Blockbuster), define the search operation and checkout operation using correct Z notation. Given a railway station with one way east-west, and one way west-east, a road cross the railway, one way south-north and one way north-south. Define the search operation and checkout operation using correct Z notation. 4. Given a coffee machine, define the brewing operation using correct Z notation. I 2. 3. 5. Model the behavior of the control system that lowers and raises the gate where a road crosses a railway. ACCOR ↑ Far Near Train Passed Road Near Far Train Passed
There are two sensors, e.g. Sensor One (left) and Sensor Two (right) respectively, telling the gate that a train is passed. This is a classical example of a real-time system, which we will only model very coarsely here, assuming that there is only a single track with only one train at a time and one gate in this assignment. However, a train could go in either direction. There are some specifications of the scenario following. When a sensor detects that a train passes, it will emit the signal "Train Passed" to the gate controller system, in order to make the gate start moving to the opposite direction to the previous one, e.g. from state up to state down We assume that the gate needs between 20 and 30 seconds to be lowered (to go from the state up to the state down) or be raised (to go from the state down to the state up) or to come down The gate cannot be moved when the train is passing. Otherwise, it will lead to tragedy Your task is to: . . ● . model the system by using correct Z notation. point out weaknesses of the system, and describe how the system could be improved to be more safe.