Skip to content

Instantly share code, notes, and snippets.

@99991
Created March 2, 2020 19:57
Show Gist options
  • Save 99991/4fcf3093321ebe29d73bd34cbdb707a2 to your computer and use it in GitHub Desktop.
Save 99991/4fcf3093321ebe29d73bd34cbdb707a2 to your computer and use it in GitHub Desktop.
A python code snippet to generate a hexagonal svg grid
import math
class Line:
def __init__(self, x1, y1, x2, y2):
self.x1 = x1
self.y1 = y1
self.x2 = x2
self.y2 = y2
def to_svg(self, style):
return f'<line x1="{self.x1}" y1="{self.y1}" x2="{self.x2}" y2="{self.y2}" style="{style}" vector-effect="non-scaling-stroke" />'
class Circle:
def __init__(self, x, y, radius):
self.x = x
self.y = y
self.radius = radius
def to_svg(self, style):
return f'<circle cx="{self.x}" cy="{self.y}" r="{self.radius}" style="{style}" vector-effect="non-scaling-stroke" />'
class NGon:
def __init__(self, x, y, radius, n):
self.x = x
self.y = y
self.radius = radius
self.n = n
def to_svg(self, style):
n = self.n
starting_angle = 0.5 * 2.0 * math.pi / n
points = []
for i in range(n):
angle = 2.0 * math.pi * i / n + starting_angle
x = self.x + self.radius * math.cos(angle)
y = self.y + self.radius * math.sin(angle)
points.append(f"{x},{y}")
points = " ".join(points)
return f'<polygon points="{points}" style="{style}" vector-effect="non-scaling-stroke" />'
class Ring:
def __init__(self, x, y, inner_radius, outer_radius):
self.x = x
self.y = y
self.inner_radius = inner_radius
self.outer_radius = outer_radius
def to_svg(self, style):
r0 = self.inner_radius
r1 = self.outer_radius
path = f'''
M {self.x} {self.y - r1}
A {r1} {r1} 0 1 0 {self.x} {self.y + r1}
A {r1} {r1} 0 1 0 {self.x} {self.y - r1}
Z
M {self.x} {self.y - r0}
A {r0} {r0} 0 1 1 {self.x} {self.y + r0}
A {r0} {r0} 0 1 1 {self.x} {self.y - r0}
Z
'''
path = " ".join(path.split())
return f'<path d="{path}" style="{style}" vector-effect="non-scaling-stroke" />'
def make_svg_header(width, height):
return f'''<svg version="1.1"
baseProfile="full"
width="{width}" height="{height}"
xmlns="http://www.w3.org/2000/svg">'''
def draw_walls(
filename,
walls,
nx,
ny,
padding,
scale,
stroke_width,
):
# squish vertically to make triangles equilateral
squish = math.sqrt(1 - 0.5**2)
width = (nx + 2 * padding) * scale
height = (ny + 2 * padding) * scale * squish
svg = []
svg.append(make_svg_header(width, height))
svg.append(f'<g transform="scale({scale} {scale})">')
svg.append('<g transform="translate(0.5, 0.5)">')
def draw_line(ax, ay, bx, by):
style = f'stroke: rgb(0,0,0); stroke-width: {stroke_width}'
svg.append(Line(ax, ay, bx, by).to_svg(style))
# draw horizontal lines
for y in range(ny + 1):
shift = 0.0 if y % 2 == 0 else 0.5
draw_line(shift, y * squish, shift + nx - 1, y * squish)
# draw diagonal lines which start at 0
for x2 in range(nx):
x3 = min(nx - 0.5, x2 + 0.5 * ny)
draw_line(x2, 0, x3, (x3 - x2) * 2 * squish)
x4 = max(0, x2 - 0.5 * ny)
draw_line(x2, 0, x4, (x2 - x4) * 2 * squish)
# draw diagonal lines that don't start at 0
for y2 in range(1, ny):
shift = 0.0 if y2 % 2 == 0 else 0.5
y3 = min(ny, y2 + ny)
draw_line(shift, y2 * squish, shift + 0.5 * (y3 - y2), y3 * squish)
x = shift + nx - 1
draw_line(x, y2 * squish, x - 0.5 * (y3 - y2), y3 * squish)
# draw circles at intersection points
for y in range(ny + 1):
shift = 0.0 if y % 2 == 0 else 0.5
for x in range(nx):
style = f'stroke: rgb(0,0,0); stroke-width: {stroke_width}'
svg.append(Circle(x + shift, y * squish, 0.05).to_svg(style))
# draw walls
for x, y, has_green_circle in walls:
shift = 0.0 if y % 2 == 0 else 0.5
style = f'fill:rgb(52, 174, 235); stroke:black;stroke-width: {stroke_width}'
svg.append(NGon(x + shift, y * squish, 0.5, 6).to_svg(style))
# draw green ring
if has_green_ring:
style = f'fill:rgb(3, 252, 40); stroke:black;stroke-width: {stroke_width}'
svg.append(Ring(x + shift, y * squish, 0.3, 0.5 * squish).to_svg(style))
svg.append('</g>')
svg.append('</g>')
svg.append('</svg>\n')
svg = "\n".join(svg)
with open(filename, "w") as f:
f.write(svg)
def main():
# format: (x, y, has_green_ring)
walls = [
(1, 1, True),
(2, 1, False),
(3, 1, True),
(4, 1, False),
(5, 1, True),
(6, 1, False),
(7, 2, True),
(7, 3, False),
(7, 4, True),
(6, 5, False),
(6, 6, True),
(5, 6, False),
(4, 6, True),
(3, 6, False),
(2, 6, True),
]
draw_walls(
walls=walls,
nx=10,
ny=10,
scale=60,
padding=0.5,
stroke_width=1.5,
filename="test.svg")
if __name__ == "__main__":
main()
Display the source blob
Display the rendered blob
Raw
<svg version="1.1"
baseProfile="full"
width="660.0" height="571.5767664977295"
xmlns="http://www.w3.org/2000/svg">
<g transform="scale(60 60)">
<g transform="translate(0.5, 0.5)">
<line x1="0.0" y1="0.0" x2="9.0" y2="0.0" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.5" y1="0.8660254037844386" x2="9.5" y2="0.8660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.0" y1="1.7320508075688772" x2="9.0" y2="1.7320508075688772" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.5" y1="2.598076211353316" x2="9.5" y2="2.598076211353316" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.0" y1="3.4641016151377544" x2="9.0" y2="3.4641016151377544" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.5" y1="4.330127018922193" x2="9.5" y2="4.330127018922193" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.0" y1="5.196152422706632" x2="9.0" y2="5.196152422706632" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.5" y1="6.06217782649107" x2="9.5" y2="6.06217782649107" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.0" y1="6.928203230275509" x2="9.0" y2="6.928203230275509" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.5" y1="7.794228634059947" x2="9.5" y2="7.794228634059947" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.0" y1="8.660254037844386" x2="9.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0" y1="0" x2="5.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0" y1="0" x2="0" y2="0.0" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="1" y1="0" x2="6.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="1" y1="0" x2="0" y2="1.7320508075688772" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="2" y1="0" x2="7.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="2" y1="0" x2="0" y2="3.4641016151377544" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="3" y1="0" x2="8.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="3" y1="0" x2="0" y2="5.196152422706632" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="4" y1="0" x2="9.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="4" y1="0" x2="0" y2="6.928203230275509" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="5" y1="0" x2="9.5" y2="7.794228634059947" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="5" y1="0" x2="0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="6" y1="0" x2="9.5" y2="6.06217782649107" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="6" y1="0" x2="1.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="7" y1="0" x2="9.5" y2="4.330127018922193" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="7" y1="0" x2="2.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="8" y1="0" x2="9.5" y2="2.598076211353316" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="8" y1="0" x2="3.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="9" y1="0" x2="9.5" y2="0.8660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="9" y1="0" x2="4.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.5" y1="0.8660254037844386" x2="5.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="9.5" y1="0.8660254037844386" x2="5.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.0" y1="1.7320508075688772" x2="4.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="9.0" y1="1.7320508075688772" x2="5.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.5" y1="2.598076211353316" x2="4.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="9.5" y1="2.598076211353316" x2="6.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.0" y1="3.4641016151377544" x2="3.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="9.0" y1="3.4641016151377544" x2="6.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.5" y1="4.330127018922193" x2="3.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="9.5" y1="4.330127018922193" x2="7.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.0" y1="5.196152422706632" x2="2.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="9.0" y1="5.196152422706632" x2="7.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.5" y1="6.06217782649107" x2="2.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="9.5" y1="6.06217782649107" x2="8.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.0" y1="6.928203230275509" x2="1.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="9.0" y1="6.928203230275509" x2="8.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="0.5" y1="7.794228634059947" x2="1.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<line x1="9.5" y1="7.794228634059947" x2="9.0" y2="8.660254037844386" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="0.0" cy="0.0" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="1.0" cy="0.0" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="2.0" cy="0.0" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="3.0" cy="0.0" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="4.0" cy="0.0" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="5.0" cy="0.0" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="6.0" cy="0.0" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="7.0" cy="0.0" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="8.0" cy="0.0" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="9.0" cy="0.0" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="0.5" cy="0.8660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="1.5" cy="0.8660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="2.5" cy="0.8660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="3.5" cy="0.8660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="4.5" cy="0.8660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="5.5" cy="0.8660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="6.5" cy="0.8660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="7.5" cy="0.8660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="8.5" cy="0.8660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="9.5" cy="0.8660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="0.0" cy="1.7320508075688772" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="1.0" cy="1.7320508075688772" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="2.0" cy="1.7320508075688772" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="3.0" cy="1.7320508075688772" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="4.0" cy="1.7320508075688772" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="5.0" cy="1.7320508075688772" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="6.0" cy="1.7320508075688772" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="7.0" cy="1.7320508075688772" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="8.0" cy="1.7320508075688772" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="9.0" cy="1.7320508075688772" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="0.5" cy="2.598076211353316" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="1.5" cy="2.598076211353316" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="2.5" cy="2.598076211353316" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="3.5" cy="2.598076211353316" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="4.5" cy="2.598076211353316" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="5.5" cy="2.598076211353316" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="6.5" cy="2.598076211353316" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="7.5" cy="2.598076211353316" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="8.5" cy="2.598076211353316" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="9.5" cy="2.598076211353316" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="0.0" cy="3.4641016151377544" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="1.0" cy="3.4641016151377544" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="2.0" cy="3.4641016151377544" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="3.0" cy="3.4641016151377544" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="4.0" cy="3.4641016151377544" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="5.0" cy="3.4641016151377544" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="6.0" cy="3.4641016151377544" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="7.0" cy="3.4641016151377544" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="8.0" cy="3.4641016151377544" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="9.0" cy="3.4641016151377544" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="0.5" cy="4.330127018922193" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="1.5" cy="4.330127018922193" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="2.5" cy="4.330127018922193" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="3.5" cy="4.330127018922193" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="4.5" cy="4.330127018922193" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="5.5" cy="4.330127018922193" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="6.5" cy="4.330127018922193" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="7.5" cy="4.330127018922193" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="8.5" cy="4.330127018922193" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="9.5" cy="4.330127018922193" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="0.0" cy="5.196152422706632" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="1.0" cy="5.196152422706632" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="2.0" cy="5.196152422706632" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="3.0" cy="5.196152422706632" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="4.0" cy="5.196152422706632" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="5.0" cy="5.196152422706632" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="6.0" cy="5.196152422706632" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="7.0" cy="5.196152422706632" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="8.0" cy="5.196152422706632" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="9.0" cy="5.196152422706632" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="0.5" cy="6.06217782649107" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="1.5" cy="6.06217782649107" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="2.5" cy="6.06217782649107" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="3.5" cy="6.06217782649107" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="4.5" cy="6.06217782649107" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="5.5" cy="6.06217782649107" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="6.5" cy="6.06217782649107" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="7.5" cy="6.06217782649107" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="8.5" cy="6.06217782649107" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="9.5" cy="6.06217782649107" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="0.0" cy="6.928203230275509" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="1.0" cy="6.928203230275509" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="2.0" cy="6.928203230275509" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="3.0" cy="6.928203230275509" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="4.0" cy="6.928203230275509" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="5.0" cy="6.928203230275509" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="6.0" cy="6.928203230275509" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="7.0" cy="6.928203230275509" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="8.0" cy="6.928203230275509" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="9.0" cy="6.928203230275509" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="0.5" cy="7.794228634059947" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="1.5" cy="7.794228634059947" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="2.5" cy="7.794228634059947" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="3.5" cy="7.794228634059947" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="4.5" cy="7.794228634059947" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="5.5" cy="7.794228634059947" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="6.5" cy="7.794228634059947" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="7.5" cy="7.794228634059947" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="8.5" cy="7.794228634059947" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="9.5" cy="7.794228634059947" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="0.0" cy="8.660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="1.0" cy="8.660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="2.0" cy="8.660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="3.0" cy="8.660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="4.0" cy="8.660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="5.0" cy="8.660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="6.0" cy="8.660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="7.0" cy="8.660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="8.0" cy="8.660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<circle cx="9.0" cy="8.660254037844386" r="0.05" style="stroke: rgb(0,0,0); stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<polygon points="1.9330127018922194,1.1160254037844386 1.5,1.3660254037844386 1.0669872981077808,1.1160254037844388 1.0669872981077806,0.6160254037844387 1.5,0.3660254037844386 1.9330127018922194,0.6160254037844388" style="fill:rgb(52, 174, 235); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<path d="M 1.5 0.4330127018922193 A 0.4330127018922193 0.4330127018922193 0 1 0 1.5 1.299038105676658 A 0.4330127018922193 0.4330127018922193 0 1 0 1.5 0.4330127018922193 Z M 1.5 0.5660254037844386 A 0.3 0.3 0 1 1 1.5 1.1660254037844386 A 0.3 0.3 0 1 1 1.5 0.5660254037844386 Z" style="fill:rgb(3, 252, 40); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<polygon points="2.933012701892219,1.1160254037844386 2.5,1.3660254037844386 2.066987298107781,1.1160254037844388 2.0669872981077804,0.6160254037844387 2.5,0.3660254037844386 2.9330127018922196,0.6160254037844388" style="fill:rgb(52, 174, 235); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<polygon points="3.933012701892219,1.1160254037844386 3.5,1.3660254037844386 3.066987298107781,1.1160254037844388 3.0669872981077804,0.6160254037844387 3.5,0.3660254037844386 3.9330127018922196,0.6160254037844388" style="fill:rgb(52, 174, 235); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<path d="M 3.5 0.4330127018922193 A 0.4330127018922193 0.4330127018922193 0 1 0 3.5 1.299038105676658 A 0.4330127018922193 0.4330127018922193 0 1 0 3.5 0.4330127018922193 Z M 3.5 0.5660254037844386 A 0.3 0.3 0 1 1 3.5 1.1660254037844386 A 0.3 0.3 0 1 1 3.5 0.5660254037844386 Z" style="fill:rgb(3, 252, 40); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<polygon points="4.93301270189222,1.1160254037844386 4.5,1.3660254037844386 4.06698729810778,1.1160254037844388 4.06698729810778,0.6160254037844387 4.5,0.3660254037844386 4.93301270189222,0.6160254037844388" style="fill:rgb(52, 174, 235); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<polygon points="5.93301270189222,1.1160254037844386 5.5,1.3660254037844386 5.06698729810778,1.1160254037844388 5.06698729810778,0.6160254037844387 5.5,0.3660254037844386 5.93301270189222,0.6160254037844388" style="fill:rgb(52, 174, 235); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<path d="M 5.5 0.4330127018922193 A 0.4330127018922193 0.4330127018922193 0 1 0 5.5 1.299038105676658 A 0.4330127018922193 0.4330127018922193 0 1 0 5.5 0.4330127018922193 Z M 5.5 0.5660254037844386 A 0.3 0.3 0 1 1 5.5 1.1660254037844386 A 0.3 0.3 0 1 1 5.5 0.5660254037844386 Z" style="fill:rgb(3, 252, 40); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<polygon points="6.93301270189222,1.1160254037844386 6.5,1.3660254037844386 6.06698729810778,1.1160254037844388 6.06698729810778,0.6160254037844387 6.5,0.3660254037844386 6.93301270189222,0.6160254037844388" style="fill:rgb(52, 174, 235); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<polygon points="7.43301270189222,1.9820508075688772 7.0,2.232050807568877 6.56698729810778,1.9820508075688774 6.56698729810778,1.4820508075688774 7.0,1.2320508075688772 7.43301270189222,1.4820508075688774" style="fill:rgb(52, 174, 235); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<path d="M 7.0 1.299038105676658 A 0.4330127018922193 0.4330127018922193 0 1 0 7.0 2.1650635094610964 A 0.4330127018922193 0.4330127018922193 0 1 0 7.0 1.299038105676658 Z M 7.0 1.4320508075688771 A 0.3 0.3 0 1 1 7.0 2.032050807568877 A 0.3 0.3 0 1 1 7.0 1.4320508075688771 Z" style="fill:rgb(3, 252, 40); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<polygon points="7.93301270189222,2.848076211353316 7.5,3.098076211353316 7.06698729810778,2.848076211353316 7.06698729810778,2.348076211353316 7.5,2.098076211353316 7.93301270189222,2.348076211353316" style="fill:rgb(52, 174, 235); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<polygon points="7.43301270189222,3.7141016151377544 7.0,3.9641016151377544 6.56698729810778,3.7141016151377544 6.56698729810778,3.2141016151377544 7.0,2.9641016151377544 7.43301270189222,3.2141016151377544" style="fill:rgb(52, 174, 235); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<path d="M 7.0 3.031088913245535 A 0.4330127018922193 0.4330127018922193 0 1 0 7.0 3.8971143170299736 A 0.4330127018922193 0.4330127018922193 0 1 0 7.0 3.031088913245535 Z M 7.0 3.1641016151377546 A 0.3 0.3 0 1 1 7.0 3.764101615137754 A 0.3 0.3 0 1 1 7.0 3.1641016151377546 Z" style="fill:rgb(3, 252, 40); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<polygon points="6.93301270189222,4.580127018922193 6.5,4.830127018922193 6.06698729810778,4.580127018922193 6.06698729810778,4.080127018922193 6.5,3.8301270189221928 6.93301270189222,4.080127018922193" style="fill:rgb(52, 174, 235); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<polygon points="6.43301270189222,5.446152422706632 6.0,5.696152422706632 5.56698729810778,5.446152422706632 5.56698729810778,4.946152422706632 6.0,4.696152422706632 6.43301270189222,4.946152422706632" style="fill:rgb(52, 174, 235); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<path d="M 6.0 4.763139720814412 A 0.4330127018922193 0.4330127018922193 0 1 0 6.0 5.629165124598852 A 0.4330127018922193 0.4330127018922193 0 1 0 6.0 4.763139720814412 Z M 6.0 4.896152422706632 A 0.3 0.3 0 1 1 6.0 5.496152422706632 A 0.3 0.3 0 1 1 6.0 4.896152422706632 Z" style="fill:rgb(3, 252, 40); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<polygon points="5.43301270189222,5.446152422706632 5.0,5.696152422706632 4.56698729810778,5.446152422706632 4.56698729810778,4.946152422706632 5.0,4.696152422706632 5.43301270189222,4.946152422706632" style="fill:rgb(52, 174, 235); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<polygon points="4.43301270189222,5.446152422706632 4.0,5.696152422706632 3.566987298107781,5.446152422706632 3.5669872981077804,4.946152422706632 4.0,4.696152422706632 4.43301270189222,4.946152422706632" style="fill:rgb(52, 174, 235); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<path d="M 4.0 4.763139720814412 A 0.4330127018922193 0.4330127018922193 0 1 0 4.0 5.629165124598852 A 0.4330127018922193 0.4330127018922193 0 1 0 4.0 4.763139720814412 Z M 4.0 4.896152422706632 A 0.3 0.3 0 1 1 4.0 5.496152422706632 A 0.3 0.3 0 1 1 4.0 4.896152422706632 Z" style="fill:rgb(3, 252, 40); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<polygon points="3.433012701892219,5.446152422706632 3.0,5.696152422706632 2.566987298107781,5.446152422706632 2.5669872981077804,4.946152422706632 3.0,4.696152422706632 3.4330127018922196,4.946152422706632" style="fill:rgb(52, 174, 235); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<polygon points="2.433012701892219,5.446152422706632 2.0,5.696152422706632 1.5669872981077808,5.446152422706632 1.5669872981077806,4.946152422706632 2.0,4.696152422706632 2.4330127018922196,4.946152422706632" style="fill:rgb(52, 174, 235); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
<path d="M 2.0 4.763139720814412 A 0.4330127018922193 0.4330127018922193 0 1 0 2.0 5.629165124598852 A 0.4330127018922193 0.4330127018922193 0 1 0 2.0 4.763139720814412 Z M 2.0 4.896152422706632 A 0.3 0.3 0 1 1 2.0 5.496152422706632 A 0.3 0.3 0 1 1 2.0 4.896152422706632 Z" style="fill:rgb(3, 252, 40); stroke:black;stroke-width: 1.5" vector-effect="non-scaling-stroke" />
</g>
</g>
</svg>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment