[sdiy] Digital Waveshape Generator.

Mike Bryant mbryant at futurehorizons.com
Mon Jul 14 16:30:19 CEST 2025


Yes that's moreorless what I've done on the Pi.  As you say you can create any sound, although the problem is designing a user-interface that is easy to use - which mine isn't 🙁
________________________________
From: brianw <brianw at audiobanshee.com>
Sent: 14 July 2025 03:01
To: Mike Bryant <mbryant at futurehorizons.com>
Cc: synth-diy <Synth-diy at synth-diy.org>
Subject: Re: [sdiy] Digital Waveshape Generator.

... and on a related note, what you've described, Mike, is basically what the Technos Axcel does. That hardware was limited to 1024 sine wave oscillators, but also had amplitude envelopes as well as pitch envelopes for each sine oscillator. You could resynthesize basically any sound, on create from scratch.

Once I realized that I could synthesize thousands of sine waves in real time on a MacBook Pro, I partially recreated the Technos Axcel in software. It was impressive what could be done with a mere 32 oscillators, but I stopped short of creating the pitch envelopes, so samples with vibrato were not perfect recreations.

Brian


On Jul 13, 2025, at 6:27 PM, brian wrote:
> Oops!
>
> Somehow I read your suggestion incorrectly, Mike. I thought you were suggesting that the inverse FFT be used to synthesize the desired waveform.
>
> You're right, of course, that sinusoidal oscillators mixed together will not alias (as long as the mix doesn't clip).
>
> Sorry for the wordy sidetrack...
>
> Brian
>
> On Jul 13, 2025, at 6:19 PM, brian wrote:
>> On Jul 13, 2025, at 8:53 AM, Mike Bryant wrote:
>>>> I believe it's standard operating procedure to store waveforms that won't alias at the intended frequencies.  And that this usually involves separate waveforms for each octave above a certain point.  And that's not really a problem because for each octave up you only need half as waveform many entries.
>>>
>>> Or just draw out the waveform you want, FFT it, then feed valid frequencies less than Nyquist together with the phase to a bank of sinusoidal digital oscillators on an MCU.  You can get 1200 of them simultaneously with full envelope control using a Pi CM4.
>>
>> It seems that you're forgetting that the FFT actually represents an infinitely-repeating cycle, but there can be a discontinuity between the last and first sample when the cycle repeats ... and thus the IFFT is not guaranteed to produce a waveform without aliasing.
>>
>> Any discontinuity becomes an infinite series, albeit with diminishing amplitude as the harmonics get higher. The larger the discontinuity, the higher the amplitude. The FFT (and iFFT) cannot remove this, because it doesn't "see" it.
>>
>> Another important fact is that the FFT does not actually include frequencies above Nyquist, so there isn't really any way to "exclude" frequencies above Nyquist. Put another way, the input to an inverse FFT is *always* only valid frequency bins that are less than Nyquist. Technically, the complex values (real and imaginary) that are fed as inputs represent the frequencies up to Nyquist, and then a mirror-image reflection of those same frequencies as negative frequencies that are still "below" Nyquist. Most FFT subroutines deal with only the real data, which is entirely below Nyquist, but even if you use a subroutine that takes complex numbers as input, there's no way to limit the output frequencies to be below Nyquist.
>>
>> i.e. FFT and inverse FFT are not a magic bullet that allows you to create arbitrary waveforms without aliasing.
>>
>>
>> Looking at the process from a different angle, drawing a waveform that you want will potentially create aliased overtones (which are no longer on the correct harmonic multiples after aliasing). So performing an FFT on this will output the aliased frequencies as well as the non-aliased frequencies. There's no way for the FFT to separate the good from the bad if the input is already a mix of aliased and non-aliased frequencies.
>>
>> Brian

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://synth-diy.org/pipermail/synth-diy/attachments/20250714/f60dd61f/attachment.htm>


More information about the Synth-diy mailing list