Many (discrete) stochastic systems are analyzed using the probability generating function (pgf) technique, which often leads to expressions in terms of the (complex) roots of a certain equation. In this paper, for a class of pgfs with a rational form, we show that it is not necessary to compute the roots in order to evaluate these expressions. Instead, one can use contour integrals, which is computationally a more reliable method than the classical root-finding approach. We also give the necessary and sufficient condition for the mean of the corresponding random variable, e.g., queue length, to be an additive function of the roots. In this case, the mean is found using one contour integral. Finally, we give the necessary and sufficient condition for the mean to be independent of the roots.