Among the causes of railway vibrations, rail and wheel roughness is recognized as a major contribution. The excitation mechanism at work when rough wheels run on rough rails can be assimilated to a prescribed relative displacement between the wheels and the rails. This article deals with the modeling of this wheel/rail interaction phenomenon, using a 3D FEM approach. The input excitation data is the combined wheel / rail roughness spectrum, while the sought output is the spectrum of dynamic forces transmitted to the support. Characterization of these dynamic forces can be used, for instance, to assess the anti-vibration performance of a track. The presented approach overcomes the limitations of 2D or analytical approaches commonly encountered in dynamic studies of railway tracks: (a) It takes advantage of the finite element modeling flexibility, compared to analytical approaches, which are developed for specific configurations. (b) It can account for the infrastructure's dynamic flexibility, whether it is invariant in the longitudinal direction or not. (c) It can account for the 3D dynamic behavior of the track. As an illustration, the method is applied to a floating slab track, thereby showing the importance of the transverse modal behavior of the track in this case.