logicpuzzle

A LaTeX style file for typesetting logic puzzles

User Tools

Site Tools


magiclabyrinth

Differences

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

Link to this comparison view

magiclabyrinth [2015/09/06 09:51] (current)
Line 1: Line 1:
 +<​markdown>​
 +Magic Labyrinth
 +===============
  
 +The environment enables the user to typeset Magic Labyrinth logic puzzles
 +(aka Magic Spiral, Magisches Labyrinth, ...)  ​
 +Enter the numbers 1 to N into the grid. Each number can appear only once in each column and row. Following the labyrinth from the outside inwards, then the given number sequence must be repeated continuously.
 +
 +![magiclabyrinth puzzle](http://​i.imgur.com/​eU4YmuU.png)
 +
 +    \begin{magiclabyrinth}
 +      \mlline{\xtikzpath{1}{6}{6/​5,​2/​5,​4/​5,​8/​4,​6/​4,​2/​3,​4/​3,​8/​2,​6/​2,​2/​1,​4/​1}}
 +      \setcells{1/​1,​2/​4,​4/​5}{3}
 +      \magiclabyrinthcell{4}{2}{2}
 +      \magiclabyrinthcell{5}{4}{1}
 +    \end{magiclabyrinth}
 +    \hspace{1.5cm}
 +    \begin{magiclabyrinth}
 +      \mlline{\xtikzpath{1}{6}{6/​5,​2/​5,​4/​5,​8/​4,​6/​4,​2/​3,​4/​3,​8/​2,​6/​2,​2/​1,​4/​1}}
 +      \setrow{5}{{},​1,​2,​3}
 +      \setrow{4}{2,​3,​{},​{},​1}
 +      \setrow{3}{{},​{},​3,​1,​2}
 +      \setrow{2}{1,​{},​{},​2,​3}
 +      \setrow{1}{3,​2,​1}
 +    \end{magiclabyrinth}
 +</​markdown>​
magiclabyrinth.txt ยท Last modified: 2015/09/06 09:51 (external edit)