taocp

This site has no text of the book. Keep your own copy of TAOCP next to it. See what is checked.

Exercise · Volume 1 · 2.2.5-3

Exercise 2.2.5-3

not stated yet in Lean solution written

Rating22
KindInformal: the exercise has no formal statement, so Lean does not state it from the written solution
SectionSection 2.2.5 of Volume 1

The task

The elevator model has three call variables per floor, CALLUP\mathrm{CALLUP}, CALLCAR\mathrm{CALLCAR} and CALLDOWN\mathrm{CALLDOWN}. Explain how an experimenter could press buttons in a chosen order to prove that there are three independent binary variables on each middle floor.

The exact wording is in your copy of the book.

Hints

Open one hint at a time. Try the exercise again after each.

Hint 1

Look for two situations that differ in only one variable and in which the elevator behaves differently.

Hint 2

Read steps E2, E7 and E8 for what each variable alone causes.

Solution

Show the solution

It is enough to show that no variable can be computed from the other two, and that no two can be merged.

CALLUP\mathrm{CALLUP} against CALLDOWN\mathrm{CALLDOWN}. Let the elevator go up past floor 33 on its way to floor 44, where somebody has pressed the button in the car. In step E7 the elevator stops at a floor if CALLCAR\mathrm{CALLCAR} or CALLUP\mathrm{CALLUP} is set. It stops for CALLDOWN\mathrm{CALLDOWN} only when nothing is called above that floor, or for floor 22. So when a person on floor 33 has pressed the up button, the elevator stops there. When the person has pressed the down button, the elevator passes floor 33. Therefore the two variables are different. The mirrored experiment with the down trip shows the same.

CALLCAR\mathrm{CALLCAR} against the other two. In step E2, when the elevator going up finds nothing called above its floor, it turns to GOINGDOWN\mathrm{GOINGDOWN} if some CALLCAR[j]\mathrm{CALLCAR}[j] with jj below is set, and otherwise it turns to NEUTRAL\mathrm{NEUTRAL}. The hall variables CALLUP[j]\mathrm{CALLUP}[j] and CALLDOWN[j]\mathrm{CALLDOWN}[j] below are not looked at. So run two experiments that are equal except that a person has pushed an in-car button for floor 11 in the first and a hall button on floor 11 in the second. When the elevator opens its doors at the top, its state is GOINGDOWN\mathrm{GOINGDOWN} in the first and NEUTRAL\mathrm{NEUTRAL} in the second. The difference shows when the next person gets in. In state NEUTRAL\mathrm{NEUTRAL} that person chooses the direction, and the doors close after only 25 units, while in state GOINGDOWN\mathrm{GOINGDOWN} the direction stays and the doors wait for the usual time.

With a hall button of either kind in the first experiment, no variable of the pair CALLUP\mathrm{CALLUP}, CALLDOWN\mathrm{CALLDOWN} can reproduce the effect of CALLCAR\mathrm{CALLCAR}, since the second experiment may use either of them. Together with the first experiment, this shows that the three variables are independent.

Remarks

Table 1 of the text has examples of both effects: the elevator passes floors where people wait to go down, and it decides its direction when the doors open from the in-car buttons.

This solution is drafted, and a person has not reviewed it yet. The source.

In Lean

not stated yet The exercise is not stated in Lean yet.

The status is computed from the Lean build. The node of the map.

Something is wrong? Report it.