A LaTeX style file for typesetting logic puzzles

User Tools

Site Tools



This shows you the differences between two versions of the page.

Link to this comparison view

sunandmoon [2015/09/06 09:52] (current)
Line 1: Line 1:
 +Sun and Moon
 +The environment enables the user to typeset 'Sun and Moon' logic puzzles
 +(aka Sternenhaufen,​ Munraito, ...)  ​
 +Enter exactly one star and one dark cloud in each row and each column of the grid, so that the planets are illuminated as specified. The stars shine horizontally or vertically arbitrarily far, but not through a planet or a dark cloud.
 +![sun and moon puzzle](http://​i.imgur.com/​xK3yPXf.png)
 +    \begin{center}
 +      \begin{sunandmoon}
 +        \framepuzzle
 +        \setrow{5}{{},​{},​{},​{},​\Moon}
 +        \setrow{4}{{},​{},​\MoonTL}
 +        \setrow{3}{\Moon}
 +        \setrow{2}{{},​\MoonR}
 +        \setrow{1}{{},​{},​{},​\MoonT}
 +      \end{sunandmoon}
 +      \hspace{1.5cm}
 +      \begin{sunandmoon}
 +        \framepuzzle
 +        \setrow{5}{{},​{},​\Star,​\Cloud,​\Moon}
 +        \setrow{4}{{},​\Star,​\MoonTL,​{},​\Cloud}
 +        \setrow{3}{\Moon,​\Cloud,​{},​{},​\Star}
 +        \setrow{2}{\Cloud,​\MoonR,​{},​\Star}
 +        \setrow{1}{\Star,​{},​\Cloud,​\MoonT}
 +      \end{sunandmoon}
 +    \end{center}
sunandmoon.txt ยท Last modified: 2015/09/06 09:52 (external edit)