Z Schema Operations: Formal Specification of a Wheat Control System

Verified

Added on  2020/03/28

|10
|1326
|382
Project
AI Summary
This project delves into Z Schema Operations, a formal specification language used to define the functionalities and properties of an information system. The assignment focuses on designing a wheat control system, detailing operations such as initializing the system, entering new silo information, accepting deliveries, managing truck queues, and generating silo and farmer accounts. The solution provides pseudo code for each operation and includes Z notations, syntax, and examples to illustrate the system's behavior. The student's contribution involved specifying requirements for each operation and integrating them into a unified specification to predict the system's behavior. References to relevant research papers are also included to support the project's concepts and methodologies.
Document Page
Running head: Z SCHEMA OPERATIONS
Z Schema Operations
Name of the Student
Name of the University
Authors Note
tabler-icon-diamond-filled.svg

Secure Best Marks with AI Grader

Need help grading? Try our AI Grader for instant feedback on your assignments.
Document Page
1Z SCHEMA OPERATIONS
Z Notations
The Z notations are mainly used in defining the Formal specifications of an
information system by using the mathematical notations. This helps in describing the required
functionalities of an information system in a precise way or the properties the information
system must have. This specifications are not constrained by the issues that affects that
affects the way in which the properties or functionalities are to be achieved. The Z notations
describes different functionalities for a system which are to be completed without specifying
the way it is going to be achieved. This abstraction provided by the Z notations makes the
formal specifications of an information system useful in the development process of an
information system.
The Z notations/schemas defines an information system while defining the different
functionalities and relations between them. This Z notations stresses on analysing a
information system while using the mathematical techniques. This techniques helps in
elimination of the ambiguity in defining the specification for the information system. In
addition to that, it also helps in avoiding the reasoning errors for specifying the functionalities
as well as proving implementation specification for the system precise as per the requirement
of the information system. It also helps in performing organized deduction of
functionalities/programs based on the predicate language as specified by the Z-notations. It
also helps in quality analysis techniques and testing the models of the information system.
Used Pseudo code for the Z schema
Init
Log in to the system.
Select specific operation to perform
Document Page
2Z SCHEMA OPERATIONS
Complete and execute the operation.
Match with the desired result.
Enter a new Silo
Start Task
Select option for opening a new account for a Silo.
Enter the Name for the new Silo, the name should be unique from the stored list in the
system.
Enter Storage Capacity of the Silo.
Enter Current amount of wheat stored in the New Silo equal to Zero.
Display-Silo is currently empty.
Completion of the Task
Accept_delivery
Start and Login to System
Select the option for Operation Accept Delivery from the Silo.
Verification of the Registration No of the Truck.
Verification of the Farmers Name.
Check and verify the load of the Truck
Verify for the capacity of the silo to store the extra load of the new truck
Document Page
3Z SCHEMA OPERATIONS
Calculate the capacity of the Silo by using the formula Capacity> current Silo Load+
Truck Load)
If the Silo can accommodate the new store load then;
Verify the load status of truck (i.e is it Unloaded or Not Unloaded)
If found unloaded;
Then unload wheat from Truck.
Else bring the next Truck from the Queue of the Trucks
Complete Performing Operation of Accepting Delivery.
End Task
Leave_queue
Start
Select the option of Leave_Queue .
Check the existing Truck Queue
If no truck is found in the queue then;
Show message “There are No Trucks in queue”
If there are trucks in the queue;
Update Queue status of the truck (Total number of Trucks in queue, Driver
Information, Registration Number, Farmer information, the number in the sequence of the
Truck in the queue)
Verify if any of the drivers of the trucks wants to leave the queue as it will take more
time to unload the truck as the queue is too long.
tabler-icon-diamond-filled.svg

Secure Best Marks with AI Grader

