very slow version of precision optimization added