A relation between the coefficients in the recurrence formula and the spectral function for orthogonal polynomials