Animations of 4D torii cross-sections

Discussion of shapes with curves and holes in various dimensions.

Animations of 4D torii cross-sections

Postby Plasmath » Thu Feb 11, 2021 12:29 am

I made some animations of cross-sections of the 4D torii (and the torinder) that were based on some of the renders by Polyhedron Dude.
Last edited by Plasmath on Sun Feb 14, 2021 12:36 pm, edited 1 time in total.
Plasmath
Dionian
 
Posts: 35
Joined: Mon Feb 08, 2021 10:57 pm

Re: Animations of 4D torii cross-sections

Postby Plasmath » Thu Feb 11, 2021 1:20 pm

Okay, so I've been able to get some higher-quality images from using external links.

Tiger
Image

Ditorus
Image

Image

Image

Torisphere
Image

Image

Spheritorus
Image

Image

Torinder
Note: the first cross-section is just a boring torus for the entire time because it is a prism, however the other two look pretty neat:
Image

Image

I hope this makes it easier to visualize the 4D torii, although I haven't figured out how to make oblique cross-sections yet.
Plasmath
Dionian
 
Posts: 35
Joined: Mon Feb 08, 2021 10:57 pm

Re: Animations of 4D torii cross-sections

Postby Plasmath » Sat Feb 13, 2021 1:51 am

Okay, so I've made some oblique cross-sections of all the 4D torii (all at a 45° angle), and although the tiger looks the best, I still think that the others look pretty cool.

Tiger
Image


Here's a slower version of the animation, there's a lot going on.
Image

Ditorus
Image

Image

Spheritorus
Image

Image

Torisphere
I didn't find much of anything interesting when exploring the torisphere. I might look at it in further detail later, but it takes a really long time to poke through the cross-sections.

Torinder
Image

Image
Plasmath
Dionian
 
Posts: 35
Joined: Mon Feb 08, 2021 10:57 pm

Re: Animations of 4D torii cross-sections

Postby Marek14 » Sun Feb 14, 2021 12:14 am

Look nice -- but I think the speed is set too high. They should change, say, 2-3 times slower.
Marek14
Pentonian
 
Posts: 1191
Joined: Sat Jul 16, 2005 6:40 pm

Re: Animations of 4D torii cross-sections

Postby Marek14 » Sun Feb 14, 2021 12:43 pm

I know that there are also some interesting rotation animations (between two mid-sections), in 4D and higher.

The interesting ones should be:

Torisphere ((xyz)w): xyz/xyw, two concentric spheres vs. torus, with two concentric circles in xy fixed through the rotation.
Spheritorus ((xy)zw): xyz/xzw, torus vs. two spheres, with two circles in xz fixed through the rotation.
Tiger ((xy)(zw)): xyz/xzw, stack of two torii vs. stack of two torii in different orientation, with 2x2 circles in xz fixed through the rotation.

Ditorus (((xy)z)w):
1) xyz/xyw: two cocircular torii vs. two concentric torii, with four concentric circles in xy fixed through the rotation.
2) xyz/xzw: two cocircular torii vs. two torii, with two pairs of concentric circles in xz fixed through the rotation.
3) xyw/xzw: two concentric torii vs. two torii, with four circles in xw fixed through the rotation.
Marek14
Pentonian
 
Posts: 1191
Joined: Sat Jul 16, 2005 6:40 pm

Re: Animations of 4D torii cross-sections

Postby Plasmath » Mon Feb 15, 2021 6:29 pm

Here are some rotations of the torii:

Tiger ((xy)(zw)): xyz/xzw, stack of two torii vs. stack of two torii in different orientation, with 2x2 circles in xz fixed through the rotation.

Image

Spheritorus ((xy)zw): xyz/xzw, torus vs. two spheres, with two circles in xz fixed through the rotation.

Image

Torisphere ((xyz)w): xyz/xyw, two concentric spheres vs. torus, with two concentric circles in xy fixed through the rotation.

Image

Ditorus (((xy)z)w):

Image

Image

I couldn't find the final rotation.

Here's also some rotations of the torinder:
Image

Image
Plasmath
Dionian
 
Posts: 35
Joined: Mon Feb 08, 2021 10:57 pm

Re: Animations of 4D torii cross-sections

Postby Marek14 » Mon Feb 15, 2021 11:09 pm

The final one is between two concentric torii and two cocircular torii. Each of them occurs in one of your animations.
Marek14
Pentonian
 
