Another edition of oddly aesthetic debug output (this time for a graph drawing package using geometric algebra)…

This is the #Clojure code that generated this sample diagram:

(->> (repeatedly 90 #(* (rand-int 6) (/ tau 6)))
(reductions #(+ (vga2d/rotate (e 1) %2) %1) zero)
(partition 2 1))

Clojure's standard library is quite good, and a little sprinkle of geometric algebra makes working with vectors a very pleasant and matrix-free experience. 🙂

@jack hope I’ve got this right.

svg {
viewBox: -100 -100 200 200;
path {
fill: none;
stroke: black;
stroke-linejoin: round;
d: m 50 -50 @M90.p.Plot(
points: 2;
r: 10;
rotate: $(@ri5 * 60)
)
}
}

@yuanchuan @jack what language is that?
An Introduction to css-doodle

This is a rough transcript based on my notes for the sharing session I presented at the online Groove meetup in June. I've shared the slides before, but I think it's worth putting the content in writing. The full slide deck is accessible on GitHub.