Release

Improve algorithm