# mcrl2/utilities/sequence.h¶

Include file:

#include "mcrl2/utilities/sequence.h"


Functions for sequences.

## Functions¶

void mcrl2::utilities::foreach_sequence(const SequenceContainer &X, OutIter i, SequenceFunction f, Assign assign)

Algorithm for generating sequences. Given a sequence [X1, …, Xn], where each element Xi is a sequence as well, this function generates all sequences [x1, …, xn], where xi is an element of Xi for all i = 1 … n. For each of these sequences the function f is called. The assign parameter gives the user control over how each sequence is built.

Parameters:

• X A sequence.

• i An output iterator to where the generated sequences are written.

• f A function that is called for each generated sequence.

• assign The assign operation is called to assign values to the generated sequence.

void mcrl2::utilities::foreach_sequence(const SequenceContainer &X, OutIter i, SequenceFunction f)

Algorithm for generating sequences. Given a sequence [X1, …, Xn], where each element Xi is a sequence as well, this function generates all sequences [x1, …, xn], where xi is an element of Xi for all i = 1 … n. For each of these sequences the function f is called.

Parameters:

• X A sequence.

• i An output iterator to where the generated sequences are written.

• f A function that is called for each generated sequence.