Calculate the rotation in degrees of a rectangle on its axis to form a cylinder of said rectangles

circlesratio

Im working with rectangles in 3D space that rotate by degrees around an origin of its parent object.

I want to calculate how to make a perfect Cylinder / Circle from r radius. Essentially I want to be able to generate the correct rectangle width, count and degree of rotation for a circle with a specific radius / diameter.

For example, I can create a circle for this 3D shape out of rectangular pieces with each piece being of the rotation 22.5 degrees.

enter image description here

Each "rectangle" is a voxel, so each must conform to being a whole number in width and height

such as 1 x 2 or 4 x 8

Is there a simple way to calculate the perfect width I would need each rectangle to be, and how many degrees to rotate each one with a formula?

The only thing I want to be able to define is the circle's radius. Nothing else, as that should be procedurally created by my input radius.

The issue is, I don't have a lot of experience in math, so I have no idea how to do what I want.

To Clarify: Each rectangle inherits the transform of the one behind it. So if I rotate the first rectangle 22.5 degrees, all children will be rotated 22.5 degrees plus their own transforms.

PS, incase someone needs to create a formula reversed / based off of my example given:
The radius of the circle in the image is 5 voxels / 5 units, and it's diameter is 10 voxels.
Each piece of the circle is rotated 22.5 degrees exactly. Each of those rectangles are 2 units / voxels wide.

To simplify everything above: I essentially need to be able to generate the exact voxel width / count and degree of rotation for each one based off of one number: The circle's radius / diameter… Is this possible?

Best Answer

If I understood correctly, in order to get a 16 sided polygon ( not a circle) you need 16 trapeziums of vertex angle $22.5^{\circ}$( not rectangles) arranged end to end.

Vertex angle 2π/n is required for n vertices/corners.