Finishing touches. Documented new time-management code.

(Comments are welcome.)