algorithms MPs