Tuples
Haskell commentary on the implementation of Tractable and Practicable Inducers/Haskell Implementation/Tuples
See section ‘Substrate models computation’ P635. For convenience, define the sets of partition variables in the next layer $\mathrm{tuples} \in \mathrm{P}(\mathcal{V}_U) \times \mathcal{F}_{U,\mathrm{P}^{ * } } \to \mathrm{P}(\mathrm{P}(\mathcal{V}_{U}))$ as (Text)
\[
\mathrm{tuples}(V,F) := \{K : K \subseteq \mathrm{vars}(F) \cup V,~(\mathrm{der}(F) \neq \emptyset \implies K \cap \mathrm{der}(F) \neq \emptyset)\}
\]
The tuples function is defined in module Alignment
,
setVariablesFudsSetTuple :: Set.Set Variable -> Fud -> Set.Set (Set.Set Variable)
as
setVariablesFudsSetTuple vv ff =
llqq [kk | kk <- powerll (fvars ff `union` vv), (fder ff == empty) || (kk `cap` fder ff /= empty)]
...
For example,
rp $ setVariablesFudsSetTuple (vars (regcart 1 2)) fudEmpty
"{ {},{1},{1,2},{2} }"
rp $ setVariablesFudsSetTuple (vars (regcart 1 3)) fudEmpty
"{ {},{1},{1,2},{1,2,3},{1,3},{2},{2,3},{3} }"