this post was submitted on 07 May 2025
17 points (90.5% liked)

Generative Art

135 readers
1 users here now

"Generative art" often refers to algorithmic art (algorithmically determined computer generated artwork).

founded 2 years ago
MODERATORS
 

6 hexagons are red, one blue, arranged in a honeycomb pattern, where 1 hexagon is surrounded by 6 others

Did you know a Hexagon can be constructed using the angle pi/3 a lot of times? This is because a hexagon is made of 6 triangles with equal side length - the radius of the hexagon. The inner angles of these triangles is pi/3. Using this information and the trigonometric functions sin and cos can be used to draw such a picture.

top 19 comments
sorted by: hot top controversial new old
[–] originalucifer@moist.catsweat.com 7 points 3 weeks ago (1 children)

i remember doin something like this with an apple turtle/logo in 1984

livin in the future!

[–] glowing_hans@sopuli.xyz 2 points 3 weeks ago* (last edited 3 weeks ago) (1 children)

what is apple turtle/logo? some turtle program one could code to draw image? would be interested to hear more.

[–] DemBoSain@midwest.social 3 points 3 weeks ago

There was a programming language in the old old Apple computers called Logo. It was basically a drawing program language. You had control of a 'cursor' called a turtle, and you would give it commands like "forward 5, left 90, forward 5, left 90..." and it would draw shapes. I'm sure there's a wiki for it is you want more info.

[–] LordKitsuna@lemmy.world 4 points 3 weeks ago* (last edited 3 weeks ago)

I'm going to work off the assumption that they were supposed to all be red but one of them refuses to not be blue and we are just pretending that's a feature now

[–] over_clox@lemmy.world 3 points 3 weeks ago (1 children)

Did you know that 355/113 is an extremely close approximation of π? It's accurate to the first 6 decimal places.

That's accurate enough for most everyday uses except the most demanding scientific and engineering purposes.

[–] glowing_hans@sopuli.xyz 0 points 3 weeks ago (3 children)

Why should i use that instead of math.pi?

[–] Reddfugee42@lemmy.world 2 points 3 weeks ago

I missed the comment that said you should. Did they delete it?

[–] over_clox@lemmy.world 1 points 3 weeks ago

You're right. But as the other commenter suggested, if you're on an embedded system or otherwise limited system, or even using another language missing certain constants and/or functions, it's a good thing to know.

You could also just pull the constant from memory, assuming you have the brain memory space that I apparently have...

3.1415926535897932384646233832795020841971693993751

[–] riskable@programming.dev 1 points 3 weeks ago

If you're using an embedded version of Python that's missing the math module. Because somebody couldn't be bothered to fix the floating point math in C for platforms that don't have an FPU 🤷

[–] redlemace@lemmy.world 2 points 3 weeks ago (2 children)

How do my bees know all that??

[–] glowing_hans@sopuli.xyz 1 points 3 weeks ago* (last edited 3 weeks ago)

Ultra High Bee IQ/s???

[–] funkless_eck@sh.itjust.works 1 points 3 weeks ago (1 children)

non joke answer: the bee is compelled to build wax, wax takes a comparative large amount of effort and calories to produce, so they evolved to use a shape that requires the least effort and takes the most space. It could've been squares, but squares are harder to form and less compact, so it's likely they started with blobs/circles, and over millions of years, more closely, densely packed hives survived where others didn't until they ended up at the idea shape of a hexagon.

[–] redlemace@lemmy.world 1 points 3 weeks ago

I know, and you're right. It's space efficiency and strength. Hexagon is much stronger than squares.

[–] Trex202@lemmy.world 2 points 3 weeks ago (2 children)
[–] klemptor@startrek.website 3 points 3 weeks ago (1 children)

I only see 3 that are fully red

[–] glowing_hans@sopuli.xyz 2 points 2 weeks ago (1 children)

May I ask how many hexagons you see in total? Do you count the partial ones in an extra category? Fully red, partially red and fully blue? I see 7 in total.

[–] klemptor@startrek.website 1 points 2 weeks ago

7 total: 1 pure blue, 3 pure red, 3 mostly red with a blue edge

[–] glowing_hans@sopuli.xyz 1 points 2 weeks ago* (last edited 2 weeks ago)

interesting point. My program draws 6 red hexagons, and in the one a blue one "overdraws" the others at the border.

[–] glowing_hans@sopuli.xyz 1 points 2 weeks ago

hexagon = bestagon