Exercise 04 - UML Part III: State Machine Diagrams
Foto by Jeff Kubina
Prelab
Please do read this Introduction to State Machine Diagrams before coming to lab!
I will only give a brief intro/Q&A to State Machine Diagrams in the lab.
Assignment
Your job in this exercise is to model all of the following systems (2 points per system for 1-3, 4 points for system 4):
Model the modified goat/cabbage/wolf problem: The farmer is in Schöneweide and wants to get his goat, his cabbage and his wolf over to Oberschöneweide. Only one thing can fit in his boat at a time beside himself. He cannot leave the cabbage and the goat or the goat and the wolf alone on the same side of the river, for obvious reasons. Is it possible for him to get all three possessions across the Spree? Draw a State Machine Diagram modelling a solution to this problem.
Model the states an IMI student passes through from the first until the sixth semester. (Special prize for the most humorous model that is not offensive.)
Model an algorithm that determines if a given string is a proper floating-point number, i.e.
[sign] integerpart dot fractional part [E exponent]
Model the states in an Pumpkin order in the HTW system can be in.
Lab Report
Your Lab Report should include reflections on the process of producing the diagrams and, as always, names of all collaborators and the time needed to complete the exercise.
Based on Exercise04 by Prof. Dr. Debora Weber-Wulff