My code art had turned dark during the pandemic. I enjoy seeing my futuristic space stations floating in the dark.
But it is autumn now – time of soft warm colors. The soft, rounded shapes of my spherical harmonic functions would match autumnal colors perfectly!
This is my starting point: Alien structures on black.




I create the software equivalent of a doodle on a white background, and I am searching for proper colors:
For the first time, I am gradually varying the colors of the contour lines while I walk along the surface. I have picked three colors: My favorite orange and light blue, and black to add contrast.
It has not been black enough though, as I had a bug in my code. The “spherical” in “Spherical functions” means that the “radius” (distance from the origin) varies with two angles. Think of longitude and latitude. I keep one angle constant per contour and vary the other one while I traverse the loop. Mindlessly, I had varied both from 0° to 360°. That’s fine for the loopy contour. But I have been drawing over half of the contours when varying the other angle, missing half of my color palette.
The fixed-per-contour angle defines the plane whose intersection with the funny shape is the contour. You get the same plane for 180° and 360° (disregarding some sense of orientation of the normal vector of the plane that does not matter for me).
I just need to stop at 180° to see my full range of colors.
To test my fix, I resort to showing a single surface only, not nesting several of them. My virtual structure has a clear-cut edge now – which I like to my surprise.
Finally, I see all the colors I wanted!

However, I like the white background not as much as I like the black. It must be softer, less bold. It should not look like a scientific visualization on the usual default white background. Maybe it should look like yellowed paper, like an antique hand-made scientific visualization.
The function above is again a weirder combination of sine and cosine functions of “longitude” and “latitude”. I wonder, if the new color palette and the new method of coloring would make one of the boring basic functions art-worthy.
I pick a symmetrical function that looks like a pacifier or a ninepin. I like it, but I like lots of them even more … and I love creating collages!
Here finally is an invasion of spherical harmonics. But I drop the alien / science-fiction metaphors and call it: Orbital Autumn

~
All images have been created with custom JavaScript code using the threejs framework. No AI involved!
I am rotating these structures until I find a viewpoint I am satisfied with.
The multitude of ninepins is a collage created from these code-generated images with GIMP.
~



Leave a Reply