I need to play thousands of simple sounds (generated tones) at the same time. If I am understand correctly there should be a way to add them together in complex wave but i really can't see the light in the end of the tunnel. Is there any good advice reads or formulas for beginners?

  • 1
    $\begingroup$ Welcome to DSP.SE! Unless you have a specific relationship between the sine waves, that will sound pretty awful. What are you trying to achieve? $\endgroup$
    – Peter K.
    Nov 13, 2015 at 14:29
  • $\begingroup$ Well, i am experimenting with sound, the "beauty" of sound is not a problem, i just need results to be "true", same as if i am put real world sounds in front of me and will change tones. I was trying to achieve it with many sounds played together at the same time but found that on apple sound engine you can "only" use 150 players playing at the same time, no more, but I want to experiment with hundreds/thousands if it is possible, so i thought that i can use only one player with computated waves to achieve that. $\endgroup$ Nov 14, 2015 at 4:02

1 Answer 1


You can add each sample of each sound in time. Say something like

Y[0] = X0[0] + X1 [0] + ...

You may need to check the maximum value when you are done and scale signal back down so the media will play in whatever format you are using

  • $\begingroup$ Hm, will try that way but can imagine the result right now, thank you $\endgroup$ Nov 14, 2015 at 3:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.