modifed precision when searching distance