search foor nearest and target point