Integrable algorithm