Posts: 1191
Joined: Sat Jul 16, 2005 6:40 pm

Re: Animations of 4D torii cross-sections

Postby icebreaker » Fri Feb 19, 2021 7:49 pm

The animations look very good, visually. But I wouldn't show them to a novice in 4D. I agree with Maker14, time period should be increased. As for the tiger animation, its 'flashing' texture prevents from seeing its very interesting structure, especially for the untrained viewer. If you want to leave stripped texture, it might be well to make colors not so contrast. Also, it's easily to mix up ditorus with spheritorus because of speed and especially lack of transparency. The same problem is visible in torisphere (looks like a glome).

Thank you, didn't see Torinder cross-secitons before. It's a pleasure. How did you get so clear edges? I'm interested what software are you using.
icebreaker
Dionian
 
Posts: 57
Joined: Thu Sep 14, 2017 8:07 am
Location: Omsk, Russian Federation (UTC+6)

Re: Animations of 4D torii cross-sections

Postby Plasmath » Sat Feb 20, 2021 2:09 am

I used POV-Ray for the animations, it has the max function implemented so that's how I made the edges.

I could definitely make the tiger less flashy, although making animations longer or transparent would be more difficult because both would make rendering take a much longer time, but I could try to do that.
Plasmath
Dionian
 
Posts: 35
Joined: Mon Feb 08, 2021 10:57 pm

Re: Animations of 4D torii cross-sections

Postby ICN5D » Thu Mar 18, 2021 9:09 pm

These are great! You might be able to slow down the animations by opening them in a gif maker, like gifmoviegear. Then, select all the frames and set a longer duration to them (in seconds, like 0.1 s). Hopefully the program doesn't mess up the colors, because it might (it could downgrade the color spectrum). I don't use povray, so I don't know how to make the transparent surfaces (other than using calcplot). I'm sure some of the adobe programs could modify the timescale, but those will cost $$$ monthly to license one.
It is by will alone, I set my donuts in motion
ICN5D
Pentonian
 
Posts: 1135
Joined: Mon Jul 28, 2008 4:25 am
Location: the Land of Flowers

Re: Animations of 4D torii cross-sections

Postby Plasmath » Sat Apr 03, 2021 2:18 am

Okay, this took much longer than I expected, but I've finally re-rendered everything, now with 91 frames in each because just slowing the frames down looked really bad. I think I made some mistakes before and also forgot some sections before, but I've added them here.

I also made some of these transparent, and the tiger a bit less flashy.

Tiger
Orthogonal cross-sections
Image

Oblique cross-sections
Image

Rotations
Image

Ditorus
Orthogonal cross-sections
Image
Image
Image

Oblique cross-section
Image
Image
Image

Rotations
Image
Image
Image

Spheritorus
Orthogonal cross-sections
Image
Image

Oblique cross-sections
Image

Rotations
Image

Torisphere
Orthogonal cross-sections
Image
Image

Oblique cross-sections
Image

Rotations
Image

Torinder
Orthogonal cross-sections
Image
Image

Oblique cross-sections
Image
Image
Image

Rotations
Image
Image
Image
Last edited by Plasmath on Sat Apr 03, 2021 9:26 pm, edited 1 time in total.
Plasmath
Dionian
 
Posts: 35
Joined: Mon Feb 08, 2021 10:57 pm

Re: Animations of 4D torii cross-sections

Postby ICN5D » Sat Apr 03, 2021 2:06 pm

Torisphere definitely has some neat looking oblique slices! Especially when getting close to the concentric spheres slice, between the 67.5 deg and 90 deg angles.

Image
It is by will alone, I set my donuts in motion
ICN5D
Pentonian
 
Posts: 1135
Joined: Mon Jul 28, 2008 4:25 am
Location: the Land of Flowers

Re: Animations of 4D torii cross-sections

Postby Plasmath » Sat Apr 03, 2021 9:26 pm

Okay, I think I just forgot to render the oblique sections of the torisphere. I'll edit the post so that it includes that.
Plasmath
Dionian
 
Posts: 35
Joined: Mon Feb 08, 2021 10:57 pm

Re: Animations of 4D torii cross-sections

Postby icebreaker » Sun Apr 04, 2021 5:55 am

Plasmath wrote:Okay, this took much longer than I expected, but I've finally re-rendered everything, now with 91 frames in each because just slowing the frames down looked really bad. I think I made some mistakes before and also forgot some sections before, but I've added them here.

