dark
Thedark
filter takes a single set filter as argument. It has as value the set of dark squares that are in the set of squares represented by its argument.
Thus, to find positions with more than one dark-squared white bishop, use
dark ♗>1
The set of dark squares (dark ▦
)
can be computed directly via:
diagonal 0 7 diagonal 0 7 a1
Examples
Thedark
filter is used in chameleon.cql. When run on sample database, it matches the following study from John Nunn with two thematic positions:
(found from CQL file: chameleon.cql)
and
Note that these positions differ in that the pieces have all been rigidly shifted and stand on different colored squares. A typical filter in from chameleon.cql is:
light ♔ and source:dark ♔
which matches a position in which the white King is on a light square in the current position and a black square in the position represented by the position variable named source
.