Waveforms 

 

Waveforms is a sample app the creates square, triangle, square and sine waves using Fourier series.  This is an very inefficient way to compute square waves but the purpose is to show you the math capabilites are there if you need to do such a thing.  The example is coded much the same way the textbook equation is given. After the wave is computed you can listen to it.  As previously stated, for optimum efficiency there much faster ways to compute these wave forms.  The sample is purely academic.