page 155
The body of
CarPassingEvent should say:
NewPassage(distanceBetweenLoops / drivingTime)
instead of:
NewPassage(distanceBetweenLoops * drivingTime)
page 162
The definition of
ResetLog and
WriteLog should be changed to:
class OperatorControl
...
public ResetLog:() ==> ()
ResetLog() ==
atomic
( messageLog := [];
locations := [] );
public WriteLog: seq1 of char * CWS`Location ==> ()
WriteLog(message, location) ==
atomic
( messageLog := messageLog ^ [message ^ ConvertNum2String(location)];
locations := locations ^ [location] );
end OperatorControl
This change is necessary in order to ensure that the invariant (requiring the length of the instance variables
messageLog and
locations to be equal) is checked after both instance variables are updated.
page 180
The first box should be changed to:
class CongestionSensor
...
instance variables
passageSensors: map CWS`Lane to PassageSensor := {|->};
end CongestionSensor
page 292
Figure 12.3 should be changed to the attached figure.
page 364
In the solution to Exercise 7.12 should the answer for the first exercise be changed from
[true,false,4] to
[true,true,4].
page 365
In the solution to Exercise 7.16 should the answer to the last exercise be changed from
{[5]} to
{[5,4,5]}. In the solution to Exercise 8.2 should the answer to the last exercise be changed from
{1 |-> 0.5} be changed to
{|->}.
page 366
In the solution to Exercise 8.6 should the answer to the last exercise be changed from
{1 |-> 5, 3 |-> 1, 5 |-> 1} be changed to
{1 |-> 6, 3 |-> 1, 5 |-> 1}.
--
PeterGormLarsen - 21 Sep 2007