I also made some of these transparent, and the tiger a bit less flashy.

...


I think it was worth it! Look so smooth that I would like to touch these, if could. And they have become more informative, too.
icebreaker
Dionian
 
Posts: 57
Joined: Thu Sep 14, 2017 8:07 am
Location: Omsk, Russian Federation (UTC+6)

Re: Animations of 4D torii cross-sections

Postby ICN5D » Mon May 03, 2021 6:07 pm

Hey Plasmath, would you mind sharing the code you use in POVray? I'm looking for a better program to make slice animations, and I like what I see here.

Also, how exactly do you make the animation? Is that part of the script, too? Or a separate program?

You can use the "[code][/code]" tag to copy-paste as it is.
It is by will alone, I set my donuts in motion
ICN5D
Pentonian
 
Posts: 1135
Joined: Mon Jul 28, 2008 4:25 am
Location: the Land of Flowers

Re: Animations of 4D torii cross-sections

Postby Plasmath » Tue May 04, 2021 12:41 am

Here's the code (this shows a spheritorus at an oblique cross-section, but it can be pretty easily altered to anything else):
Code: Select all
#include "colors.inc"
#include "metals.inc"

camera {
location <4,0,4>
look_at <0,0,0>
right x*image_width/image_height
}
     
light_source {
<5,4,3>
color  White

}     

#declare q = pi/4; 
#declare F = function { sqrt(pow(x,2)+pow(y,2)) }
#declare T = function { abs(x)-1 }

sky_sphere{                   
    pigment{
        gradient x
        color_map {
        [0 rgb <0.2,0.3,0.9>]                                                                             
        [0.5 color <0.1,0.2,0.5>]
        [0.75 color <0.5,0.5,0.9>]
        [1 rgb <0.2,0.3,0.9>]
        }
    }
}

#declare Reddiclear = color rgb <0.9, 0.3, 0.1>;

isosurface {
  function { F(T(F(F(clock*cos(q)-x*sin(q),clock*sin(q)+x*cos(q),0),y,0),0,0),z,0)-0.5 }
  max_gradient 4                                                               
  contained_by{ box { -5 , 5 } }
  pigment { Reddiclear }
  finish {     
        ambient .5
        diffuse .1
        specular .4
        roughness .3
        reflection {
           .2
        }
     }
}

This is a lot of.. stuff, so I'll explain it.
First, to make it a gif i use a .ini file that looks like this:
Code: Select all
+W1920
+H1080
Input_File_Name=robot.pov
Initial_Frame=0
Final_Frame=90
Initial_Clock=-1.25
Final_Clock=1.25

This is what the clock variable is, and it outputs an image for each value. I then run it through a website that turns it into a gif.
Code: Select all
#declare F = function { sqrt(pow(x,2)+pow(y,2)) }
#declare T = function { abs(x)-1 }

These functions define the two operators needed to create the equation for the isosurface of any torus. You could also just use something saying (some equation)=0 and it will work, with the clock variable being a replacement for the w axis.
Code: Select all
#declare Reddiclear = color rgb <0.9, 0.3, 0.1>;

This just defines the color.
Code: Select all
sky_sphere{                   
    pigment{
        gradient x
        color_map {
        [0 rgb <0.2,0.3,0.9>]                                                                             
        [0.5 color <0.1,0.2,0.5>]
        [0.75 color <0.5,0.5,0.9>]
        [1 rgb <0.2,0.3,0.9>]
        }
    }
}

Defines what the background looks like.
Code: Select all
#declare q = pi/4;

This will define the rotation in radians. The cosines and sines in the isosurface equation use this to rotate along some axis. Setting q to equal the clock makes it rotate.
Code: Select all
isosurface {
  function { F(T(F(F(clock*cos(q)-x*sin(q),clock*sin(q)+x*cos(q),0),y,0),0,0),z,0)-0.5 }
  max_gradient 4                                                               
  contained_by{ box { -5 , 5 } }
  pigment { Reddiclear }
  finish {     
        ambient .5
        diffuse .1
        specular .4
        roughness .3
        reflection {
           .2
        }
     }
}

Finally, the isosurface equation. It has the function saying that
Code: Select all
F(T(F(F(clock*cos(q)-x*sin(q),clock*sin(q)+x*cos(q),0),y,0),0,0),z,0)-0.5
is equal to 0, and finds all the solutions for that. Contained_by means that this is the range of numbers it will check, and the finish part just defines some reflection and other raycasting things.