Need help grading? Try our AI Grader for instant feedback on your assignments.
Document Page
4Z SCHEMA OPERATIONS
Update latest status of the Queue after drivers leaves the queue.
Complete the operation of Leave_queue
End
Silo_account
Start
Select the option for Silo_Account
Show the list of Carried Trucks on the Silo
Calculate the total of amount of wheat delivered through the Silo by using the
following
(Sum=weight (load of truck1+load of truck2+…………. +load of truck n)
Display the total Amount
Complete operation Silo_Account.
End
Ships_total_account
Start
Select the option for Ships_Total_Account
Show the full list of Silos from where the Wheat is loaded on a Ship.
Calculate the total amount of wheat delivered through the silo (Sum=(Silo1
weight+Silo2Weight +…………+Silo n)
Display the Total Amount
Document Page
5Z SCHEMA OPERATIONS
Operation completed
End
Farmer_Account
Start
Select the option for Farmer Account
Show the full list of Farmers who delivered wheat on the silos
Accept the Farmer number
Complete operation
End
Z schema for the operations
Following are the commonly used syntax and notations in developing the Z notations
for the different operations proposed for an information system.
: In Z specification this is known as the Negation
˄: This is known as the Conjunction
˅: This is known as the Disjunction
∃: This is known as the Existential Quantifier.
: This is known as the universal Quantifier.
Document Page
6Z SCHEMA OPERATIONS
Operation Init
Truck control System
Operation Name?: Init
˅ Name? : Select operation
Output! acceptOutput
Known Name= known {name?}
{Operation Display→Not a valid Operation}
Operation: Enter_new_Silo
Wheat Control Truck System
Name ? : Enter_new_Silo
Outcome! New Silo Info
{{Name of Silo : Name of Silo Name Of Silo List}
Add new account
Operation : Add FarmerAccount
∆ Add New Farmer Account
Name? : List of NAME s
Date? : DATE ˄ result! : REPORT
(Name? / known Add Name! = day {name? $ date?}
Result! = ok)
tabler-icon-diamond-filled.svg

Paraphrase This Document

Need a fresh take? Get an instant paraphrase of this document with our AI Paraphraser
Document Page
7Z SCHEMA OPERATIONS
(name? known Delivery List! = Delivery List result! = already known)
Accept_delivery
Delivery
Silo owner: Registration num Truck
Created,
Updated: Time
Unload: wheat
Load ≤ Silo capacity
Accommodate: Extra Load
Created ≤ expires
Next Silo.
Leave_queue
Wheat Control Truck System
Wheat Truck→Queue→Silo
OperationName ? Leave_Queue
Check Time for unload: More than T hours
Outcome! Status of the Queue
Leave queue
Ships_total_account
Operation Ship total account
Document Page
8Z SCHEMA OPERATIONS
Farmer→ Wheat Truck→ Silo
Name ? Accept Delivery
Sum total weight: Load of trucks,
⌐ Total Capacity of Silo.
Complete Total;
My contribution in the designing the schema
In this task, I was responsible for specifying the different requirements for each of the
six operation separately. After that, the requirements were combined in a single specification
in order to determine and predict the behaviour of the proposed information system while
carrying out the above mentioned different operation. Here it is important to state that, all the
specifications are developed separately but it does not imply that each of them is to be
implemented separately but they can be implemented in a combined way.
Document Page
9Z SCHEMA OPERATIONS
References
Grant, E. S., & Brown, T. (2016). Towards Rigorous Transformation Rules for Converting
UML Operation Signatures to Z Schema. In Proceedings of the International
MultiConference of Engineers and Computer Scientists (Vol. 1).
Tan, Z. (2014). A user anonymity preserving three-factor authentication scheme for telecare
medicine information systems. Journal of medical systems, 38(3), 16.
Yin, H., Cui, B., Chen, L., Hu, Z., & Zhou, X. (2015). Dynamic user modeling in social
media systems. ACM Transactions on Information Systems (TOIS), 33(3), 10.
Jamal, M., & Zafar, N. A. (2016, December). Formalizing structural semantics of UML 2.5
activity diagram in Z Notation. In Open Source Systems & Technologies (ICOSST),
2016 International Conference on (pp. 66-71). IEEE.
chevron_up_icon
1 out of 10
circle_padding
hide_on_mobile
zoom_out_icon
[object Object]