Behavior : State Machine Diagrams - What is a State and State Machine - Qualitatively different states

4 important questions on Behavior : State Machine Diagrams - What is a State and State Machine - Qualitatively different states

When any attribute is different, it is possible to define a new state. Unfortunately, this is not always useful.

When is it not useful? (give an example)



Consider a Clock. There is a state where the Clock is 1:00 am, and one
where it reads 1:01 am, and one where it reads 1:02 am, and so on.

This approach would make an enormous, not very useful, state machine, with at least 720 states.

If we went to seconds and modeled a 24-hour Clock, we would
have 86,400 states.


All of them nearly the same. For a Clock, instead, we might want to have the possible states of Running, Stopped, BeingSet, AlarmSetOn, 24HourModeOn, and Ringing
Report

When the Clock. query is performed in any one of the 86,400 states, the behavior works the same, even though the time returned is different.

If the only difference between the results of operations in two states is a .... ?

quantitative difference, perhaps the states are the same.
Report

If the only difference is a quantitative difference, we also usually treat them as..... ?

one state
Report

When choosing states, choose states where .....?

The object’s behavior is significantly different from its behavior in other states, and the differences are relevant to understanding the object and contributing to understanding the system.
Report

The question on the page originate from the summary of the following study material:

  • A unique study and practice tool
  • Never study anything twice again
  • Get the grades you hope for
  • 100% sure, 100% understanding
Remember faster, study better. Scientifically proven.
Trustpilot Logo
  • Higher grades + faster learning
  • Never study anything twice
  • 100% sure, 100% understanding
Discover Study Smart