In this article we plot and animate Penrose tilings using de Bruijn’s multigrid method.

Initialization Code

Here the function makeMultigridTilingPlot is defined which uses the multigrid method to create a rhombic tiling in the plane given a list of grid shift values:

makeMultigridTilingPlot

In[]:=
ClearAll[makeMultigridTilingPlot];​​Options[makeMultigridTilingPlot]={​​"GridRange"->5,​​"EdgeForm"->Thin,​​"TileColorFunction"->Function[Blend[{GrayLevel[.5],GrayLevel[.95]},#]],​​PlotRange->Automatic,​​ImageSize->Automatic​​};​​makeMultigridTilingPlot[gridShifts_List,OptionsPattern[]]:=​​Module[{range,plotRange,gridCount,gridVectors,tileTypeGridIndices,​​tileTypeCount,tileTypeGridVectors,tileTypeAreas,tileTypeColors,​​gridLineNumbers,tileTypeGraphics,gridIndices,gridLineIntersectionPoints,​​tileCornerLatticeCoordinates,tileCornerVertices,gridVector1,gridVector2,tileVertices},​​range=OptionValue["GridRange"];​​gridCount=Length[gridShifts];​​gridVectors=CirclePoints[gridCount];​​gridVectors=gridVectors//N;​​tileTypeGridIndices=Subsets[Range[gridCount],{2}];​​tileTypeGridIndices=Select[tileTypeGridIndices,Function[Unequal[Chop[Det[N[gridVectors[[#]]]]],0]]];​​tileTypeCount=Length[tileTypeGridIndices];​​tileTypeGridVectors=gridVectors[[#]]&/@tileTypeGridIndices;​​tileTypeAreas=Abs[Map[Det,tileTypeGridVectors]];​​tileTypeColors=Map[OptionValue["TileColorFunction"],Rescale[Round[tileTypeAreas,10.^-10]]];​​gridLineNumbers=Table[Range[-range,range],gridCount];​​tileTypeGraphics=​​Table[​​gridIndices=tileTypeGridIndices[[tileTypeIndex]];​​gridLineIntersectionPoints=Dot[Transpose[Transpose[Tuples[gridLineNumbers[[gridIndices]]]]-gridShifts[[gridIndices]]],Transpose[Inverse[gridVectors[[gridIndices]]]]];​​tileCornerLatticeCoordinates=Transpose[Ceiling[Dot[gridVectors,Transpose[gridLineIntersectionPoints]]+gridShifts]];​​tileCornerLatticeCoordinates[[All,gridIndices]]=Tuples[gridLineNumbers[[gridIndices]]];​​tileCornerVertices=Dot[Transpose[Transpose[tileCornerLatticeCoordinates]-gridShifts],gridVectors];​​{gridVector1,gridVector2}=gridVectors[[gridIndices]];​​tileVertices=Transpose[{tileCornerVertices,(tileCornerVertices+gridVector1),(tileCornerVertices+gridVector1+gridVector2),(tileCornerVertices+gridVector2)}];​​{EdgeForm[OptionValue["EdgeForm"]],FaceForm[tileTypeColors[[tileTypeIndex]]],Polygon[tileVertices]}​​,{tileTypeIndex,tileTypeCount}​​];​​Graphics[tileTypeGraphics,PlotRange->OptionValue[PlotRange],ImageSize->OptionValue[ImageSize]]​​]

Penrose tilings

We start with classic Penrose tiling. It is constructed using a 5-grid with offsets all set to 0.2:
In[]:=
makeMultigridTilingPlot[{.2,.2,.2,.2,.2},"EdgeForm"->Opacity[.3],"GridRange"->15,PlotRange->25,ImageSize->400]
Out[]=
Changing the grid parameters alters the tiling.
When the tiling changes it does so discretely along one or more lines or “ribbons” where an infinite row of tiles are simultaneously flipped:
In[]:=
makeMultigridTilingPlot[{.23,.21,.21,.2,.2},"EdgeForm"->Opacity[.3],"GridRange"->15,PlotRange->25,ImageSize->400]
Out[]=
Keeping all the shift values equal ensures that the tiling has rotational symmetry:
In[]:=
makeMultigridTilingPlot[ConstantArray[.25,5],"EdgeForm"->Opacity[.3],"GridRange"->15,PlotRange->25,ImageSize->400]
Out[]=
The characteristic of the tiling changes drastically as the shift values change.
In this next plot, we see 10-pointed “flowers” where 10 thin rhombuses meet at a vertex.
This vertex type is not found in the original Penrose tiling (with shift values 0.2).
In[]:=
makeMultigridTilingPlot[ConstantArray[.28,5],"EdgeForm"->Opacity[.3],"GridRange"->15,PlotRange->25,ImageSize->400]
Out[]=
At shift value 0.5, we see the 10-pointed “flower” at the center of a tiling.
Moreover, the tiling exhibits 10-fold symmetry.
Zooming out we can get a sense for the overall structure of each tiling:
The code generating these plots runs quick enough for interactive visualization:

CITE THIS NOTEBOOK

Penrose Tilings using de Bruijn's Multigrid​
by Dugan Hammock​
Wolfram Community, STAFF PICKS, August 15, 2023
​https://community.wolfram.com/groups/-/m/t/2990736