Você está na página 1de 8

Create torus with ALL surface polygons squares in 3Dsmax

I want to learn to draw a spiral spline on the surface of various tori shapes. The tori will have different
parameters. Most of the time r1=2r2, but there will be deviations from this start-up rule. For
instance r1=2r2+g, where g is a variable tiny in comparison to r1 or r2.

http://i.imgur.com/GPRQ0ze.jpg

Torus parameters

The spiral must have its tangent at a constant angle in respect with local tori surface coordinates, like
this:
45 and 60 tori

http://i.imgur.com/zO4U8nq.jpg

My plan is to use the vertexes on the tori surface as aids or guides to manually draw the
spiral/spline/line Im after (with vertex snaps toggle on) like this:
Create spiral

http://i.imgur.com/B54ppT8.jpg

-Hold on a second there. Thats why you need all these squares on the torus surface?

-Yes.

-Hold on a second. Why do you go to so much trouble, when you could just find other straight forward
ways to draw these spirals? I mean, if this 3D spiral is your final goal, then why build the torus in the first
place? Why dont you play for instance with the torus knot? (From extended primitives)

-Because I want the spirals to always lay, at a precise angle, on the surface of a particular torus Im pre-
setting. I also need the torus for other purposes.

Obviously the more squares on the torus surface, the higher the torus resolution (Im begging all of
you to forgive the sloppy terminology), the more accurate the spline will be to my specifications. Or the
more rectangles on the torus surface, the better the spiral will be shaped/curved AT the angle Im
setting. I lazy to do the math, and since its tricky, here I am on this forum, with the belief that maybe,
there is someone out-there kind enough to enlighten me with a simpler solution.

-A simpler solution compared to what?

-Compared to my approach which is to manually calculate in excel the poloidal angles required to make
perfect squares on the torus surface. We all know the conventional poloidal and toroidal directions:
http://i.imgur.com/HwXyEQX.jpg

https://en.wikipedia.org/wiki/Toroidal_and_poloidal

Lets name these poloidal angles with Greek letter alpha ()


Poloidal angles.

http://i.imgur.com/NA8T0y7.png

What it needs to happen is the yellow segment must equal in size with the red segment.
Calculation1

http://i.imgur.com/GhzbSrY.png

This can easily be written mathematically like this:

The yellow segment length is:


( )
=

Meaning r1-r2 is the radius of the inner hole of the torus, and we divide by the total number of
segments of the torus, to find the length of our yellow segment. Straight forward.

The red segment is based on circle arc length formula:



=

So we make the two equations equal and we get:



Thus:
( )
=

The trick comes when we have to find the next poloidal angles like 12, 3 and so on. We cant use the
same (r1-r2) radius. This radius has changed. Look:
Calculation2.png

http://i.imgur.com/px9wMRE.jpg

In order to make the next yellow segment equal with the red one, the radius to calculate the yellow
segment length has changed. It is: ( r1-BC ). Where BC is the segment BC in the right angle triangle ABC.
We apply a cosine of 1 and we get: cos (1)=BC/AB . Since AB is r2 we have: BC=r2*cos(1).

Then we can calculate second level yellow segment like this:


( ( ))
=

Then we write the math for the second level red segment like this:

=

Again we make the two equations equal each other and we get:
1 2 cos(1 ) 2 2
=
360
Thus:
( ( ))
=

When we go to third level, we find that each poloidal angle is a function of the previous ones
(obviously), so based on that pattern, our formula becomes:

( (
= )
=

As you all can see, the math is indeed tricky which justifies why I was so lazy in the first place to do it.

If there were a mistake in these calculations, then I wouldnt have been able to create the tori Im after
in all the pictures above.

As I said in my previous replies, this can go on to a certain point, until the sum of all the poloidal angles
calculated reach 180 degrees. The rest doesnt matter, and since we have equatorial symmetry, we just
mirror the entire upper torus below the home grid (equatorial plane of the torus).

At first glance we might be tempted to say that we can never find a configuration/sum of poloidal angles
to match perfectly 180 degrees, but this is not necessary true. Its just a matter of pre-setting the right
torus in the first place. A certain torus parameters can result in a perfect configuration of poloidal angles
where their sum match exactly 180 degrees. This is what I was actually trying to say.
To make the a certain rectangle everywhere on the entire torus surface, the same, we use the same final
formula above, but with a certain factor at the nominator. To make a toroidal spiral at a 60 degree
angle, each rectangle must be made from two 30-60-90 degrees triangles. Thus the sides of the
rectangle are in a sqrt(3) ratio.

Você também pode gostar