Wolfram Function Repository
Instant-use add-on functions for the Wolfram Language
Function Repository Resource:
Generate a graph corresponding to a hexagonal grid
ResourceFunction["HexagonalGridGraph"][{width,height}] returns a hexagonal grid graph with dimensions width×height. |
A 6×6 hexagonal grid graph:
| In[1]:= |
| Out[1]= | ![]() |
Use a different graph embedding:
| In[2]:= |
| Out[2]= | ![]() |
Use a different plot theme:
| In[3]:= |
| Out[3]= | ![]() |
Large graphs may be formatted differently in OutputForm than smaller graphs. A 50×60 hexagonal grid graph shows explicit edges and vertices:
| In[4]:= |
| Out[4]= | ![]() |
A 60×60 hexagonal grid graph displays as an elided Graph expression:
| In[5]:= |
| Out[5]= |
This work is licensed under a Creative Commons Attribution 4.0 International License