To _completely_ prevent aliasing of a harmonic series extending
infinitely is obviously impossible when you're limited to a finite
Very slightly more practically, eventually the generated harmonics
will drop below the noise floor. Where that limit lies is of course
specific to your particular setup and quality demands, and strongly
dependent on the amplitude of the signal to be waveshaped. As the
input amplitude rises, the tanh output will approach a square wave,
with harmonic amplitudes following the well-known 1/n series.
Assuming this to be a desired outcome of the manipulation, a noise
floor of just 72 dB results in
n = 10**(72/20.) = 3981.0717055349733
and for a noise floor of 90 dB it's
10**(90/20.) = 31622.776601683792
In the end, I think it's safe to assume such oversampling ratios
intractable for practical purposes.
Linux-audio-user mailing list