I'm not sure that they are. You just need to model the concept of state as the function's input/output, as functional programmers are eager to do :)
If we start in state x, then apply operation f, the resulting state is f(x). If we apply operation f again, we'll be in state f(f(x)). If f is idempotent, then state f(x) and state f(f(x)) are identical.