i have learnd that there is a formula(i cant find it yet)
were you can calculate the harmonics of the saw,square,triangle,ecc. just by adding sinewaves
i think it is for the saw: 2ndharmonic= 2*freq/(amp/2) 3rdharmonic=3*freq/(amp/4)...
how about to add different sinewaves and with that formula into the js code and lets say to calculate 24 harmonics for each....
it will be a long code...
has somebody tried that?
are there some problems with disturbs or noise or something?
and thanks for the answers....
edit:
if that is a solution i could do that with excel..
has the alaising thing to do with the "Nyquist–Shannon sampling theorem"?
This says that a audio signal with fmax can be reconstructed as a digital signal if the sampling frequency is bigger than 2*fmax. (Got this from wikipedia, correct me if i am wrong)....
if the frequency is higher than fmax*2... then i have to apply a lowpassfiler? with cutting(idk if this is the right therm) of -60db?
has that to do with the 44100?