A mathematical clock