- #1
btb4198
- 572
- 10
how do I to change the harmonic of a sin wave ? I want it to sound more like a real note.
I tried this :
buffer[n] = Amplitude * Math.Sin(Math.PI * Frequency * n / 44100D) + (Amplitude/2 * Math.Sin(Math.PI * Frequency/2 * n / 44100D)) + (Amplitude/2 * Math.Sin(Math.PI * Frequency *2 * n / 44100D)));
but the sound has a beat ... I was told that is you times the Frequency be two or dived the Frequency by two it was not have a beat, but that is not right
is there another way?
I tried this :
buffer[n] = Amplitude * Math.Sin(Math.PI * Frequency * n / 44100D) + (Amplitude/2 * Math.Sin(Math.PI * Frequency/2 * n / 44100D)) + (Amplitude/2 * Math.Sin(Math.PI * Frequency *2 * n / 44100D)));
but the sound has a beat ... I was told that is you times the Frequency be two or dived the Frequency by two it was not have a beat, but that is not right
is there another way?