Debian Codegraph @

texmf-dist/doc/latex/tilings/tilings.tex

raw
1 %\immediate\write18{tex tilings_code.dtx}
2 \documentclass{ltxdoc}
3 \usepackage[T1]{fontenc}
4 \usepackage{trace}
5 \usepackage{lmodern}
6 \usepackage{morefloats}
7 \usepackage{multicol}
8 \usepackage[svgnames]{xcolor}
9 \usepackage{tikz}
10 \usetikzlibrary{
11 external,
12 tilings.polykite,
13 tilings.penrose
14 }
15
16 \usepackage[numbered]{hypdoc}
17 \definecolor{lstbgcolor}{rgb}{0.9,0.9,0.9}
18
19 \usepackage{listings}
20 \lstloadlanguages{[LaTeX]TeX}
21 \lstset{
22 breakatwhitespace=true,
23 breaklines=true,
24 language=[LaTeX]TeX,
25 basicstyle=\small\ttfamily,
26 keepspaces=true,
27 columns=fullflexible
28 }
29
30 \usepackage{fancyvrb}
31
32 \newenvironment{example}
33 {\VerbatimEnvironment
34 \begin{VerbatimOut}{example.out}}
35 {\end{VerbatimOut}
36 \begin{center}
37 \setlength{\parindent}{0pt}
38 \fbox{\begin{minipage}{.9\linewidth}
39 \lstinputlisting[]{example.out}
40 \end{minipage}}
41
42 \fbox{\begin{minipage}{.9\linewidth}
43 \centering
44 \input{example.out}
45 \end{minipage}}
46 \end{center}
47 }
48
49 \newenvironment{justexample}
50 {\VerbatimEnvironment
51 \begin{VerbatimOut}{example.out}}
52 {\end{VerbatimOut}
53 \begin{center}
54 \setlength{\parindent}{0pt}
55 \fbox{\begin{minipage}{.9\linewidth}
56 \lstinputlisting[]{example.out}
57 \end{minipage}}
58 \end{center}
59 }
60
61 \colorlet{thinRhombus}{DarkOrchid}
62 \colorlet{thickRhombus}{DarkSlateGray}
63 \colorlet{circleArc}{RosyBrown}
64 \colorlet{longArc}{LawnGreen}
65
66 \colorlet{kite}{HotPink}
67 \colorlet{dart}{Fuchsia}
68
69 \colorlet{goldenTriangle}{Gold}
70 \colorlet{reverseGoldenTriangle}{Magenta}
71 \colorlet{goldenGnomon}{Cyan}
72 \colorlet{reverseGoldenGnomon}{LimeGreen}
73
74 \makeatletter
75 \tikzset{
76 tint fill colour/.code={%
77 \edef\@temp{%
78 \def\noexpand\tikz@fillcolor{\tikz@fillcolor!#1}%
79 \noexpand\tikz@addoption{\noexpand\pgfsetfillcolor{\tikz@fillcolor!#1}}%
80 }%
81 \@temp
82 }
83 }
84 \makeatother
85
86 \tikzexternalize
87 \tikzsetexternalprefix{tiling-doc-}
88
89 \providecommand*{\url}{\texttt}
90 \GetFileInfo{tikzlibrarytilings.code.tex}
91
92 \title{The \textsf{Tilings} Package: Documentation}
93 \author{Andrew Stacey\texorpdfstring{\\ \url{[email protected]}}{}}
94 \date{\fileversion~from \filedate}
95
96 \begin{document}
97
98 \maketitle
99
100 \tableofcontents
101
102 \section{Introduction}
103
104 The \textsf{Tilings} package is a TikZ library for drawing tiles and tilings, such as Penrose tilings (indeed, it was originally called the \textbf{Penrose} package).
105 It currently supports natively the various Penrose tile sets -- kite/dart, rhombus, and pentagon -- and the aperiodical polykites, but has provision for defining new tiles.
106 There are two main methods for their placement: one that automatically generates a tiling, and one that allows for ``by hand'' placement.
107 Furthermore, the tiles themselves can be deformed and will still (hopefully!) fit together in the correct fashion.
108
109 \section{Initialisation}
110
111 This is actually several libraries.
112 There is a core library called \Verb+tilings+ which defines the main functionality for working with tiles and tilings but which doesn't define any tiles itself.
113 For that, there are currently two sublibraries:
114 %
115 \begin{itemize}
116 \item \Verb+tilings.penrose+ for Penrose tiles,
117 \item \Verb+tilings.polykite+ for the aperiodical polykite tiles.
118 \end{itemize}
119 %
120 The sublibraries automatically load the core library.
121
122 So to use this package, load the \Verb+tikz+ package and load one of the tilings libraries as a TikZ library.
123 Specifically, your preamble should contain:
124
125 \begin{verbatim}
126 \usepackage{tikz}
127 \end{verbatim}
128
129 \noindent and at least one of the following lines:
130
131 \begin{verbatim}
132 \usetikzlibrary{tilings}
133 \usetikzlibrary{tilings.penrose}
134 \usetikzlibrary{tilings.polykite}
135 \end{verbatim}
136
137 The original version of this package concerned itself only with Penrose tiles so was named \Verb+penrose+.
138 Since then it has been extended and is more general and so has been renamed \Verb+tilings+.
139 Some commands have been renamed, but there is a wrapper library which aims to provide backwards compatibility with the original naming scheme.
140 This is now the \Verb+penrose+ TikZ library, meaning that old documents that use the \Verb+penrose+ TikZ library should still work (please report any that don't on the \href{https://github.com/loopspace/penrose}{issue tracker}).
141 New documents shouldn't be written using it.
142
143
144 \section{Defining the Tiles}
145
146 This package includes the capability to define new tiles.
147 The command to do this is:
148 %
149 \begin{verbatim}
150 \DefineTile{<name>}{<sides>}{<vertices>}
151 \end{verbatim}
152 %
153 For example,
154 %
155 \begin{verbatim}
156 \DefineTile {square}{a A a A}
157 {
158 {0,0}
159 {1,0}
160 {1,1}
161 {0,1}
162 }
163 \end{verbatim}
164
165 The \Verb!<sides>! is a list of letters representing sides for matching rules and positioning.
166 The first letter in the list corresponds to the edge between the first two vertices, through to the last side which corresponds to the edge between the last and first vertices.
167
168 Each letter used matches against its opposite case (so it is possible to create a side that matches against itself by using a symbol that \TeX\ regards as having the same upper as lower case; not all symbols work, I've used numbers and \Verb+!+ successfully).
169 These are also used in path replacing, both a letter and its opposite case are replaced by the corresponding path (but in opposite directions) when the tile is ``baked''.
170
171 The vertices can be written in cartesian form: \Verb+{<x>,<y>}+, or in polar: \Verb+{<angle>:<length>}+ (with the angle in degrees).
172 The vertex can be preceded by upto two \Verb!+! signs which have the same interpretation as in TikZ: the vertex description is taken relative to the previously saved point with a single \Verb!+! additionally not updating the last saved point.
173 The initial saved point is the origin, so the following defines a hexagonal tile.
174 %
175 \begin{verbatim}
176 \DefineTile {hexagon}{a A a A a A}
177 {
178 +{0:1}
179 +{60:1}
180 +{120:1}
181 +{180:1}
182 +{240:1}
183 +{300:1}
184 }
185 \end{verbatim}
186
187 The numbers are passed to the \Verb!fp! module of \LaTeX3 so can involve complicated expressions.
188 Note that the trigonometric functions for angles in degrees are \Verb!cosd!, \Verb!sind!, and \Verb!tand!.
189
190 The tile must be baked via the command \Verb!\BakeTile! before it can be used.
191
192 \begin{example}
193 \DefineTile {square}{a A a A}
194 {
195 {0,0}
196 {1,0}
197 {1,1}
198 {0,1}
199 }
200
201 \begin{tikzpicture}
202 \path[save tiling path=a] (0,0) to[out=45,in=135] (1,0);
203 \BakeTile{square}
204 \pic[square,name=A,fill=green];
205 \pic[square,align with=A along a1 using 2,name=B,fill=red];
206 \pic[square,align with=A along A1 using 2,fill=red];
207 \pic[square,align with=A along A2 using 1,fill=red];
208 \pic[square,align with=B along a1 using 2,fill=green];
209 \pic[square,align with=B along a2 using 1,fill=green];
210 \end{tikzpicture}
211 \end{example}
212
213 \subsection{Predefined Tiles: Penrose}
214
215 The sublibrary \Verb+tilings.penrose+ defines a slew of tiles based on Penrose tilings.
216
217 \tikzset{
218 every tile pic/.style={draw,ultra thick},
219 every circle arc/.style={draw,thin},
220 every long arc/.style={draw,thin},
221 }
222
223 \begin{itemize}
224 \item kite \tikz[baseline=-.5ex] \pic[draw,kite];
225 \item dart \tikz[baseline=-.5ex] \pic[draw,dart];
226 \item thin rhombus \tikz[baseline=-.5ex] \pic[draw,thin rhombus];
227 \item thick rhombus \tikz[baseline=-.5ex] \pic[draw,thick rhombus];
228 \item pentagon \(2\), \(3\), and \(5\) \tikz[baseline=-.5ex] \pic[draw, pentagon 5];
229 The number signifies how many pentagons it goes next to.
230 \item pentagram \tikz[baseline=-.5ex] \pic[draw, pentagram];
231 \item boat \tikz[baseline=-.5ex] \pic[draw, boat];
232 \item diamond \tikz[baseline=-.5ex] \pic[draw, diamond];
233 \item golden triangle \tikz[baseline=-.5ex] \pic[draw,golden triangle];
234 \item reverse golden triangle \tikz[baseline=-.5ex] \pic[draw,reverse golden triangle];
235 \item golden gnomon \tikz[baseline=-.5ex] \pic[draw,golden gnomon];
236 \item reverse golden gnomon \tikz[baseline=-.5ex] \pic[draw,reverse golden gnomon];
237 \end{itemize}
238
239 The main tiles can have arcs drawn on them to illustrate the matching rules.
240 The triangles and gnomon are not true Penrose tiles but rather can be used to build tilings so they do not have the arcs.
241 The two types of each triangle and gnomon are actually different in that they have different matching rules.
242 This is best illustrated by deforming the paths (see Section~\ref{sec:pathdeform}).
243
244 The edge labelling is as follows.
245 For the \Verb+pentagon 5+, for example, the edges are all the same and the numbers are used to distinguish between them.
246
247 \begin{multicols}{2}
248
249 \foreach \tile/\edges in {
250 kite/{a,A,c,C},
251 dart/{a,A,c,C},
252 thin rhombus/{a,A,b,B},
253 thick rhombus/{a,A,b,B},
254 pentagon 5/{a1,a2,a3,a4,a5},
255 pentagon 3/{A,b1,a1,a2,b2},
256 pentagon 2/{d,A1,e,c,A2},
257 pentagram/{C1,E1,C2,E2,C3,E3,C4,E4,C5,E5},
258 boat/{C1,E1,C2,E2,B1,D,B2},
259 diamond/{D1,B1,B2,D2},
260 golden triangle/{a,b,c},
261 reverse golden triangle/{A,B,C},
262 golden gnomon/{A,b,C},
263 reverse golden gnomon/{a,B,c}} {
264
265 \begin{tikzpicture}
266 \pic[draw,\tile,name=tile];
267 \foreach \e in \edges {
268 \path (tile-edge \e\space start) -- node[fill=white,fill opacity=.5,text opacity=1] {\e} (tile-edge \e\space end);
269 }
270 \end{tikzpicture}
271
272 }
273
274 \end{multicols}
275
276 \subsection{Predefined Tiles: Polykite}
277
278 The sublibrary \Verb+tilings.polykite+ defines a slew of tiles based on the aperiodical polykite tilings as described in \href{https://arxiv.org/abs/2303.10798}{An Aperiodic Monotile} and \href{https://arxiv.org/abs/2305.17743}{A Chiral Aperiodic Monotile}.
279 It also defines a wrapper around the \Verb+\DefineTile+ command for creating one of the family of polykite tiles described in that article:
280
281 \begin{verbatim}
282 \DefinePolykiteTile{<name>}{<a>}{<b>}
283 \DefinePolykiteTile*{<name>}{<a>}{<b>}
284 \DefinePolykiteTile{aperiodical hat}{sqrt(3)/2}{1/2}
285 \end{verbatim}
286
287 The polykite tiles have two types of edge corresponding to the two lengths.
288 The starred option swaps the labels on these edges so that, for example, the hat and turtle tiles can be used in the same diagram.
289 Predefined polykite tiles are the \texttt{aperiodical hat}, \texttt{aperiodical turtle}, \texttt{spectral hat}, and \texttt{spectral turtle}.
290 The aperiodical versions can be swapped in for each other as they have the same edge labelling but the spectral versions have the opposite.
291 (In actual fact, the aperiodical and spectral hats are the same.)
292
293 The equilateral polykite tile also exists as a \texttt{spectre} with alternating edge matching, as in the second paper \href{https://arxiv.org/abs/2305.17743}{A Chiral Aperiodic Monotile}.
294
295 \begin{itemize}
296 \item Aperiodical Hat \tikz[baseline=-.5ex] \pic[draw,aperiodical hat];
297 \item Aperiodical Turtle \tikz[baseline=-.5ex] \pic[draw,aperiodical turtle];
298 \item Spectral Hat \tikz[baseline=-.5ex] \pic[draw,spectral hat];
299 \item Spectral Turtle \tikz[baseline=-.5ex] \pic[draw,spectral turtle];
300 \item Spectre \tikz[baseline=-.5ex] \pic[draw,spectre];
301 \item Meta Cluster H \tikz[baseline=-.5ex] \pic[scale=.5,draw,meta cluster H];
302 \item Meta Cluster F \tikz[baseline=-.5ex] \pic[scale=.5,draw,meta cluster F];
303 \item Meta Cluster T \tikz[baseline=-.5ex] \pic[scale=.5,draw,meta cluster T];
304 \item Meta Cluster P \tikz[baseline=-.5ex] \pic[scale=.5,draw,meta cluster P];
305 \item Super Cluster H \tikz[baseline=-.5ex] \pic[scale=.3,draw,super cluster H];
306 \item Super Cluster F \tikz[baseline=-.5ex] \pic[scale=.3,draw,super cluster F];
307 \item Super Cluster T \tikz[baseline=-.5ex] \pic[scale=.3,draw,super cluster T];
308 \item Super Cluster P \tikz[baseline=-.5ex] \pic[scale=.3,draw,super cluster P];
309 \item Subcluster H \tikz[baseline=-.5ex] \pic[scale=.5,draw,subcluster H];
310 \item Subcluster F \tikz[baseline=-.5ex] \pic[scale=.5,draw,subcluster F];
311 \item Subcluster T \tikz[baseline=-.5ex] \pic[scale=.5,draw,subcluster T];
312 \item Subcluster P \tikz[baseline=-.5ex] \pic[scale=.5,draw,subcluster P];
313 \end{itemize}
314
315 The edges of the meta and super cluster tiles are actually multi-edges for the matching rules.
316
317 The subcluster tiles are a bit different to the others.
318 The \(H\) and \(T\) tiles are actually equilateral triangles but they have edge deformations applied by default so that they have the appearance of the aperiodical hat tile.
319 The \(P\) and \(F\) tiles have no area (so are not clipped by default) which means that the edge labels aren't fully clear as to which side they are on.
320 They match the diagrams given in the \href{https://arxiv.org/abs/2303.10798}{paper}, with the \(L\) sides being the sides labelled \(11\) and \(12\).
321
322 \begin{multicols}{2}
323
324 \tikzset{
325 every super cluster scope/.style={
326 scale=.3
327 },
328 every super cluster T scope/.style={every super cluster scope},
329 every super cluster P scope/.style={every super cluster scope},
330 every super cluster F scope/.style={every super cluster scope},
331 every super cluster H scope/.style={every super cluster scope},
332 every meta cluster scope/.style={
333 scale=.7
334 },
335 every meta cluster T scope/.style={every meta cluster scope},
336 every meta cluster P scope/.style={every meta cluster scope},
337 every meta cluster F scope/.style={every meta cluster scope},
338 every meta cluster H scope/.style={every meta cluster scope},
339 }
340
341 \foreach \tile/\edges in {
342 aperiodical hat/{11,21,22,23,24,12,13,25,26,14,15,27,28,16},
343 aperiodical turtle/{11,21,22,23,24,12,13,25,26,14,15,27,28,16},
344 spectral hat/{11,21,22,23,24,12,13,25,26,14,15,27,28,16},
345 spectral turtle/{11,21,22,23,24,12,13,25,26,14,15,17,18,16},
346 spectre/{a1,a2,a3,a4,a5,a6,a7,A1,A2,A3,A4,A5,A6,A7},
347 meta cluster T/{A1,A2,b},
348 meta cluster P/{A, 11, D1, d1, b, 12, D2, d2},
349 meta cluster F/{11, D1, c, C, d1, b, 12, D2, d2},
350 meta cluster H/{a, D1, d1, B1, D2, d2, B2, D3, d3},
351 super cluster T/{A1,A2,b},
352 super cluster P/{A, 11, D1, d1, b, 12, D2, d2},
353 super cluster F/{11, D1, c, C, d1, b, 12, D2, d2},
354 super cluster H/{a, D1, d1, B1, D2, d2, B2, D3, d3},
355 subcluster T/{A1,A2,b},
356 subcluster H/{B1,B2,a},
357 subcluster P/{11, A, 12, b},
358 subcluster F/{11, 12, F, f, b}%
359 }{
360 \begin{tikzpicture}
361 \pic[draw,\tile,name=tile];
362 \foreach \e in \edges {
363 \path (tile-edge \e\space start) -- node[fill=white,fill opacity=.5,text opacity=1] {\e} (tile-edge \e\space end);
364 }
365 \end{tikzpicture}
366
367 }
368
369 \end{multicols}
370
371
372 \section{Using the Tiles}
373
374 \subsection{Positioning}
375
376 The main way to use the tiles is via the \Verb+pic+ syntax that was introduced in TikZ3.0.
377 These are mini-drawings that are node-like in style, but a little more geared towards repeatable \emph{drawings} than boxes containing text.
378
379 There are two ways in TikZ to specify the \Verb+pic+ type: either as the ``contents'' of the pic or as the argument to the \Verb+pic type+ key.
380 Each of the tiles comes with a shorthand key which specifies the \Verb+pic type+ and also invokes the keys \Verb+every tile pic+ and \Verb+every <tile type> pic+.
381 That is, the key \Verb+dart+ calls the \Verb+every tile pic+ and \Verb+every dart pic+ keys and specifies the \Verb+pic type+ as \Verb+dart+.
382
383 The tiles can be placed using standard TikZ methods.
384 One important thing to note is that by default, \Verb+pic+s are like \Verb+nodes+ in that they only respond to ambient translations, and not to rotations and scaling.
385 To make them notice this, use the key \Verb+transform shape+ or specify the transformation to the \Verb+pic+ directly.
386 If the shortcut keys are used to specify the tiles, this can be put in the \Verb+every tile pic+ style.
387
388 TikZ \Verb+pic+s can be named, using the \Verb+name=<name>+ key or using the \Verb+(name)+ syntax (see the TikZ documentation for more details).
389 When a tile has been named then it can be used for positioning other tiles.
390 Each edge is assigned a label and a new tile can be aligned with an old one along a matching edge (\Verb+a+ matches with \Verb+A+ and so on).
391
392 To align a tile with an existing one, use the following key:
393 %
394 \begin{verbatim}
395 align with=<tile> along <edge>
396 \end{verbatim}
397 %
398 where \Verb+<tile>+ is the name given to an existing tile, and \Verb+<edge>+ is the label on the existing tile.
399 If the tile being placed has edges that are identical (for example, \Verb+pentagon 5+), this syntax extends to
400 %
401 \begin{verbatim}
402 align with=<tile> along <edge> using <number>
403 \end{verbatim}
404 %
405 to specify which of the edges on the new tile to use.
406
407 Lastly, it is possible to reflect a tile either in use or in definition in which case the edges might be backwards so the key can be modified with the word \Verb+back+ as in:
408 %
409 \begin{verbatim}
410 align with=<tile> back along <edge>
411 \end{verbatim}
412 %
413 and similarly with \Verb+using ...+.
414
415 A similar key can be used to place the tile so that an edge starts and ends at specified coordinates:
416 %
417 \begin{verbatim}
418 align between=<coordinate> and <coordinate> using <edge>
419 \end{verbatim}
420 %
421 Here, the \Verb+edge+ has to be specified in full since the start and end coordinates don't contain the information about which edge should stretch between them.
422 To obtain the equivalent of \Verb+back along+ then simply swap the coordinates.
423
424 \begin{example}
425 \begin{tikzpicture}
426 \pic[kite,name=tile];
427 \pic[dart,align with=tile along c];
428 \pic[pentagon 5,name=ptile,at={(3,0)}];
429 \pic[pentagon 3,align with=ptile along a1];
430 \end{tikzpicture}
431 \end{example}
432
433 With judicious use of loops, quite complicated pictures can be rendered using simple code.
434 (Note that the \Verb+transform shape+ is \emph{not} needed to apply the transformations needed to place a tile using this syntax.)
435
436 \begin{example}
437 \begin{tikzpicture}[
438 every rhombus/.style={
439 draw=black,
440 ultra thick,
441 },
442 every thin rhombus/.style={
443 every rhombus/.try,
444 fill=thinRhombus,
445 },
446 every thick rhombus/.style={
447 every rhombus/.try,
448 fill=thickRhombus,
449 },
450 every circle arc/.style={
451 draw=circleArc
452 },
453 every long arc/.style={
454 draw=longArc
455 }
456 ]
457 \pic[rotate=18,thick rhombus,name=a0];
458 \foreach[evaluate=\k as \kmo using int(\k-1)] \k in {1,...,4}
459 {
460 \pic[thick rhombus,name=a\k,align with={a\kmo} along A];
461 }
462 \foreach \k in {0,...,4}
463 {
464 \pic[thin rhombus,name=b\k,align with={a\k} along B];
465 \pic[thick rhombus,name=c\k,align with={b\k} along A];
466 \pic[thick rhombus,name=d\k,align with={b\k} along a];
467 \pic[thick rhombus,name=e\k,align with={c\k} along A];
468 \foreach \l/\a in {{0/b},{1/B}}
469 \pic[thin rhombus,name=f\k\l,align with={e\k} along \a];
470 }
471 \pic[thin rhombus,name=g0,align with={f10} along a];
472 \pic[thin rhombus,name=g1,align with={f21} along A];
473 \foreach \l/\a in {{0/a},{1/A}}
474 \pic[thick rhombus,name=h\l,align with={g\l} along \a];
475 \pic[thick rhombus,name=i,align with=g0 along B];
476 \foreach \l/\a in {{0/a},{1/A}}
477 \pic[thick rhombus,name=j\l,align with=i along \a];
478 \end{tikzpicture}
479 \end{example}
480
481 \subsection{Styling}
482
483 The tiles can be styled, either directly or using various keys.
484 When a tile is placed then there are various actions that happen with associated keys.
485 The actions and keys are:
486 %
487 \begin{enumerate}
488 \item A scope is started and the following keys are tried.
489 %
490 \begin{enumerate}
491 \item \Verb+every tile scope+
492 \item \Verb+every <name> scope+ where \Verb+name+ is the tile name (not the pic name)
493 \item \Verb+this tile scope+
494 \end{enumerate}
495
496 \item The tile path is used with the intention of it being a clipping path.
497 The keys for this action are:
498 %
499 \begin{enumerate}
500 \item \Verb+every tile clip+ by default this is set to \Verb+clip+
501 \item \Verb+every <name> clip+
502 \item \Verb+this tile clip+
503 \end{enumerate}
504
505 \item A set of keys are used to allow arbitrary code to be executed before the tile path is rendered.
506 These are:
507
508 \begin{enumerate}
509 \item \Verb+every tile before path+
510 \item \Verb+every <name> before path+
511 \item \Verb+this tile before path+
512 \end{enumerate}
513
514 \item The tile path is rendered.
515 The keys for this action are:
516 %
517 \begin{enumerate}
518 \item \Verb+every tile+
519 \item \Verb+every <name>+
520 \item \Verb+this tile+
521 \item \Verb+pic actions+
522 \end{enumerate}
523
524 \item A set of keys are used to allow arbitrary code to be executed after the tile path is rendered.
525 These are:
526
527 \begin{enumerate}
528 \item \Verb+every tile after path+
529 \item \Verb+every <name> after path+
530 \item \Verb+this tile after path+
531 \end{enumerate}
532 \end{enumerate}
533
534
535 The \Verb+pic actions+ are any actions given directly to the tile, as in \Verb+\pic[draw,thin rhombus];+.
536 The kite, dart, and rhombus tiles also have arcs drawn on them which are inserted via the \Verb+every <name> after path+ keys, and these are themselves styled ussing \Verb+every circle arc+ and \Verb+every long arc+.
537 The names come from the way the arcs look on the rhombus shapes.
538
539 One other point is important to note about the tiles.
540 They are actually clipped against themselves.
541 This ensures that the tiles do not overstep their bounds and so when placed alongside each other then they do not go over each other.
542 In practical terms, this means that if drawn then the line width is half that which might be expected (but when placed next to another tile, the two halves combine to the expected width).
543
544 \subsection{Placing Tiles Automatically}
545
546 There is a way to specify certain tilings using \emph{Lindenmayer systems}.
547 In brief, this takes a seed pattern and successively applies \emph{substitution rules} which are meant to simulate replacing a tile by smaller versions of it (and others from the same set).
548 This is implemented for the Penrose tiles and the various clusters related to the aperiodical polykite tile.
549
550 The Penrose rules are \emph{positional} in that when replacing a Penrose tile by smaller versions of it the new tiles can be placed solely based on information about the position and orientation of the original tile.
551 This is true also for the \emph{super cluster} tiles of the aperiodical polykite, but not for the meta cluster or subclusters.
552
553 The meta and subclusters work on a different system.
554 The structure that is built up is that of a \emph{tree} with a root tile.
555 That root tile is positioned, and then the other tiles are placed next to previously placed tiles.
556 This is a slower process and can mean that the overall shape is different to what might be expected, but from the user's perspective it is the same.
557
558 The user command is one of:
559 %
560 \begin{verbatim}
561 \TilingDecomposition{<type>}{<level>}{<seed>}
562 \pic{decomposition={<type>}{<level>}{<seed>}};
563 \end{verbatim}
564 %
565 where \Verb+<type>+ is one of:
566 %
567 \begin{itemize}
568 \item \Verb+kite+ for the kite and dart tiling,
569 \item \Verb+rhombus+ for the rhombus tiling,
570 \item \Verb+pentagon+ for the pentagon tiling.
571 \item \Verb+ktriangle+ for the triangular decomposition used to form the kite and dart tiling but with the individual triangles
572 \item \Verb+rtriangle+ for the triangular decomposition used to form the rhombus tiling but with the individual triangles.
573 \item \Verb+supercluster+ for the super cluster substitution system that works on a positional basis.
574 \item \Verb+cluster+ for the cluster substitution system that uses the neighbour information.
575 The choice of super, meta, or subcluster is determined by the value of the key \Verb!cluster type!.
576 \end{itemize}
577
578 The \Verb+<seed>+ is a ``word'' that will be used to initiate the Lindenmayer system.
579 The key letters in the alphabet for the kite/darts and rhombuses are \Verb+T+, \Verb+t+, \Verb+G+, and \Verb+g+.
580 These actually correspond to the two triangles and two gnomons.
581 For the pentagons, the key letters are \Verb+P+, \Verb+Q+, \Verb+R+, \Verb+G+, \Verb+B+, \Verb+D+.
582 These correspond to the three pentagons, the pentagram, the boat, and the diamond.
583 For the clusters, the key letters are \Verb+H+, \Verb+T+, \Verb+P+, and \Verb+F+.
584 Other permitted letters are \Verb+[+, \Verb+]+, \Verb+s+, \Verb+f+, \Verb!+!, \Verb+*+, \Verb+-+, \Verb+_+, \Verb+>+.
585 These refer to various transformations (for details, see the implementation).
586
587 The \Verb+<level>+ controls how far to take the iteration.
588 The code is not particularly optimised for speed, and once \Verb+<level>+ gets to about \(5\) or \(6\) then we are at the ``make a cup of tea while compiling'' stage, depending on the processor.
589
590 \begin{example}
591 \begin{tikzpicture}[
592 every tile/.style={draw},
593 tiling step=2cm,
594 ]
595 \TilingDecomposition{kite}{0}{T}
596 \end{tikzpicture}
597 \end{example}
598
599 The two types of substitution rules -- positional and neighbourly -- are rendered slightly differently.
600 The positional tiles are drawn directly but the neighbour ones are drawn via the \Verb!\pic! mechanism.
601 This is to exploit the existing code for aligning against existing tiles.
602 This means that the \Verb!\pic! styling options are available for the latter type of decomposition but not for the former.
603 For the former, only the following keys are used:
604
605 \begin{verbatim}
606 every tile
607 every <tile type>
608 \end{verbatim}
609
610 There are, however, some additional styles which allow styling the tiles by their number: a count is kept of the number of tiles and each tile knows its own number.
611 Specifically, two keys are tried:
612 %
613 \begin{enumerate}
614 \item \Verb+tile <number>+, and
615 \item \Verb+tile={<number>}{<total>}+
616 \end{enumerate}
617 %
618 A word of warning is in order on the second of these.
619 The \Verb+<total>+ is not guaranteed to be correct.
620 It is done by a quick count at the start of the process and counts those letters which \emph{might} result in a rendered tile.
621 Not every letter in the resulting word actually does.
622 Nevertheless, this can be used to style a tile based on what proportion of tiles have been rendered.
623
624 Lastly, \Verb+tiling step+ is used to control the size of the resulting picture.
625
626 \begin{example}
627 \begin{tikzpicture}[
628 every tile/.style={draw},
629 tiling step=4cm,
630 tile/.code 2 args={
631 \pgfmathsetmacro\tint{100*#1/#2}
632 \pgfkeysalso{fill=black!\tint}
633 }
634 ]
635 \TilingDecomposition{rhombus}{3}{T}
636 \end{tikzpicture}
637 \end{example}
638
639 Here's the super, meta, and subcluster combinatorial decompositions.
640 These decompositions also define a style \Verb!first tile! which is applied to the initial tile (that isn't placed next to an existing tile).
641
642 \begin{example}
643 \begin{tikzpicture}[
644 every tile/.style={draw},
645 first tile/.style={
646 transform shape
647 },
648 ]
649
650 \TilingDecomposition[scale=.25,cluster type=super cluster]{cluster}{1}{H}
651 \TilingDecomposition[xshift=3cm,scale=.5,cluster type=meta cluster]{cluster}{1}{H}
652 \TilingDecomposition[xshift=5cm,cluster type=subcluster]{cluster}{1}{H}
653 \end{tikzpicture}
654 \end{example}
655
656 Here is a subcluster decomposition showing just the \(F_0\) and \(P_0\) tiles.
657
658 \begin{example}
659 \begin{tikzpicture}[
660 every tile/.style={},
661 every tile pic/.style={},
662 every subcluster F/.style={draw=magenta, ultra thin},
663 every subcluster P/.style={draw=magenta, ultra thin},
664 ]
665 \pic[
666 first tile/.style={transform shape},
667 cluster type=subcluster,
668 scale=3
669 ] {decomposition={cluster}{3}{H}};
670 \end{tikzpicture}
671 \end{example}
672
673
674 \section{Deforming Paths}
675 \label{sec:pathdeform}
676
677 This package provides the ability to deform the edges of the tiles.
678 The tiles are built from labelled paths together with their reverses.
679 By changing these paths, one can get a wide variety of different tiles with the same fundamental matching rules.
680 Indeed, by using asymmetric paths, the matching rules can be enforced without the need for additional decoration.
681
682 Internally, the \Verb+tiling+ library uses the \Verb+spath3+ package for storing and manipulating the paths.
683
684 To create a new edge path, use the key \Verb+save tiling path=<edge>+ where \Verb+<edge>+ is a symbol used in the edge description of a tile.
685 There are no constraints on the size of the path as all paths are scaled and transformed to fit the tiles.
686 Once the edge paths have been specified, they are welded together into the tiles using the following command:
687 %
688 \begin{verbatim}
689 \BakeTile{<name>}
690 \end{verbatim}
691 %
692 Here, \Verb+<name>+ is one of the names of the tiles.
693 This has global effect, as does the definition of the edge paths.
694 Paths, both sides and tiles, can be cloned via:
695 %
696 \begin{verbatim}
697 \tikzset{clone tiling side path={target}{source}}
698 \tikzset{clone tile path={target}{source}}
699 \end{verbatim}
700 %
701 and restored with the same command (but names switched).
702
703 \begin{example}
704 \begin{tikzpicture}
705 \pic[draw,dart,name=dart];
706 \pic[draw,kite,align with=dart along c];
707 \pic[draw,kite,align with=dart along C];
708 \tikzset{clone tile path={original kite}{kite}}
709 \tikzset{clone tile path={original dart}{dart}}
710 \path[save tiling path=a] (0,0) to[out=-30,in=100] (1,0);
711 \path[save tiling path=c] (0,0) to[out=-40,in=140] (1,0);
712 \BakeTile{kite}
713 \BakeTile{dart}
714 \pic[xshift=2cm,draw,dart,name=dart];
715 \pic[draw,kite,align with=dart along c];
716 \pic[draw,kite,align with=dart along C];
717 \tikzset{clone tile path={kite}{original kite}}
718 \tikzset{clone tile path={dart}{original dart}}
719 \pic[xshift=4cm,draw,dart,name=dart];
720 \pic[draw,kite,align with=dart along c];
721 \pic[draw,kite,align with=dart along C];
722 \end{tikzpicture}
723 \end{example}
724
725 With deformed tiles there is no guarantee that the inner arcs on the Penrose tiles will match up perfectly.
726
727 Note that the subcluster tiles from the polykite subpackage are actually already deformed tiles.
728
729 \begin{example}
730 \begin{tikzpicture}[
731 every subcluster F/.style={draw, ultra thick},
732 every subcluster P/.style={draw, thick},
733 every subcluster H/.style={draw, fill, fill opacity=.5}
734 ]
735 \pic[subcluster F, name=F1, this tile/.style={line width=1mm}];
736 \pic[subcluster F, align with=F1 along 12 using 1, name=F2, this tile/.style={line width=1mm}];
737 \pic[subcluster F, align with=F1 along 11 using 2, name=F3, this tile/.style={line width=1mm}];
738 \pic[subcluster F, align with=F1 along F,name=F1-2];
739 \pic[subcluster F, align with=F1 along f,name=F1-3];
740 \pic[subcluster F, align with=F2 along F,name=F2-2];
741 \pic[subcluster F, align with=F2 along f,name=F2-3];
742 \pic[subcluster F, align with=F3 along F,name=F3-2];
743 \pic[subcluster F, align with=F3 along f,name=F3-3];
744 \pic[subcluster H, align with=F1 along b using 2, fill=red];
745 \pic[subcluster H, align with=F2 along b using 2, fill=green];
746 \pic[subcluster H, align with=F3 along b using 2, fill=blue];
747 \pic[subcluster H, align with=F1-2 along b using 1, fill=yellow];
748 \pic[subcluster H, align with=F2-2 along b using 1, fill=cyan];
749 \pic[subcluster H, align with=F3-2 along b using 1, fill=magenta];
750 \end{tikzpicture}
751 \end{example}
752
753 \begin{example}
754 \begin{tikzpicture}[
755 every tile pic/.style={},
756 % every subcluster F/.style={draw, ultra thick},
757 % every subcluster P/.style={draw, thick},
758 every subcluster H/.style={draw, fill, fill opacity=.5}
759 ]
760 \path[save tiling path=a] (0,0) -- (1,0);
761 \path[save tiling path=b] (0,0) -- (1,0);
762 \path[save tiling path=f] (0,0) -- (1,0);
763 \BakeTile{subcluster H}
764 \BakeTile{subcluster T}
765 \BakeTile{subcluster P}
766 \BakeTile{subcluster F}
767
768 \pic[subcluster F, name=F1, this tile/.style={line width=1mm}];
769 \pic[subcluster F, align with=F1 along 12 using 1, name=F2, this tile/.style={line width=1mm}];
770 \pic[subcluster F, align with=F1 along 11 using 2, name=F3, this tile/.style={line width=1mm}];
771 \pic[subcluster F, align with=F1 along F,name=F1-2];
772 \pic[subcluster F, align with=F1 along f,name=F1-3];
773 \pic[subcluster F, align with=F2 along F,name=F2-2];
774 \pic[subcluster F, align with=F2 along f,name=F2-3];
775 \pic[subcluster F, align with=F3 along F,name=F3-2];
776 \pic[subcluster F, align with=F3 along f,name=F3-3];
777 \pic[subcluster H, align with=F1 along b using 2, fill=red];
778 \pic[subcluster H, align with=F2 along b using 2, fill=green];
779 \pic[subcluster H, align with=F3 along b using 2, fill=blue];
780 \pic[subcluster H, align with=F1-2 along b using 1, fill=yellow];
781 \pic[subcluster H, align with=F2-2 along b using 1, fill=cyan];
782 \pic[subcluster H, align with=F3-2 along b using 1, fill=magenta];
783 \end{tikzpicture}
784 \end{example}
785
786 The spectre tile, from \href{https://arxiv.org/abs/2305.17743}{A Chiral Aperiodic Monotile}, is a natural for deformation as that can be used to force aperiodicity.
787
788 \begin{example}
789 \begin{tikzpicture}[
790 every spectre/.style={
791 draw,
792 thick,
793 },
794 every tile pic/.style={scale=.5,rotate=105},
795 ]
796 \pic[spectre];
797 \path[save tiling path=a] (0,0) to[out=30,in=150] (1,0);
798 \BakeTile{spectre}
799 \pic[spectre,at={(3,0)}];
800 \path[save tiling path=a] (0,0) to[out=30,in=210] (1,0);
801 \BakeTile{spectre}
802 \pic[spectre,at={(6,0)}];
803 \path[save tiling path=a] (0,0) .. controls +(30:1) and +(210:.75) .. (1,0);
804 \BakeTile{spectre}
805 \pic[spectre,at={(9,0)}];
806 \end{tikzpicture}
807 \end{example}
808
809 \section{More Examples}
810
811 Let's set some aesthetically pleasing shapes.
812 Note that I'm using the TikZ \Verb!external! library in creating this document so to deform the paths in the examples I need to add the deformation code to every picture (otherwise the externalisation skips it).
813 I've saved it into a key \Verb!deform tiles! to avoid overwhelming the example code.
814 In a document without externalisation then adding the following code will achieve the same effect.
815
816 \begin{justexample}
817 \begin{tikzpicture}
818 \path[save tiling path=a] (0,0) to[out=-30,in=100] (1,0);
819 \path[save tiling path=b] (0,0) to[out=0,in=140] (1,0);
820 \path[save tiling path=c] (0,0) to[out=-40,in=140] (1,0);
821 \BakeTile{thin rhombus}
822 \BakeTile{thick rhombus}
823 \BakeTile{golden triangle}
824 \BakeTile{reverse golden triangle}
825 \BakeTile{golden gnomon}
826 \BakeTile{reverse golden gnomon}
827 \BakeTile{kite}
828 \BakeTile{dart}
829 \end{tikzpicture}
830 \end{justexample}
831
832 \tikzset{
833 deform tiles/.code={%
834 \path[save tiling path=a] (0,0) to[out=-30,in=100] (1,0);
835 \path[save tiling path=b] (0,0) to[out=0,in=140] (1,0);
836 \path[save tiling path=c] (0,0) to[out=-40,in=140] (1,0);
837 \BakeTile{thin rhombus}
838 \BakeTile{thick rhombus}
839 \BakeTile{golden triangle}
840 \BakeTile{reverse golden triangle}
841 \BakeTile{golden gnomon}
842 \BakeTile{reverse golden gnomon}
843 \BakeTile{kite}
844 \BakeTile{dart}
845 }
846 }
847
848 Styling the first tile.
849 Note that as the pattern is formed by repeating two different initial seeds \(5\) times, there are \(10\) ``first tiles'' in each overall pattern.
850
851 \begin{example}
852 \begin{tikzpicture}[
853 deform tiles/.try,
854 every tile/.style={draw},
855 tile 1/.style={fill=yellow},
856 ]
857 \foreach \tp/\pos in {rhombus/0cm,rtriangle/2.5cm,kite/5cm,ktriangle/7.5cm}
858 {
859 \begin{scope}[xshift=\pos]
860 \foreach[evaluate=\k as \mk using {\k+Mod(\k,2)},evaluate=\k as \ax using {Mod(\k,2) == 0 ? "T" : "t"}] \k in {0,...,9} {
861 \begin{scope}[rotate=\mk*36]
862 \TilingDecomposition{\tp}{1}{\ax}
863 \end{scope}
864 }
865 \end{scope}
866 }
867 \end{tikzpicture}
868 \end{example}
869
870
871
872 A more detailed decomposition, with more and more tinting applied to each tile.
873 Roughly half of the counted tiles are rendered, and the ordering in which they are rendered is not at first an obvious one (though it is in general from ``outside in'').
874
875 Note that the key \Verb+tint fill colour+ is not a TikZ native.
876 It is defined as:
877
878 \begin{verbatim}
879 \makeatletter
880 \tikzset{
881 tint fill colour/.code={%
882 \edef\@temp{%
883 \def\noexpand\tikz@fillcolor{\tikz@fillcolor!#1}%
884 \noexpand\tikz@addoption{%
885 \noexpand\pgfsetfillcolor{\tikz@fillcolor!#1}%
886 }%
887 }%
888 \@temp
889 }
890 }
891 \makeatother
892 \end{verbatim}
893
894 \begin{example}
895 \begin{tikzpicture}[
896 deform tiles/.try,
897 every tile/.style={draw},
898 every kite/.style={fill=reverseGoldenTriangle},
899 every dart/.style={fill=goldenTriangle},
900 tile/.code 2 args={
901 \pgfmathsetmacro\tint{100*(1 - 1.5*#1/#2))}
902 \pgfkeysalso{tint fill colour=\tint}
903 }
904 ]
905 \foreach[evaluate=\k as \mk using {\k+Mod(\k,2)},evaluate=\k as \ax using {Mod(\k,2) == 0 ? "T" : "t"}] \k in {0,...,9} {
906 \begin{scope}[rotate=\mk*36]
907 \TilingDecomposition[tiling step=5cm]{kite}{4}{\ax}
908 \end{scope}
909 }
910 \end{tikzpicture}
911 \end{example}
912
913 An example with ``manual placement''.
914
915 \begin{example}
916 \begin{tikzpicture}[
917 deform tiles/.try,
918 every tile/.style={
919 draw=black,
920 ultra thick,
921 },
922 every kite/.style={
923 fill=kite,
924 },
925 every dart/.style={
926 fill=dart,
927 },
928 every circle arc/.style={
929 draw=circleArc
930 },
931 every long arc/.style={
932 draw=longArc
933 }
934 ]
935 \pic[dart,name=a0];
936 \foreach[evaluate=\k as \kmo using int(\k-1)] \k in {1,...,4} {
937 \pic[dart,name=a\k,align with={a\kmo} along a];
938 }
939 \foreach \k in {0,...,4} {
940 \foreach \l/\e/\ee in {0/c/a,1/C/A} {
941 \pic[kite,name=b\l\k,align with={a\k} along \e];
942 \pic[dart,name=c\l\k,align with={b\l\k} along \ee];
943 \pic[kite,name=d\l\k,align with={c\l\k} along \e];
944 }
945 \pic[kite,name=e\k,align with={c0\k} along C];
946 \pic[dart,name=f\k,align with={c0\k} along a];
947 \foreach \e in {c,C} {
948 \pic[kite,name=g\k,align with={f\k} along \e];
949 }
950 }
951 \end{tikzpicture}
952 \end{example}
953
954
955 The decomposition rules for the Lindenmayer system can be illustrated by drawing each tile together with the result of one decomposition superimposed on top.
956
957 \begin{example}
958 \foreach \ax in {T,t,G,g} {
959
960 \begin{tikzpicture}[
961 deform tiles/.try,
962 ]
963 \foreach \tp/\pos in {rhombus/0cm,rtriangle/2cm,kite/4cm,ktriangle/6cm}
964 {
965 \begin{scope}[xshift=\pos]
966 \TilingDecomposition[every path/.style={draw=red,ultra thick}]{\tp}{0}{\ax}
967 \TilingDecomposition[every path/.style={fill=gray!50,fill opacity=.5,draw=black}]{\tp}{1}{\ax}
968 \end{scope}
969 }
970 \end{tikzpicture}
971
972 }
973 \end{example}
974
975 The tiles can make interesting forms by themselves.
976
977 \begin{example}
978 \begin{tikzpicture}[
979 deform tiles/.try,
980 scale=2,
981 every tile pic/.style={
982 transform shape,
983 },
984 every golden triangle/.style={
985 draw=black,
986 ultra thick,
987 fill=goldenTriangle,
988 },
989 every reverse golden triangle/.style={
990 draw=black,
991 ultra thick,
992 fill=reverseGoldenTriangle,
993 },
994 every golden gnomon/.style={
995 draw=black,
996 ultra thick,
997 fill=goldenGnomon,
998 },
999 every reverse golden gnomon/.style={
1000 draw=black,
1001 ultra thick,
1002 fill=reverseGoldenGnomon,
1003 },
1004 ]
1005 \pic[golden triangle,name=a];
1006 \pic[reverse golden triangle,align with=a along a];
1007 \pic[reverse golden triangle,align with=a along b];
1008 \pic[reverse golden triangle,align with=a along c];
1009 \begin{scope}[xshift=2cm]
1010 \pic[reverse golden triangle,name=a];
1011 \pic[golden triangle,align with=a along A];
1012 \pic[golden triangle,align with=a along B];
1013 \pic[golden triangle,align with=a along C];
1014 \end{scope}
1015 \begin{scope}[yshift=-3cm]
1016 \pic[golden gnomon,name=a];
1017 \pic[reverse golden gnomon,align with=a along C];
1018 \pic[reverse golden gnomon,align with=a along b];
1019 \pic[reverse golden gnomon,align with=a along A];
1020 \begin{scope}[xshift=2cm]
1021 \pic[reverse golden gnomon,name=a];
1022 \pic[golden gnomon,align with=a along c];
1023 \pic[golden gnomon,align with=a along B];
1024 \pic[golden gnomon,align with=a along a];
1025 \end{scope}
1026 \end{scope}
1027 \end{tikzpicture}
1028 \end{example}
1029
1030 \begin{example}
1031 \begin{tikzpicture}[
1032 deform tiles/.try,
1033 every rhombus/.style={
1034 draw=black,
1035 ultra thick,
1036 },
1037 every thin rhombus/.style={
1038 every rhombus/.try,
1039 fill=thinRhombus,
1040 },
1041 every thick rhombus/.style={
1042 every rhombus/.try,
1043 fill=thickRhombus,
1044 },
1045 every circle arc/.style={
1046 draw=circleArc
1047 },
1048 every long arc/.style={
1049 draw=longArc
1050 }
1051 ]
1052 \pic[rotate=18,thick rhombus,name=a0];
1053 \foreach[evaluate=\k as \kmo using int(\k-1)] \k in {1,...,4}
1054 {
1055 \pic[thick rhombus,name=a\k,align with={a\kmo} along A];
1056 }
1057 \foreach \k in {0,...,4}
1058 {
1059 \pic[thin rhombus,name=b\k,align with={a\k} along B];
1060 \pic[thick rhombus,name=c\k,align with={b\k} along A];
1061 \pic[thick rhombus,name=d\k,align with={b\k} along a];
1062 \pic[thick rhombus,name=e\k,align with={c\k} along A];
1063 \foreach \l/\a in {{0/b},{1/B}}
1064 \pic[thin rhombus,name=f\k\l,align with={e\k} along \a];
1065 }
1066 \pic[thin rhombus,name=g0,align with={f10} along a];
1067 \pic[thin rhombus,name=g1,align with={f21} along A];
1068 \foreach \l/\a in {{0/a},{1/A}}
1069 \pic[thick rhombus,name=h\l,align with={g\l} along \a];
1070 \pic[thick rhombus,name=i,align with=g0 along B];
1071 \foreach \l/\a in {{0/a},{1/A}}
1072 \pic[thick rhombus,name=j\l,align with=i along \a];
1073 \end{tikzpicture}
1074 \end{example}
1075
1076 Lastly, here's an example that generates full page patterns.
1077
1078 \begin{justexample}
1079 \foreach \tp/\lvl in {rhombus/5,rhombus/6,kite/5,kite/6}
1080 {
1081 \tikzset{external/export next=false}
1082 \begin{tikzpicture}[
1083 every tile/.style={draw},
1084 remember picture,
1085 overlay,
1086 scale=20
1087 ]
1088 \coordinate (a) at (current page.center);
1089 \begin{scope}[shift={(a)}]
1090 \foreach[evaluate=\k as \mk using {\k+Mod(\k,2)},evaluate=\k as \ax using {Mod(\k,2) == 0 ? "T" : "t"}] \k in {0,...,9} {
1091 \begin{scope}[rotate=\mk*36]
1092 \TilingDecomposition{\tp}{\lvl}{\ax}
1093 \end{scope}
1094 }
1095 \end{scope}
1096 \end{tikzpicture}
1097 \newpage
1098 }
1099 \end{justexample}
1100 \end{document}
1101
1102 \begin{tikzpicture}
1103 \path[save tiling path=a] (0,0) -- (1,0);
1104 \path[save tiling path=b] (0,0) -- (1,0);
1105 \path[save tiling path=c] (0,0) -- (1,0);
1106 \BakeTile{thin rhombus}
1107 \BakeTile{thick rhombus}
1108 \BakeTile{golden triangle}
1109 \BakeTile{reverse golden triangle}
1110 \BakeTile{golden gnomon}
1111 \BakeTile{reverse golden gnomon}
1112 \BakeTile{kite}
1113 \BakeTile{dart}
1114 \end{tikzpicture}
1115
1116 \newpage
1117
1118 \foreach \tp/\lvl in {rhombus/5,rhombus/6,kite/5,kite/6}
1119 {
1120 \begin{tikzpicture}[
1121 every tile/.style={draw},
1122 remember picture,
1123 overlay,
1124 scale=20
1125 ]
1126 \coordinate (a) at (current page.center);
1127 \begin{scope}[shift={(a)}]
1128 \foreach[evaluate=\k as \mk using {\k+Mod(\k,2)},evaluate=\k as \ax using {Mod(\k,2) == 0 ? "T" : "t"}] \k in {0,...,9} {
1129 \begin{scope}[rotate=\mk*36]
1130 \TilingDecomposition{\tp}{\lvl}{\ax}
1131 \end{scope}
1132 }
1133 \end{scope}
1134 \end{tikzpicture}
1135 \newpage
1136 }
1137
1138
1139
1140 %% \foreach \lvl in {5,6}
1141 %% {
1142 %% \begin{tikzpicture}[
1143 %% every tile/.style={draw},
1144 %% remember picture,
1145 %% overlay,
1146 %% scale=180
1147 %% ]
1148 %% \coordinate (a) at (current page.center);
1149 %% \TilingDecomposition{pentagon}{\lvl}{D}
1150 %% \end{tikzpicture}
1151 %% \newpage
1152 %% }
1153
1154
1155 \end{document}
1156
1157 % Local Variables:
1158 % tex-output-type: "pdf18"
1159 % End: