Multidimensional Dataflow in Lucid
billwadge.wordpress.com
billwadge.wordpress.com
https://billwadge.wordpress.com/2011/03/23/lucid-the-origins...
And then work your way forward. The book is also great: http://www.cse.unsw.edu.au/~plaice/archive/WWW/1985/B-AP85-L...
This stuff has a very direct line to the modern "FRP" ideas (with the exception of the actual FRP by Conal Eliot, which is actually quite different from what most of us call FRP, oh details...). And it's so much more cogent.
Also check out the Wikipedia page: https://en.wikipedia.org/wiki/Lucid_(programming_language)
When I looked at it a while ago, I couldn't find a working implementation, so I banged on it until I got something that at least appeared to work (on OS X): https://github.com/mpw/pLucid-osx
I was reading up on streams as found in RxJS at the time, and though I am not yet an accomplished stream-wrangler their power is clear. Streams (or something like them, since Lucid's dataflows are different) be a core part of a language struck me as a good idea, and having only heard about Reactive Extensions in the past couple years it was surprising that the first example of first-class streams I encountered was 30 years old.
Sorry, I see that my words were ambiguous: it's not my implementation. I just took the existing pLucid implementation (which wasn't working) and banged on it until it worked again.
Guarded Dependent Type Theory (GDTT) has dimensions (called clocks), fby/sby (called later), clock quantification (to introduce new dimensions), and dimension analysis built into the type system in the form of "clocked universes" (type universes which depend on clocks). The latter is required for the semantics to make sense, but it also allows an implementation without implicit caching. In particular, GDTT does not have an analogue of first for all types, but only for those types which don't themselves depend on the clock parameter and this requires clock dependence to be tracked in the type system.
Maybe not so interesting for stream processing as is, but it could probably be extended along those lines...
cited from the book linked by yvdriess
Where did I see that before, octave (ie matlab perhaps), erlang/elixir? I think I remember trying to limit an implicit loop by giving a scalar or an array of one element and not getting anything back because the loop was infinite.
The authors later refined the idea with Multidimensional Lucid, which replaces a slew of special forms (e.g. next, fby) and better deals with complex nested iterations, essentially by introducing a eval-at-context operator (context being a vector of dimension values). The Multidimensional Programming (https://books.google.be/books/about/Multidimensional_Program...) book starts with the example of transposing a matrix without touching its values.
Here's the Lucid wikipedia page: https://en.wikipedia.org/wiki/Lucid_(programming_language)
The relatively ancient pLucid implementation can be found here: https://code.google.com/archive/p/plucid/
The original book's PDF can be found on various sites, such as Bret Victor's http://worrydream.com/refs/Wadge%20-%20Lucid,%20the%20Datafl...