A recursive computer algorithm was developed which generates line spectra from experimental response functions. The method allows storing information on the mechanical properties of polymeric materials in a convenient way. The algorithm also interconverts between relaxation and retardation spectra. From the spectra, any desired response function can then be recovered. The algorithm essentially utilizes the fact that the kernel functions resemble step functions. Slightly different codes are used for each kernel function. The appearance of negative relaxation or retardation lines is obviated. Mathematically such lines would be acceptable, and they do not seriously affect reconstruction of responses within relaxation or retardation behavior. However, they would seriously interfere with interconversion between the two types of behavior, and they would also pose problems in the interpretation of the spectra.