Hope this helps!
Plasmath
Dionian
 
Posts: 35
Joined: Mon Feb 08, 2021 10:57 pm

Re: Animations of 4D torii cross-sections

Postby ICN5D » Tue May 04, 2021 2:16 am

Totally awesome, dude! I've been googling povray stuff all day, just downloaded it. It's one sophisticated program that can do many amazing things. But that code is all mandarin chinese to me. It makes a little bit of sense, I guess. I've been playing with calcplot for 8 years, and it has served its purpose. I could really use some more options though, like background and surface material, and automating the screen capture process has always been a dream of mine. I can still use it to set up my scenes ahead of time, then make the povray version.

Also, what is that website that makes the animations? I've seen people recommending either FFmpeg or videomach. And you just use a separate .ini for the animation script? You don't add it into the whole thing? I have no idea how to use this program, as you can tell...
It is by will alone, I set my donuts in motion
ICN5D
Pentonian
 
Posts: 1135
Joined: Mon Jul 28, 2008 4:25 am
Location: the Land of Flowers

Re: Animations of 4D torii cross-sections

Postby Plasmath » Tue May 04, 2021 2:24 am

Also, what is that website that makes the animations? I've seen people recommending either FFmpeg or videomach.

I use https://gifmaker.me/.
And you just use a separate .ini for the animation script? You don't add it into the whole thing?

Yep, it's a separate file. In the POV-Ray folder there is a folder called 'ini'. In it there are .ini files, and I basically just copy-pasted the code from the POV-Ray wiki. You can set it to render using the ini by just clicking the 'ini' button, which will generate a whole bunch of images you can stitch together.
Plasmath
Dionian
 
Posts: 35
Joined: Mon Feb 08, 2021 10:57 pm

Re: Animations of 4D torii cross-sections

Postby ICN5D » Wed May 05, 2021 3:38 am

Can you show me some more of these equations you use? How do they work? I thought I could just use

pow((sqrt(pow(x,2) + pow(y,2)) -2),2) + pow(z,2) -1

for the torus, but it won't plot anything. I found all of the polynomial function stuff (the vector tables) on the povwiki, but that becomes very difficult with degree-8 surfaces of a 4D toratope. And next to impossible for degree-16 surfaces in 5D. And you can just forget about deg-32 in 6D. But it looks like you've discovered a workaround, which is magic to me right now.
It is by will alone, I set my donuts in motion
ICN5D
Pentonian
 
Posts: 1135
Joined: Mon Jul 28, 2008 4:25 am
Location: the Land of Flowers

Re: Animations of 4D torii cross-sections

Postby Plasmath » Wed May 12, 2021 11:17 pm

Sorry it took so long to reply, but I finally figured it out!
You have to turn the max gradient up. Here's what I got when I increased the value to 7 using your equation:
answer.png
answer.png (278.94 KiB) Viewed 13496 times

Hope this helps!
Plasmath
Dionian
 
Posts: 35
Joined: Mon Feb 08, 2021 10:57 pm

Re: Animations of 4D torii cross-sections

Postby ICN5D » Thu May 13, 2021 10:21 pm

Whoa, so it DOES ACTUALLY WORK?? No kidding. Dude, if this is the case, then every single one of the nastiest possible toratopes can be plotted in POVray. This enhances my ability to create music videos immensely. Thanks for the help big time. I have a lot of things to experiment with now.

By the way, check out this program. It's a very good gif maker (I've used it for years) : GIF Movie Gear .

Also, check your private messages.
It is by will alone, I set my donuts in motion
ICN5D
Pentonian
 
Posts: 1135
Joined: Mon Jul 28, 2008 4:25 am
Location: the Land of Flowers

Re: Animations of 4D torii cross-sections

Postby ICN5D » Thu May 20, 2021 2:32 am

All right, been playing around a lot, learning materials, interiors, lighting, etc. Oh povray .... where have you been all my life, lol. This is the first animation I have made from something other than calcplot3d!


So, here's a test run of the equation for a tiger:


pow((sqrt(pow((x*cos(clock)),2) + pow(y,2)) -2),2) + pow((sqrt(pow(z,2) + pow((x*sin(clock)),2)) -2),2) -0.5

max gradient = 10

and clock is

Code: Select all
Initial_Frame=1
Final_Frame=90
Initial_Clock=0
Final_Clock=1.57




