see Pampin's ATS Theory section 8:
randi is a linear-interpolation random number generator producing new random values at a Pbw rate which directly depends on Pfreq. Random values generated by randi are scaled using the time-varying energy of the partial, PE . Finally, the partial is synthesized by the addition of the amplitude scaled sinu- soidal component plus the modulated noise component:
Psynth = PampPsin + PnoiPsin where Psynth is the synthesized partial (for all frames), Pamp the partial’s time-varying amplitude, Pnoi its noise com- ponent, and Psin its sinusoidal component.