Borrowing Ideas from Other Languages™️
Declarative solutions generally are the prettiest.
We can take magical idioms from other languages and stuff them into Python.
It isn’t as pretty though.
This is a declarative, functional synthesizer written in Python. I wrote it back in 2020.
How it works:
- A generator that counts up all the natural numbers is created
- Each created number is divided by the sample rate to create a time value
- This time value is fed into a function describing a waveform
- Beautiful “Music” 😬 comes out the other end
Demo 🎵
Show Me Teh Code!!!!11
Do whatever you want with the source code, remix it, use it for a school project, use it for low orbit geolocation software, I don’t care.
Resources
- There are no resources
- Why am I awake at 3am