Functional programming has long left the domain of academia. But what does it truly mean to be general purpose? It means that you can wirte programs for all domains, such as steering your CNC router, and literally cutting metal using functional programming.
Last year, me and Franz Thoma held a workshop on generative art at BOB, and our associated library. The pictures, while nice, are still digital, so I set out to build an almost-DIN-A1-sized CNC router that now resides in my living room.
The instructions this machine runs is called G-Code, a semi-standard machine code used by all sorts of CNC machines, e.g. 3D printers, mills, or laser cutters. My machine is a pen plotter (for safety reasons – for now), and it moves a pen over paper, thousands of times, for hours on end, to paint pretty pictures. This machine code is 100% generated by Haskell.