Apologies because:

- I’m fairly new to Tidal/Haskell/functional programming
- I’m not sure if this is the right place to post

But I’m interested in working with iterative functions (things like cellular automata, markov chains and so on). I can do this easily enough in Haskell with a recursive function, but I’m not sure how to best make this playable in Tidal. I can write a simple function that, for example, takes a gain pattern as input and returns a different pattern - but is there a way to get that outputted pattern to act as the input for the next repetition (and so on ad infinitum)? I’m struggling here because intuitively I keep wanting to use something mutable to keep state.

I’m sure that there must be multiple ways of doing this - it would be really helpful to hear a few ideas.

Thanks