Image

full size on gfycat:

https://gfycat.com/carefreelightheartedbighorn


I collected the 90 frames, made a ping-pong animation of 180 frames, saved as .avi , uploaded to gfycat which converts to .mp4 , then I can get a size-restricted gif image url for the img tag (for posting on this forum). The original looks much better, but that's okay. I'm about to subscribe to adobe so I can make nice mp4's.
It is by will alone, I set my donuts in motion
ICN5D
Pentonian
 
Posts: 1135
Joined: Mon Jul 28, 2008 4:25 am
Location: the Land of Flowers

Re: Animations of 4D torii cross-sections

Postby Plasmath » Fri May 21, 2021 12:07 pm

Glad it works!
Plasmath
Dionian
 
Posts: 35
Joined: Mon Feb 08, 2021 10:57 pm

Re: Animations of 4D torii cross-sections

Postby ICN5D » Sat May 22, 2021 2:44 am

Yes, thanks for the info :) POVray is turning out to be a terrific program for my needs. I'm testing the limits with the complexity of the isosurface function. So, here's a neat little something made by combining 3 different rotations:


(((II)I)(II))

(sqrt((sqrt(x^2 + y^2) -4)^2 + z^2) -2)^2 + (sqrt(w^2 + v^2) -2)^2 = 1

pow((sqrt(pow((sqrt(pow(x,2) + pow(y,2)) -4),2) + pow(z,2)) -2),2) + pow((sqrt(pow(w,2) + pow(v,2)) -2),2) -0.75




Coordinate real 3D solutions:

(((xz))(y))
pow((sqrt(pow((sqrt(pow(x,2) + pow(z,2)) -4),2) + pow(0,2)) -2),2) + pow((sqrt(pow(y,2) + pow(0,2)) -2),2) -0.75

(((x)z)(y))
pow((sqrt(pow((sqrt(pow(x,2) + pow(0,2)) -4),2) + pow(z,2)) -2),2) + pow((sqrt(pow(y,2) + pow(0,2)) -2),2) -0.75

(((x))(yz))
pow((sqrt(pow((sqrt(pow(x,2) + pow(0,2)) -4),2) + pow(0,2)) -2),2) + pow((sqrt(pow(y,2) + pow(z,2)) -2),2) -0.75


3 real -> real rotations that transform the solutions

Z = z*cos(q)
z = z*sin(q)

(((xZ)z)(y))
pow((sqrt(pow((sqrt(pow(x,2) + pow(z*cos(q),2)) -4),2) + pow(z*sin(q),2)) -2),2) + pow((sqrt(pow(y,2) + pow(0,2)) -2),2) -0.75

(((xZ))(yz))
pow((sqrt(pow((sqrt(pow(x,2) + pow(z*cos(q),2)) -4),2) + pow(0,2)) -2),2) + pow((sqrt(pow(y,2) + pow(z*sin(q),2)) -2),2) -0.75

(((x)Z)(yz))
pow((sqrt(pow((sqrt(pow(x,2) + pow(0,2)) -4),2) + pow(z*cos(q),2)) -2),2) + pow((sqrt(pow(y,2) + pow(z*sin(q),2)) -2),2) -0.75


Code: Select all
#version 3.7;

global_settings { assumed_gamma 1.0 }

#include "colors.inc" 

sky_sphere{                   
    pigment{ SkyBlue }}

camera {
location <12,9,10>
look_at <0,0,0>
right x*image_width/image_height}
     
light_source {
<100,100,0>
color  White}   


#declare q = clock;
   
   
isosurface {
  function {pow((sqrt(pow((sqrt(pow(x,2) + pow(0,2)) -4),2) + pow(z*cos(q),2)) -2),2) + pow((sqrt(pow(y,2) + pow(z*sin(q),2)) -2),2) -0.75 }
  max_gradient 20                                                               
  contained_by{ box { -10 , 10 } }
  pigment { Orange transmit 0 }
     finish {
        emission 0.0
        ambient .1
        diffuse .9
        specular .2 
        reflection 0
        brilliance 1
     }
  }




Image
It is by will alone, I set my donuts in motion
ICN5D
Pentonian
 
Posts: 1135
Joined: Mon Jul 28, 2008 4:25 am
Location: the Land of Flowers


Return to Toratopes

Who is online

Users browsing this forum: No registered users and 11 guests

cron