Added extra argument and tolerance