Debian Codegraph @

texmf-dist/tex/latex/tilings/tikzlibrarytilings.polykite.code.tex

raw
1 %%
2 %% This is file `tikzlibrarytilings.polykite.code.tex',
3 %% generated with the docstrip utility.
4 %%
5 %% The original source files were:
6 %%
7 %% tilings_code.dtx (with options: `polykite')
8 %% ----------------------------------------------------------------
9 %% tilings --- TikZ library for producing tilings
10 %% E-mail: [email protected]
11 %% Released under the LaTeX Project Public License v1.3c or later
12 %% See http://www.latex-project.org/lppl.txt
13 %% ----------------------------------------------------------------
14 %%
15 \RequirePackage{tikz}
16 \usetikzlibrary{tilings}
17 \ProvidesFile {tikzlibrarytilings.polykite.code.tex}
18 [2023/06/01 v2.0 TikZ pics for Aperiodical Polykite tiles]
19 \DeclareDocumentCommand \DefinePolykiteTile {s m m m}
20 {
21 \IfBooleanTF {#1}
22 {
23 \DefineTile {#2} {2 2 1 1 2 2 1 1 1 1 2 2 1 1}
24 }
25 {
26 \DefineTile {#2} {1 1 2 2 1 1 2 2 2 2 1 1 2 2}
27 }
28 {
29 {0 : #4}
30 ++{90 : #3}
31 ++{150 : #3}
32 ++{240 : #4}
33 ++{180 : #4}
34 ++{-90 : #3}
35 ++{210 : #3}
36 ++{-60 : #4}
37 ++{0 : #4}
38 ++{0 : #4}
39 ++{60 : #4}
40 ++{-30 : #3}
41 ++{30 : #3}
42 ++{120 : #4}
43 }
44 }
45 \DefinePolykiteTile{aperiodical hat}{sqrt(3)/2}{1/2}
46 \DefinePolykiteTile{spectral hat}{sqrt(3)/2}{1/2}
47 \DefinePolykiteTile{aperiodical turtle}{1/2}{sqrt(3)/2}
48 \DefinePolykiteTile*{spectral turtle}{1/2}{sqrt(3)/2}
49 \DefineTile {spectre} {a A a A a A a A a A a A a A}
50 {
51 {0 : .75}
52 ++{90 : .75}
53 ++{150 : .75}
54 ++{240 : .75}
55 ++{180 : .75}
56 ++{-90 : .75}
57 ++{210 : .75}
58 ++{-60 : .75}
59 ++{0 : .75}
60 ++{0 : .75}
61 ++{60 : .75}
62 ++{-30 : .75}
63 ++{30 : .75}
64 ++{120 : .75}
65 }
66 \DefineTile{meta cluster T}{A A b}
67 {
68 { -1.5 , -sqrt(3)/2 }
69 { 1.5 , -sqrt(3)/2 }
70 { 0 , sqrt(3) }
71 }
72 \DefineTile{meta cluster P}{1 D d A 1 D d b}
73 {
74 { -2.5, sqrt(3)/2 }
75 { -2, 0 }
76 { -1.5, -sqrt(3)/2 }
77 { -0.5 , -sqrt(3)/2 }
78 { 2.5 , -sqrt(3)/2 }
79 { 2 , 0 }
80 { 1.5 , sqrt(3)/2 }
81 { .5 , sqrt(3)/2 }
82 }
83 \DefineTile{meta cluster F}{1 D d 1 D c C d b}
84 {
85 { -2.5, sqrt(3)/2 }
86 { -2, 0 }
87 { -1.5, -sqrt(3)/2 }
88 { -0.5 , -sqrt(3)/2 }
89 { .5 , -sqrt(3)/2 }
90 { 1.5 , -sqrt(3)/2 }
91 { 2 , 0 }
92 { 1.5 , sqrt(3)/2 }
93 { .5 , sqrt(3)/2 }
94 }
95 \DefineTile{meta cluster H}{B D d B D d a D d}
96 {
97 { -2, -sqrt(3) }
98 { 1, -sqrt(3) }
99 { 2, -sqrt(3) }
100 { 2.5, -sqrt(3)/2 }
101 { 1, sqrt(3)}
102 { .5 , 3*sqrt(3)/2 }
103 { -.5 , 3*sqrt(3)/2 }
104 { -2, 0 }
105 { -2.5, -sqrt(3)/2 }
106 }
107 \DefineTile{super cluster T}{A A b}
108 {
109 { -30 : 3 * (1 + sqrt(5))/2 / sqrt(3) }
110 { 90 : 3 * (1 + sqrt(5))/2 / sqrt(3) }
111 { 210 : 3 * (1 + sqrt(5))/2 / sqrt(3) }
112 }
113 \DefineTile{super cluster P}{1 D d A 1 D d b}
114 {
115 { - 1.75 - sqrt(5), (sqrt(5)/2 + 1) * sqrt(3)/2 }
116 ++{ -60 : 1 + sqrt(5) }
117 ++{ -60 : 1}
118 ++{ 1, 0}
119 ++{ 3*(1 + sqrt(5))/2, 0 }
120 ++{ 120 : 1 + sqrt(5) }
121 ++{ 120 : 1 }
122 ++{ -1, 0 }
123 }
124 \DefineTile{super cluster F}{1 D d 1 D c C d b}
125 {
126 { - 1.75 - sqrt(5), (sqrt(5)/2 + 1) * sqrt(3)/2 }
127 ++{ -60 : 1 + sqrt(5) }
128 ++{ -60 : 1}
129 ++{ 1, 0}
130 ++{ 1 + sqrt(5), 0 }
131 ++{ 1, 0 }
132 +{ -.75 + (2 + sqrt(5)) * sqrt(3)/4 * sqrt(3)/3,
133 (2 + sqrt(5)) * sqrt(3)/4 + 3/4 * sqrt(3)/3 }
134 ++{ -1.5, (2 + sqrt(5)) * sqrt(3)/2 }
135 ++{ -1, 0 }
136 }
137 \DefineTile{super cluster H}{B D d B D d a D d}
138 {
139 {1.75 + 3*sqrt(5)/4, -(1 + sqrt(5))*sqrt(3)/4}
140 ++{120 : 3*(1+sqrt(5))/2 }
141 ++{120 : 1 }
142 ++{-1,0}
143 ++{240 : 3*(1+sqrt(5))/2}
144 ++{240 : 1}
145 ++{300 : 1}
146 ++{ 3*(1+sqrt(5))/2, 0 }
147 ++{1, 0}
148 ++{60 : 1}
149 }
150 \DefineTile{subcluster H}{B B a}
151 {
152 { 0, 0 }
153 { 3, 0 }
154 { 60 : 3 }
155 }
156 \DefineTile{subcluster T}{A A b}
157 {
158 { 0, 0 }
159 { 3, 0 }
160 { 60 : 3 }
161 }
162 \DefineTile{subcluster P}{ 1 A 1 b }
163 {
164 { 0, 0 }
165 { 1, 0 }
166 { 4, 0 }
167 { 3, 0 }
168 }
169 \DefineTile{subcluster F}{ 1 1 f F b }
170 {
171 { 0, 0 }
172 { 1, 0 }
173 +{ 60 : 1 }
174 { 2, 0 }
175 { 3, 0 }
176 }
177 \tikzset{
178 no clip/.code={%
179 \tikz@addmode{\tikz@mode@clipfalse}%
180 },
181 every subcluster P clip/.style={no clip},
182 every subcluster F clip/.style={no clip},
183 }
184 \BakeTile {aperiodical hat}
185 \BakeTile {aperiodical turtle}
186 \BakeTile {spectral hat}
187 \BakeTile {spectral turtle}
188 \BakeTile {spectre}
189 \BakeTile {meta cluster T}
190 \BakeTile {meta cluster P}
191 \BakeTile {meta cluster F}
192 \BakeTile {meta cluster H}
193 \BakeTile {super cluster T}
194 \BakeTile {super cluster P}
195 \BakeTile {super cluster F}
196 \BakeTile {super cluster H}
197 \ExplSyntaxOn
198 \clist_map_inline:nn {a,A,b,B,f,F}
199 {
200 \tl_new:c {g__tilings_side_polykite_#1_tl}
201 \tl_if_exist:cF {g__tilings_side_#1_tl}
202 {
203 \tl_new:c {g__tilings_side_#1_tl}
204 }
205 }
206
207 \tl_gset:cn {g__tilings_side_polykite_A_tl}
208 {
209 \pgfsyssoftpath@movetotoken {0pt}{-0.3333332942822268pt}
210 \pgfsyssoftpath@linetotoken {0.0833331478405773pt}{-0.1889954840909892pt}
211 \pgfsyssoftpath@linetotoken {0.3333332942822268pt}{-0.3333332942822268pt}
212 \pgfsyssoftpath@linetotoken {0.5833333235705567pt}{-0.1889954840909892pt}
213 \pgfsyssoftpath@linetotoken {0.6666667057177732pt}{-0.3333332942822268pt}
214 \pgfsyssoftpath@linetotoken {1pt}{-0.3333332942822268pt}
215 }
216 \tl_gset:cn {g__tilings_side_polykite_a_tl}
217 {
218 \pgfsyssoftpath@movetotoken {0pt}{0.33333pt}
219 \pgfsyssoftpath@linetotoken {0.33333pt}{0.33333pt}
220 \pgfsyssoftpath@linetotoken {0.41667pt}{0.189pt}
221 \pgfsyssoftpath@linetotoken {0.66667pt}{0.33333pt}
222 \pgfsyssoftpath@linetotoken {0.91667pt}{0.189pt}
223 \pgfsyssoftpath@linetotoken {1pt}{0.33333pt}
224 }
225 \tl_gset:cn {g__tilings_side_polykite_B_tl}
226 {
227 \pgfsyssoftpath@movetotoken {0pt}{0pt}
228 \pgfsyssoftpath@linetotoken {0.3333332942822268pt}{0pt}
229 \pgfsyssoftpath@linetotoken {0.4166665592761237pt}{0.1443378101912376pt}
230 \pgfsyssoftpath@linetotoken {0.6666667057177732pt}{0pt}
231 \pgfsyssoftpath@linetotoken {0.9166666178527835pt}{0.1443378101912376pt}
232 \pgfsyssoftpath@linetotoken {1pt}{0pt}
233 }
234 \tl_gset:cn {g__tilings_side_polykite_b_tl}
235 {
236 \pgfsyssoftpath@movetotoken {0pt}{0pt}
237 \pgfsyssoftpath@linetotoken {0.08333pt}{-0.14433pt}
238 \pgfsyssoftpath@linetotoken {0.33333pt}{0pt}
239 \pgfsyssoftpath@linetotoken {0.58333pt}{-0.14433pt}
240 \pgfsyssoftpath@linetotoken {0.66667pt}{0pt}
241 \pgfsyssoftpath@linetotoken {1pt}{0pt}
242 }
243 \tl_gset:cn {g__tilings_side_polykite_F_tl}
244 {
245 \pgfsyssoftpath@movetotoken {0pt}{-2.00000070292pt}
246 \pgfsyssoftpath@linetotoken {0.74999982427pt}{-1.566987221617321pt}
247 \pgfsyssoftpath@linetotoken {1pt}{-2.00000070292pt}
248 }
249 \tl_gset:cn {g__tilings_side_polykite_f_tl}
250 {
251 \pgfsyssoftpath@movetotoken {0pt}{2pt}
252 \pgfsyssoftpath@linetotoken {0.25pt}{1.56699pt}
253 \pgfsyssoftpath@linetotoken {1pt}{2pt}
254 }
255
256 \clist_map_inline:nn {a,A,b,B,f,F}
257 {
258 \tl_gclear_new:c {g__tilings_side_backup_#1_tl}
259 \tl_gset_eq:cc {g__tilings_side_backup_#1_tl} {g__tilings_side_#1_tl}
260 \tl_gclear_new:c {g__tilings_side_#1_tl}
261 \tl_gset_eq:cc {g__tilings_side_#1_tl}{g__tilings_side_polykite_#1_tl}
262 }
263
264 \BakeTile{subcluster~ H}
265 \BakeTile{subcluster~ T}
266 \BakeTile{subcluster~ P}
267 \BakeTile{subcluster~ F}
268
269 \clist_map_inline:nn {a,A,b,B,f,F}
270 {
271 \tl_gset_eq:cc {g__tilings_side_#1_tl} {g__tilings_side_backup_#1_tl}
272 }
273 \cs_new_protected_nopar:Npn \__tilings_place_cluster_tile:nn #1#2
274 {
275 \group_begin:
276 \int_gincr:N \g__tilings_tile_int
277 \fp_set:Nn \l__tilings_tmpa_fp {\l__tilings_step_dim/(1cm)}
278 \pgftransformscale{\fp_use:N \l__tilings_tmpa_fp}
279 \tl_set:Nx \l__tilings_tmpc_tl
280 {
281 {\int_use:N \g__tilings_tile_int}
282 {\int_use:N \g__tilings_tiles_int}
283 }
284 \UseTile[
285 every~ tile/.try,
286 every~ #1~#2/.try,
287 tile~ \int_use:N \g__tilings_tile_int/.try,
288 tile/.try/.expand~ once=\l__tilings_tmpc_tl
289 ]{#1~ #2}
290 \group_end:
291 }
292 \cs_generate_variant:Nn \__tilings_place_cluster_tile:nn {Vn}
293 \prop_new:N \g__tilings_supercluster_lms_rule_prop
294 \prop_gput:Nnn \g__tilings_supercluster_lms_rule_prop {T}
295 {
296 [s H]
297 }
298 \prop_gput:Nnn \g__tilings_supercluster_lms_rule_prop {H}
299 {
300 [s {r{-60}} T]
301 [s {x{\fp_to_decimal:n{1}}} {y{\fp_to_decimal:n{(1+2*\c__tilings_phi_fp)}}} H]
302 [s
303 {x{\fp_to_decimal:n{-2-3*\c__tilings_phi_fp}}}
304 {y{\fp_to_decimal:n{-\c__tilings_phi_fp}}}
305 H]
306 [s
307 {x{\fp_to_decimal:n{1+3*\c__tilings_phi_fp}}}
308 {y{\fp_to_decimal:n{-1-\c__tilings_phi_fp}}}
309 {r{-120}}
310 H]
311 [s
312 {x{\fp_to_decimal:n{-1.5-3.5*\c__tilings_phi_fp}}}
313 {y{\fp_to_decimal:n{2.5*\c__tilings_phi_fp+1.5}}}
314 {r{-120}}
315 P]
316 [s
317 {x{\fp_to_decimal:n{-1.5-2*\c__tilings_phi_fp}}}
318 {y{\fp_to_decimal:n{-1.5-3*\c__tilings_phi_fp}}}
319 {r{180}}
320 P]
321 [s
322 {x{\fp_to_decimal:n{3+5.5*\c__tilings_phi_fp}}}
323 {y{\fp_to_decimal:n{.5*\c__tilings_phi_fp}}}
324 {r{120}}
325 P]
326 [s
327 {x{\fp_to_decimal:n{-4.5-6.5*\c__tilings_phi_fp}}}
328 {y{\fp_to_decimal:n{.5-.5*\c__tilings_phi_fp}}}
329 {r{-120}}
330 F]
331 [s
332 {x{\fp_to_decimal:n{1.5+4*\c__tilings_phi_fp}}}
333 {y{\fp_to_decimal:n{-2.5-3*\c__tilings_phi_fp}}}
334 F]
335 [s
336 {x{\fp_to_decimal:n{3+2.5*\c__tilings_phi_fp}}}
337 {y{\fp_to_decimal:n{2+3.5*\c__tilings_phi_fp}}}
338 {r{120}}
339 F]
340 }
341 \prop_gput:Nnn \g__tilings_supercluster_lms_rule_prop {P}
342 {
343 [s {r{60}} P]
344 [s
345 {x{\fp_to_decimal:n{2.5+3.5*\c__tilings_phi_fp}}}
346 {y{\fp_to_decimal:n{-.5-.5*\c__tilings_phi_fp}}}
347 {r{-120}}
348 H]
349 [s
350 {x{\fp_to_decimal:n{-2.5-3.5*\c__tilings_phi_fp}}}
351 {y{\fp_to_decimal:n{.5+.5*\c__tilings_phi_fp}}}
352 {r{180}}
353 H]
354 [s
355 {x{\fp_to_decimal:n{4.5+6*\c__tilings_phi_fp}}}
356 {y{\fp_to_decimal:n{.5+\c__tilings_phi_fp}}}
357 {r{120}}
358 F]
359 [s
360 {x{\fp_to_decimal:n{-4.5-6*\c__tilings_phi_fp}}}
361 {y{\fp_to_decimal:n{-.5-\c__tilings_phi_fp}}}
362 {r{-60}}
363 F]
364 }
365 \prop_gput:Nnn \g__tilings_supercluster_lms_rule_prop {F}
366 {
367 [s {r{60}} P]
368 [s
369 {x{\fp_to_decimal:n{2.5+3.5*\c__tilings_phi_fp}}}
370 {y{\fp_to_decimal:n{-.5-.5*\c__tilings_phi_fp}}}
371 {r{-120}}
372 H]
373 [s
374 {x{\fp_to_decimal:n{-2.5-3.5*\c__tilings_phi_fp}}}
375 {y{\fp_to_decimal:n{.5+.5*\c__tilings_phi_fp}}}
376 {r{180}}
377 H]
378 [s
379 {x{\fp_to_decimal:n{4.5+6*\c__tilings_phi_fp}}}
380 {y{\fp_to_decimal:n{.5+\c__tilings_phi_fp}}}
381 {r{120}}
382 F]
383 [s
384 {x{\fp_to_decimal:n{-4.5-6*\c__tilings_phi_fp}}}
385 {y{\fp_to_decimal:n{-.5-\c__tilings_phi_fp}}}
386 {r{-60}}
387 F]
388 [s
389 {x{\fp_to_decimal:n{3+4.5*\c__tilings_phi_fp}}}
390 {y{\fp_to_decimal:n{-2-2.5*\c__tilings_phi_fp}}}
391 F]
392 }
393 \prop_gput:Nnn \g__tilings_drawables_lms_prop {supercluster} {HTPF}
394 \fp_const:Nn \c__tilings_phi_fp {(1 + sqrt(5))/2}
395 \prop_new:N \g__tilings_supercluster_lms_action_prop
396
397 \prop_gput:Nnn \g__tilings_supercluster_lms_action_prop {r}
398 {
399 \pgftransformrotate{\l__tilings_parameters_lms_tl}
400 }
401 \prop_gput:Nnn \g__tilings_supercluster_lms_action_prop {x}
402 {
403 \pgftransformxshift{
404 \fp_to_dim:n
405 {.5 * (\l__tilings_parameters_lms_tl) * \l__tilings_step_dim}
406 }
407 }
408 \prop_gput:Nnn \g__tilings_supercluster_lms_action_prop {y}
409 {
410 \pgftransformyshift{
411 \fp_to_dim:n
412 {.5 * sqrt(3) * (\l__tilings_parameters_lms_tl) * \l__tilings_step_dim}
413 }
414 }
415
416 \prop_gput:Nnn \g__tilings_supercluster_lms_action_prop {s}
417 {
418 \fp_set:Nn \l__tilings_tmpa_fp {
419 \l__tilings_step_dim
420 /
421 \c__tilings_phi_fp
422 /
423 \c__tilings_phi_fp
424 }
425 \dim_set:Nn \l__tilings_step_dim {\fp_to_dim:N \l__tilings_tmpa_fp}
426 }
427 \prop_gput:Nnn \g__tilings_supercluster_lms_action_prop {H}
428 {
429 \__tilings_place_cluster_tile:nn {super~ cluster}{H}
430 }
431 \prop_gput:Nnn \g__tilings_supercluster_lms_action_prop {T}
432 {
433 \__tilings_place_cluster_tile:nn {super~ cluster}{T}
434 }
435 \prop_gput:Nnn \g__tilings_supercluster_lms_action_prop {P}
436 {
437 \__tilings_place_cluster_tile:nn {super~ cluster}{P}
438 }
439 \prop_gput:Nnn \g__tilings_supercluster_lms_action_prop {F}
440 {
441 \__tilings_place_cluster_tile:nn {super~ cluster}{F}
442 }
443 \cs_new_protected_nopar:Npn \__tilings_place_cluster_tile_as_pic:nnnnnn #1#2#3#4#5#6
444 {
445 \group_begin:
446 \int_gincr:N \g__tilings_tile_int
447 \fp_set:Nn \l__tilings_tmpa_fp {\l__tilings_step_dim/(1cm)}
448 \tl_set:Nx \l__tilings_tmpc_tl
449 {
450 {\int_use:N \g__tilings_tile_int}
451 {\int_use:N \g__tilings_tiles_int}
452 }
453 \tl_clear:N \l__tilings_tmpa_tl
454 \tl_put_right:Nn \l__tilings_tmpa_tl
455 {
456 \pic[
457 every~ tile/.try,
458 every~ #1~#2/.try,
459 }
460 \tl_put_right:Nx \l__tilings_tmpa_tl
461 {
462 tile~ \int_use:N \g__tilings_tile_int/.try,
463 tile/.try=\l__tilings_tmpc_tl,
464 scale=\fp_use:N \l__tilings_tmpa_fp,
465 }
466 \tl_put_right:Nn \l__tilings_tmpa_tl
467 {
468 name=#3,
469 }
470 \tl_if_empty:nTF {#4}
471 {
472 \tl_put_right:Nn \l__tilings_tmpa_tl
473 {
474 first~ tile/.try,
475 }
476 }
477 {
478 \tl_put_right:Nn \l__tilings_tmpa_tl
479 {
480 align~ with=#4~along~#5
481 }
482 \tl_if_single:nF {#6}
483 {
484 \tl_put_right:Nx \l__tilings_tmpa_tl
485 {
486 \c_space_tl using~\tl_tail:n {#6}
487 }
488 }
489 \tl_put_right:Nn \l__tilings_tmpa_tl {,}
490 }
491 \tl_put_right:Nn \l__tilings_tmpa_tl
492 {
493 #1~ #2
494 ];
495 }
496 \tl_use:N \l__tilings_tmpa_tl
497 \group_end:
498 }
499 \cs_generate_variant:Nn \__tilings_place_cluster_tile_as_pic:nnnnnn {
500 Vnnnnn, VnVnnn, VnVVnn
501 }
502 \tikzset{
503 cluster~ type/.initial=super~ cluster,
504 first~ file/.style={transform~ shape}
505 }
506 \prop_new:N \g__tilings_cluster_lms_rule_prop
507 \cs_new_nopar:Npn \__tilings_tile_label:
508 {
509 \tl_item:Nn \l__tilings_parameters_lms_tl {1}
510 }
511 \cs_new_nopar:Npn \__tilings_adjoint_label:
512 {
513 \tl_item:Nn \l__tilings_parameters_lms_tl {2}
514 }
515 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {T}
516 {
517 [s {H{\__tilings_tile_label:0}{}}]
518 }
519 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {H}
520 {
521 [s {r{-60}} {T{\__tilings_tile_label:0}{}}]
522 [{ {HTa{A1}} {\__tilings_tile_label:1} {\__tilings_tile_label:0} }]
523 [{ {HTa{A2}} {\__tilings_tile_label:2} {\__tilings_tile_label:0} }]
524 [{ {HT{B1}b} {\__tilings_tile_label:3} {\__tilings_tile_label:0} }]
525 [{ {PHb{B2}} {\__tilings_tile_label:4} {\__tilings_tile_label:1} }]
526 [{ {PHb{B2}} {\__tilings_tile_label:5} {\__tilings_tile_label:2} }]
527 [{ {PHAa} {\__tilings_tile_label:6} {\__tilings_tile_label:3} }]
528 [{ {FHb{B1}} {\__tilings_tile_label:7} {\__tilings_tile_label:1} }]
529 [{ {FHb{B1}} {\__tilings_tile_label:8} {\__tilings_tile_label:2} }]
530 [{ {FHb{B2}} {\__tilings_tile_label:9} {\__tilings_tile_label:3} }]
531 }
532 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {P}
533 {
534 [s {r{60}} {P{\__tilings_tile_label:0}{}}]
535 [{ {HPaA} {\__tilings_tile_label:1} {\__tilings_tile_label:0} }]
536 [{ {HP{B2}b} {\__tilings_tile_label:2} {\__tilings_tile_label:0} }]
537 [{ {FHb{B2}} {\__tilings_tile_label:3} {\__tilings_tile_label:1} }]
538 [{ {FHb{B1}} {\__tilings_tile_label:4} {\__tilings_tile_label:2} }]
539 }
540 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {F}
541 {
542 [s {r{60}} {P{\__tilings_tile_label:0}{}}]
543 [{ {HPaA} {\__tilings_tile_label:1} {\__tilings_tile_label:0} }]
544 [{ {HP{B2}b} {\__tilings_tile_label:2} {\__tilings_tile_label:0} }]
545 [{ {FHb{B2}} {\__tilings_tile_label:3} {\__tilings_tile_label:1} }]
546 [{ {FHb{B1}} {\__tilings_tile_label:4} {\__tilings_tile_label:2} }]
547 [{ {FHb{B1}} {\__tilings_tile_label:5} {\__tilings_tile_label:1} }]
548 }
549 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {TH{A1}a} {}
550 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {TH{A2}a} {}
551 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {THb{B1}} {}
552 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {THb{B2}} {}
553 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {HTa{A1}} {}
554 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {HTa{A2}} {}
555 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {HT{B1}b} {}
556 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {HT{B2}b} {}
557 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {HPaA} {}
558 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {HP{B1}b} {}
559 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {HP{B2}b} {}
560 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {HF{B1}b} {}
561 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {HF{B2}b} {}
562 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {PHAa} {}
563 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {PHb{B1}} {}
564 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {PHb{B2}} {}
565 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {PF{11}{11}} {}
566 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {PF{12}{11}} {}
567 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {PF{11}{12}} {}
568 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {PF{12}{12}} {}
569 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {FHb{B1}} {}
570 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {FHb{B2}} {}
571 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {FP{11}{11}} {}
572 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {FP{12}{11}} {}
573 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {FP{11}{12}} {}
574 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {FP{12}{12}} {}
575 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {FFfF} {}
576 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {FFFf} {}
577 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {FF{11}{11}} {}
578 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {FF{12}{11}} {}
579 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {FF{11}{12}} {}
580 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {FF{12}{12}} {}
581 \cs_new_nopar:cpn {__tilings_T{A1}_creator:nnnnn} #1#2#3#4#5
582 {
583 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {T#1{A1}#2}
584 {
585 [{ {H#3{B1}#4} {\__tilings_tile_label:0} {\__tilings_adjoint_label:#5} }]
586 }
587 }
588 \cs_new_nopar:cpn {__tilings_T{A2}_creator:nnnnn} #1#2#3#4#5
589 {
590 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {T#1{A2}#2}
591 {
592 [{ {H#3{B2}#4} {\__tilings_tile_label:0} {\__tilings_adjoint_label:#5} }]
593 }
594 }
595 \cs_new_nopar:cpn {__tilings_Tb_creator:nnnnn} #1#2#3#4#5
596 {
597 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {T#1b#2}
598 {
599 [{ {H#3a#4} {\__tilings_tile_label:0} {\__tilings_adjoint_label:#5} }]
600 }
601 }
602
603 \cs_new_nopar:cpn {__tilings_H{B1}_creator:nnnnn} #1#2#3#4#5
604 {
605 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {H#1{B1}#2}
606 {
607 [{ {P#3A#4} {\__tilings_tile_label:4} {\__tilings_adjoint_label:#5} }]
608
609 [{ {HP{B2}b} {\__tilings_tile_label:1} {\__tilings_tile_label:4} }]
610 [{ {TH{A1}a} {\__tilings_tile_label:0} {\__tilings_tile_label:1} }]
611
612 [{ {HTa{A2}} {\__tilings_tile_label:2} {\__tilings_tile_label:0} }]
613 [{ {PHb{B2}} {\__tilings_tile_label:5} {\__tilings_tile_label:2} }]
614
615 [{ {HT{B1}b} {\__tilings_tile_label:3} {\__tilings_tile_label:0} }]
616 [{ {PHAa} {\__tilings_tile_label:6} {\__tilings_tile_label:3} }]
617
618 [{ {FHb{B1}} {\__tilings_tile_label:7} {\__tilings_tile_label:1} }]
619 [{ {FHb{B1}} {\__tilings_tile_label:8} {\__tilings_tile_label:2} }]
620 [{ {FHb{B2}} {\__tilings_tile_label:9} {\__tilings_tile_label:3} }]
621 }
622 }
623
624 \cs_new_nopar:cpn {__tilings_H{B2}_creator:nnnnn} #1#2#3#4#5
625 {
626 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {H#1{B2}#2}
627 {
628 [{ {P#3A#4} {\__tilings_tile_label:5} {\__tilings_adjoint_label:#5} }]
629
630 [{ {HP{B2}b} {\__tilings_tile_label:2} {\__tilings_tile_label:5} }]
631 [{ {TH{A2}a} {\__tilings_tile_label:0} {\__tilings_tile_label:2} }]
632
633 [{ {HTa{A1}} {\__tilings_tile_label:1} {\__tilings_tile_label:0} }]
634 [{ {PHb{B2}} {\__tilings_tile_label:4} {\__tilings_tile_label:1} }]
635
636 [{ {HT{B1}b} {\__tilings_tile_label:3} {\__tilings_tile_label:0} }]
637 [{ {PHAa} {\__tilings_tile_label:6} {\__tilings_tile_label:3} }]
638
639 [{ {FHb{B1}} {\__tilings_tile_label:7} {\__tilings_tile_label:1} }]
640 [{ {FHb{B1}} {\__tilings_tile_label:8} {\__tilings_tile_label:2} }]
641 [{ {FHb{B2}} {\__tilings_tile_label:9} {\__tilings_tile_label:3} }]
642 }
643 }
644
645 \cs_new_nopar:cpn {__tilings_Ha_creator:nnnnn} #1#2#3#4#5
646 {
647 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {H#1a#2}
648 {
649 [{ {P#3b#4} {\__tilings_tile_label:6} {\__tilings_adjoint_label:#5} }]
650
651 [{ {HPaA} {\__tilings_tile_label:3} {\__tilings_tile_label:6} }]
652 [{ {THb{B1}} {\__tilings_tile_label:0} {\__tilings_tile_label:3} }]
653
654 [{ {HTa{A1}} {\__tilings_tile_label:1} {\__tilings_tile_label:0} }]
655 [{ {PHb{B2}} {\__tilings_tile_label:4} {\__tilings_tile_label:1} }]
656
657 [{ {HTa{A2}} {\__tilings_tile_label:2} {\__tilings_tile_label:0} }]
658 [{ {PHb{B2}} {\__tilings_tile_label:5} {\__tilings_tile_label:2} }]
659
660 [{ {FHb{B1}} {\__tilings_tile_label:7} {\__tilings_tile_label:1} }]
661 [{ {FHb{B1}} {\__tilings_tile_label:8} {\__tilings_tile_label:2} }]
662 [{ {FHb{B2}} {\__tilings_tile_label:9} {\__tilings_tile_label:3} }]
663 }
664 }
665
666 \cs_new_nopar:cpn {__tilings_PA_creator:nnnnn} #1#2#3#4#5
667 {
668 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {P#1A#2}
669 {
670 [{ {H#3{B1}#4} {\__tilings_tile_label:1} {\__tilings_adjoint_label:#5} }]
671 [{ {PHAa} {\__tilings_tile_label:0} {\__tilings_tile_label:1} }]
672 [{ {HP{B2}b} {\__tilings_tile_label:2} {\__tilings_tile_label:0} }]
673
674 [{ {FHb{B2}} {\__tilings_tile_label:3} {\__tilings_tile_label:1} }]
675 [{ {FHb{B1}} {\__tilings_tile_label:4} {\__tilings_tile_label:2} }]
676 }
677 }
678
679 \cs_new_nopar:cpn {__tilings_Pb_creator:nnnnn} #1#2#3#4#5
680 {
681 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {P#1b#2}
682 {
683 [{ {H#3a#4} {\__tilings_tile_label:2} {\__tilings_adjoint_label:#5} }]
684 [{ {PHb{B2}} {\__tilings_tile_label:0}{\__tilings_tile_label:2} }]
685 [{ {HPaA} {\__tilings_tile_label:1} {\__tilings_tile_label:0} }]
686
687 [{ {FHb{B2}} {\__tilings_tile_label:3} {\__tilings_tile_label:1} }]
688 [{ {FHb{B1}} {\__tilings_tile_label:4} {\__tilings_tile_label:2} }]
689 }
690 }
691
692 \cs_new_nopar:cpn {__tilings_Fb_creator:nnnnn} #1#2#3#4#5
693 {
694 \prop_gput:Nnn \g__tilings_cluster_lms_rule_prop {F#1b#2}
695 {
696 [{ {H#3a#4} {\__tilings_tile_label:2} {\__tilings_adjoint_label:#5} }]
697 [{ {PHb{B2}} {\__tilings_tile_label:0}{\__tilings_tile_label:2} }]
698 [{ {HPaA} {\__tilings_tile_label:1} {\__tilings_tile_label:0} }]
699
700 [{ {FHb{B2}} {\__tilings_tile_label:3} {\__tilings_tile_label:1} }]
701 [{ {FHb{B1}} {\__tilings_tile_label:4} {\__tilings_tile_label:2} }]
702 [{ {FHb{B1}} {\__tilings_tile_label:5} {\__tilings_tile_label:1} }]
703 }
704 }
705 \clist_map_inline:nn
706 {
707 TH{{A1}}a HP{{{B1}}}b06,
708 TH{{A2}}a HP{{{B2}}}b06,
709 THb{{B1}} HPaA04,
710 THb{{B2}} HPaA05,
711 PHAa HP{{{B1}}}b16,
712 PHb{{B1}} HPaA24,
713 PHb{{B2}} HPaA25,
714 FHb{{B1}} HPaA24,
715 FHb{{B2}} HPaA25,
716 }
717 {
718 \tl_clear:N \l__tilings_tmpa_tl
719 \tl_put_right:Nn \l__tilings_tmpa_tl { \use:c }
720 \tl_put_right:Nx \l__tilings_tmpa_tl
721 {
722 {__tilings_ \tl_item:nn {#1}{2}\tl_item:nn {#1}{4} _creator:nnnnn}
723 {\tl_item:nn {#1}{1}}{\tl_item:nn{#1}{3}}
724 \tl_item:nn {#1}{5}\tl_item:nn{#1}{7}
725 \tl_item:nn {#1}{9}
726 }
727 \tl_use:N \l__tilings_tmpa_tl
728 \tl_clear:N \l__tilings_tmpa_tl
729 \tl_put_right:Nn \l__tilings_tmpa_tl { \use:c }
730 \tl_put_right:Nx \l__tilings_tmpa_tl
731 {
732 {__tilings_ \tl_item:nn {#1}{1}\tl_item:nn {#1}{3} _creator:nnnnn}
733 {\tl_item:nn {#1}{2}}{\tl_item:nn{#1}{4}}
734 \tl_item:nn {#1}{6}\tl_item:nn{#1}{8}
735 \tl_item:nn {#1}{10}
736 }
737 \tl_use:N \l__tilings_tmpa_tl
738 }
739
740 \prop_new:N \g__tilings_cluster_lms_action_prop
741 \prop_gput:Nnn \g__tilings_drawables_lms_prop {cluster} {HTPF}
742 \prop_gput:Nnn \g__tilings_cluster_lms_action_prop {r}
743 {
744 \pgftransformrotate{\l__tilings_parameters_lms_tl}
745 }
746 \prop_gput:Nnn \g__tilings_cluster_lms_action_prop {x}
747 {
748 \pgftransformxshift{
749 \fp_to_dim:n
750 {.5 * (\l__tilings_parameters_lms_tl) * \l__tilings_step_dim}
751 }
752 }
753 \prop_gput:Nnn \g__tilings_cluster_lms_action_prop {y}
754 {
755 \pgftransformyshift{
756 \fp_to_dim:n
757 {.5 * sqrt(3) * (\l__tilings_parameters_lms_tl) * \l__tilings_step_dim}
758 }
759 }
760
761 \prop_gput:Nnn \g__tilings_cluster_lms_action_prop {s}
762 {
763 \fp_set:Nn \l__tilings_tmpa_fp {
764 \l__tilings_step_dim
765 /
766 \c__tilings_phi_fp
767 /
768 \c__tilings_phi_fp
769 }
770 \dim_set:Nn \l__tilings_step_dim {\fp_to_dim:N \l__tilings_tmpa_fp}
771 }
772 \clist_map_inline:nn {H,T,P,F}
773 {
774
775 \prop_gput:Nnn \g__tilings_cluster_lms_action_prop {#1}
776 {
777 \__tilings_tikz_keys_get:Nn \l__tilings_tmpa_tl {cluster~type}
778 \tl_set:Nx \l__tilings_tmpb_tl {\tl_item:Nn \l__tilings_parameters_lms_tl {1}}
779 \__tilings_place_cluster_tile_as_pic:VnVnnn
780 \l__tilings_tmpa_tl {#1} \l__tilings_tmpb_tl {}{}{}
781 }
782 }
783 \cs_new_protected_nopar:Npn \__tilings_place_cluster_tile_as_pic_aux:nnnn #1#2#3#4
784 {
785 \__tilings_tikz_keys_get:Nn \l__tilings_tmpa_tl {cluster~type}
786 \tl_set:Nx \l__tilings_tmpb_tl {\__tilings_tile_label:}
787 \tl_set:Nx \l__tilings_tmpc_tl {\__tilings_adjoint_label:}
788 \__tilings_place_cluster_tile_as_pic:VnVVnn
789 \l__tilings_tmpa_tl {#1} \l__tilings_tmpb_tl \l__tilings_tmpc_tl {#4}{#3}
790 }
791
792 \clist_map_inline:nn {
793 TH{A1}a,
794 TH{A2}a,
795 THb{B1},
796 THb{B2},
797 HTa{A1},
798 HTa{A2},
799 HT{B1}b,
800 HT{B2}b,
801 HPaA,
802 HP{B1}b,
803 HP{B2}b,
804 HF{B1}b,
805 HF{B2}b,
806 PHAa,
807 PHb{B1},
808 PHb{B2},
809 PF{11}{11},
810 PF{12}{11},
811 PF{11}{12},
812 PF{12}{12},
813 FHb{B1},
814 FHb{B2},
815 FP{11}{11},
816 FP{12}{11},
817 FP{11}{12},
818 FP{12}{12},
819 FFfF,
820 FFFf,
821 FF{11}{11},
822 FF{12}{11},
823 FF{11}{12},
824 FF{12}{12}
825 }
826 {
827 \prop_gput:Nnn \g__tilings_cluster_lms_action_prop {#1}
828 {
829 \__tilings_place_cluster_tile_as_pic_aux:nnnn #1
830 }
831 }
832
833 \ExplSyntaxOff
834 %%
835 %% Copyright (C) 2014-2023 by Andrew Stacey <[email protected]>
836 %%
837 %% This work may be distributed and/or modified under the
838 %% conditions of the LaTeX Project Public License (LPPL), either
839 %% version 1.3c of this license or (at your option) any later
840 %% version. The latest version of this license is in the file:
841 %%
842 %% http://www.latex-project.org/lppl.txt
843 %%
844 %% This work is "maintained" (as per LPPL maintenance status) by
845 %% Andrew Stacey.
846 %%
847 %% This work consists of the files penrose_code.dtx
848 %% penrose.tex
849 %% and the derived files penrose.ins
850 %% penrose_code.pdf
851 %% penrose.pdf
852 %% tikzlibrarytilings.code.tex
853 %% tikzlibrarytilings.penrose.code.tex
854 %% tikzlibrarytilings.polykite.code.tex
855 %% tikzlibrarypenrose.code.tex
856 %% README.txt
857 %%
858 %%
859 %% End of file `tikzlibrarytilings.polykite.code.tex'.