# How to generate this simulation of rotating circles in 3D?

I saw this beautiful, hypnotic set of concentric circles rotating in 3D around the origin.

I thought I could produce the same on Mathematica, but terribly failed. So far this is what I tried:

Graphics[Table[{AbsoluteThickness[5], Lighter@Hue[0.42 + 0.1 r], Circle[{0, 0}, r]}, {r, 0, 10, 0.5}], Background -> Black]


The above code produces a nice set of circles. I used RotateTransform inside Graphics3D too, but it says CircleBox is not a Graphics3D primitive. I do not know how to implement further.

Any idea or hint is appreciated.

## 1 Answer

Circles are really 2D objects, unfortunately you can't use them on Graphics3D like that.

You can start with this:

Table[
Graphics3D[
Table[{Hue[h],
Rotate[Tube@Table[h {Sin[t], 0, Cos[t]}, {t, 0, 2 Pi, Pi/50}],
u h, {0, 0, 1}]},
{h, 1/20, 1, 1/20}],
Lighting -> {{"Ambient", White}}, ViewPoint -> Front,
ViewAngle -> 30 Degree, Boxed -> False, Background -> Black],
{u, 0, 5 Pi, Pi/10}] // ListAnimate


This just creates your rings as 3D Tubes, sets lighting as intended and rotates these rings.

• +1, that is nice! I should have realised Tubes are the objects to be used, thanks. I will wait for more submissions until I accept this. – exp ikr Apr 5 '20 at 18:02
• Is it a mere coincidence that your profile pic looks very relevant for this question? – exp ikr Apr 6 '20 at 4:24
• @expikx Heh, it's purely coincidental. :) – kirma Apr 6 '20 at 6:53
• Haha, I'm just kidding :) – exp ikr Apr 6 '20 at 7:02