Migrated algorithm lib to qt5