Localized and resonant transverse elastic waves associated with the surface of a semi-infinite superlattice or its interface with a substrate are investigated. These modes appear as well-defined peaks of the vibrational density of states, either inside the minigaps or inside the bulk bands of the superlattice. The densities of states, which are calculated as a function of the frequency omega and the wave vector k(parallel-to) (parallel to the interfaces), are obtained from an analytic determination of the response function for a semi-infinite superlattice with or without a cap layer, and also for a superlattice in contact with a substrate. Besides, we show that the creation from the infinite superlattice of a free surface or of the substrate-superlattice interface gives rise to 8 peaks of weight (1/4) in the density of states, at the edges to the superlattice bulk bands. Then when one considers together the two semi-infinite superlattices obtained by cleavage of an infinite one along a plane parallel to the interfaces, one always has as many localized surface modes as minigaps, for any value of k(parallel-to). Although these results are obtained for transverse elastic waves with polarization perpendicular to the saggital plane (containing the propagation vector k(parallel-to) and the normal to the interfaces), they remain valid for the longitudinal waves in the limit of k(parallel-to) = 0. Specific applications of these analytical results are given in this paper for Y-Dy or GaAs-AlAs superlattices. The effect of a Si surface cap layer on the surface of this last superlattice is also investigated.