add search of best solution in LSQ