# Mathober2025_Octagonal-Heptagonal

# OctoVsHepta

For my 8th sketch of **Mathober2025** coded in **LiveCodeLab**, **OctoVsHepta** takes the prompt of ***“Octagonal/Heptagonal”*** and showcases side by side, a figure that has 8 sides and another that has 7 sides and how they slightly differ.

## Poetry

```javascript
Octagonal with slightly more
Heptagonal with slightly less
Similar in the creation process
But differences can be seen as the time soars
```

## Images

![](https://cdn.hashnode.com/res/hashnode/image/upload/v1759939992715/ac04d77e-4d87-4a35-b67a-8558035de182.jpeg align="center")

![](https://cdn.hashnode.com/res/hashnode/image/upload/v1759939996048/70655ff2-3d0b-4ea3-9236-d0ba8b4570d4.jpeg align="center")

![](https://cdn.hashnode.com/res/hashnode/image/upload/v1759939999898/904e0f57-302e-46f9-8c63-4968b173a590.jpeg align="center")

![](https://cdn.hashnode.com/res/hashnode/image/upload/v1759940003256/844df83a-a177-4764-a821-50d23a04e759.jpeg align="center")

## Code

```javascript
//Octagonal
pushMatrix()
move -1.5,0
8 times with i
	rotate sin(time % i),Math.hypot(time %6, cos(time)*5)/10,wave(Math.hypot(sin(time),cos(time)))/10
	if time % 30 > 15
		rect i/(time % 10 + 1)
	else
		line i/(time % 10 + 1)
popMatrix()


//Heptagonal
pushMatrix()
scale 0.5
move 1.5,0,5
7 times with i
	rotate sin(time %i),Math.hypot(time %6, cos(time)*5)/10,wave(Math.hypot(sin(time),cos(time)))/10
	if time % 30 > 15
		rect i/(time % 10 + 1)
	else
		line i/(time % 10 + 1)
popMatrix()
```
