The problem of designing a linear predetection filter for the detection of a sampled random signal in additive noise is considered. The design of the filter is based on an optimality criterion which maximizes the signal-to-noise ratio enhancement. The optimum weighting function obtained in this manner has the advantage that it is independent of signal characteristics and depends only on the covariance function of the noise. The optimum filter, for general covariance functions, is obtained forN = 2, 3and4samples. The asymptotic solution for largeNis also presented by employing results from the theory of Teeplitz forms. In addition, the complete solution for allNis given for several particular covariance matrices. An application of the results is made to the problem of designing a linear predetection filter in a moving target indication (MTI) radar system. The optimum weighting function forN = 2is a single-cancellation unit, while that forN = 3is similar but not quite the same as a double-cancellation unit. It is shown that the signal-to-noise ratio enhancement provided by the double-cancellation scheme is1.76db worse than that of the optimum filter when the noise has a Gaussian covariance function.