Model of the Antikythera Mechanism