BooleanCountingFunction¶
Represents the Boolean function of n variables that is True when the number
of True arguments is one the specification names: k for at most k, {k}
for exactly k, {kmin, kmax} for a range, and {{k1, k2, …}} for a set of
counts.
Applied to Boolean arguments it answers directly:
A count past the number of variables simply never matches:
Given a list of variables it writes out the expression instead, and a third argument names the form:
$ wo 'BooleanCountingFunction[{{2}}, {a, b, c}]'
(a && b && !c) || (a && !b && c) || ( !a && b && c)
An invalid specification is reported: