Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Examples A traffic light system to be installed to control the movement of cars on two crossing roads (see the below Figure). oo. 00 +000

image text in transcribed
image text in transcribed
Examples A traffic light system to be installed to control the movement of cars on two crossing roads (see the below Figure). oo. 00 +000 Figure: Traffic light system Each traffic light has Red, Yellow and Green colours. The colour signals of the traffic lights that are located on the same road are identical all the time. The signals of the traffic lights that are located on the crossing ronds are always opposite (e.g. if one traffic light shows the Green signal, another must show the Red signal). After the Red signal, a traffic light always shows an intermedinte Yellow colour. (a) Draw a state chart diagram to represent behaviour of the traffic light system. (b) Write TLA specification to model the behaviour and check safety and liveness properties of the traffic light system. TLA specification should have: i. Correct structure (declaration of constants and variables; initial and next state predicates, a type invariant and a theorem; meaningful comments). ii. Actions of the traffic light system, defining its infinite (no deadlock) behaviour. (a) With IF-THEN-ELSE operator. iii. Invariants. (a)After the Green state, a traffic light will have the Red state. (b)The signals of the traffic lights that are located on the crossing roads are always opposite iv. Liveness properties. (a) Showing Red signal leads to the Yellow signal. (b)Traffic light system eventually often shows both Green and Red signals

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

MySQL/PHP Database Applications

Authors: Brad Bulger, Jay Greenspan, David Wall

2nd Edition

0764549634, 9780764549632

More Books

Students also viewed these Databases questions