The state analysis and optimal control of time-varying discrete systems via Haar wavelets are the main tasks of this paper. First, we introduce the definition of discrete Haar wavelets. Then, a comparison between Haar wavelets and other orthogonal functions is given. Based upon some useful properties of the Haar wavelets, a special product matrix and a related coefficient matrix are proposed; also, a shift matrix and a summation matrix are derived. These matrices are very effective in solving our problems. The local property of the Haar wavelets is applied to shorten the calculation procedures.