Lubachevsky-Stillinger algorithm