In computational complexity theory, the linear search problem is an optimal search problem introduced by Richard E. Bellman and independently considered by Anatole Beck.
"An immobile hider is located on the real line according to a known probability distribution. A searcher, whose maximal velocity is one, starts from the origin and wishes to discover the hider in minimal expected time. It is assumed that the searcher can change the direction of his motion without any loss of time. It is also assumed that the searcher cannot see the hider until he actually reaches the point at which the hider is located and the time elapsed until this moment is the duration of the game."
The problem is to find the hider in the shortest time possible. Generally, since the hider could be on either side of the searcher and an arbitrary distance away, the searcher has to oscillate back and forth, i.e., the searcher has to go a distance x1 in one direction, return to the origin and go distance x2 in the other direction, etc., (the length of the n-th step being denoted by xn). (However, an optimal solution need not have a first step and could start with an infinite number of small 'oscillations'.) This problem is usually called the linear search problem and a search plan is called a trajectory.
The linear search problem for a general probability distribution is unsolved.[1] However, there exists a dynamic programming algorithm that produces a solution for any discrete distribution and also an approximate solution, for any probability distribution, with any desired accuracy.
The linear search problem was solved by Anatole Beck and Donald J. Newman (1970) as a two-person zero-sum game. Their minimax trajectory is to double the distance on each step and the optimal strategy is a mixture of trajectories that increase the distance by some fixed constant. This solution gives search strategies that are not sensitive to assumptions concerning the distribution of the target. Thus, it also presents an upper bound for a worst-case scenario. This solution was obtained in the framework of an online algorithm by Shmuel Gal, who also generalized this result to a set of concurrent rays. The best online competitive ratio for the search on the line is 9 but it can be reduced to 4.6 by using a randomized strategy. Demaine et al. gave an online solution with a turn cost.
These results were rediscovered in the 1990s by computer scientists as the cow path problem.