Added additive synthesis / Fourier synthesis waveform generator for A-112 to use

Squashed commit of the following:

commit 954e1d73e2e23c1ae0b018d06733acbf001c51cc
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Tue Oct 23 10:44:59 2012 +0100

    Bug fixed.  Made a beautiful triangle wave!

    All this time, the issue was that I was including extra harmonics
    by mistake, due to my oversimplifying how I imagined bitwise comparisons
    worked.  The actual theory is sound.

commit a626532d5d41588a29fcaa482d3f64eac5197725
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Tue Oct 23 10:04:33 2012 +0100

    The waveform's still wrong...

    ...but at least now it's the right way up.  I've swapped the polarities
    around to compensate for the fundamental harmonic being divided by 1.

commit 3b35d45f5d5c2e18d80bf3ae3f3b804041c0411c
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Mon Oct 22 22:54:35 2012 +0100

    Revert "Trying it this way..."

    This reverts commit 255ddac3d56a3556bfe0b9c33b9a161d0a7ac721.

commit 255ddac3d56a3556bfe0b9c33b9a161d0a7ac721
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Mon Oct 22 22:54:00 2012 +0100

    Trying it this way...

    ...same thing.  Bah.  Time for bed.  Using
    http://en.wikibooks.org/wiki/Sound_Synthesis_Theory/Additive_Synthesis#Constructing_common_harmonic_waveforms_in_additive_synthesis
    this time, which says the same thing, so maybe I'm doing something
    wrong...  (Not that I thought otherwise...)

commit 973a3470289faa2d5fecbae0ea26ffa27c8f48b9
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Mon Oct 22 22:23:27 2012 +0100

    Got something much closer

    ...after re-skimming the Wikipedia page and realising it requires
    both the inverse square law *and* the negative value every other
    time.

commit f588438dbbed1646fb17be33f36ed8be2fd12893
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Mon Oct 22 22:21:00 2012 +0100

    Now that's just odd...

    I'm ditching my own idea of how to build a triangle wave (likely
    gleaned from Gorden Reid's Synth Secrets series) in favour of
    Wikipedia.  Yet this is yet something else.

commit 9bfb3efa594b5e0a09552909b13978c68887131d
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Mon Oct 22 22:16:56 2012 +0100

    The triangle wave isn't working so well, although it's an interesting shape...

commit 95a4189c9d3a7c07c0f9c7d72fad3607e50cac2c
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Mon Oct 22 22:15:20 2012 +0100

    The additive square wave generator now works well too.

commit d154612a2e0ee5b2cc40b1d337690cfd27f6273d
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Mon Oct 22 22:10:56 2012 +0100

    The additive sawtooth generator now seems to work very well...

    ...although the number 1.85 seems suspiciously arbitrary.

commit c8a83d0ce9a1ee9400c09edfabe625a68da7569b
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Mon Oct 22 22:01:00 2012 +0100

    Revert "WTF?  We're counting to 127 in increments of pi. o.O"

    This reverts commit 3e5b30ed256a5ebe7db4c7b212da41be1e6f2152.

commit 3e5b30ed256a5ebe7db4c7b212da41be1e6f2152
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Mon Oct 22 22:00:03 2012 +0100

    WTF?  We're counting to 127 in increments of pi. o.O

commit c26b3dd07ac003a3f66e9d0b4c2341f0a655fc41
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Mon Oct 22 21:56:50 2012 +0100

    Fixed first (pure sine) cycle

commit 635150bca7358bf49fc2a899779bd2d8d12267ad
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Mon Oct 22 21:53:30 2012 +0100

    Almost there with the sawtooth waveform...

commit b4ac1fb026f88eb3ee87a10cc45691bf008d6470
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Mon Oct 22 21:45:52 2012 +0100

    Nearly there...

    Still making sine waves, but now implementing everything except the
    formulae themselves, and I can get those easily enough from
    http://bytenoise.co.uk/Periodic_waveform ...

commit 9ad3630be72bfaf001b491346b6303c16c734bdb
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Mon Oct 22 21:39:59 2012 +0100

    Fixed the signing issue

    OK, so we're writing an unsigned wave file.

commit bba48c01880bd413f59d5fbf5b6632f86c487adf
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Mon Oct 22 21:30:26 2012 +0100

    Generating a sine wave

    ...except the un/signed bit's not right yet.

commit a743929c65d2729d00c6725b8a4a6f93e10a5604
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Mon Oct 22 12:00:13 2012 +0100

    at least got rid of errors...

commit 69871e29db15a6c7b50c6a8c5b7c233a8c6707f4
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Mon Oct 22 11:52:14 2012 +0100

    Fixed file writing and maths importing

commit 6b5eb49b90364d8411d5c99637a685226ada9d5f
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Mon Oct 22 11:20:45 2012 +0100

    Started work on additive synthesis based waveform generator for Doepfer A-112