## Volumes of toratopes with multiple integrals

Discussion of shapes with curves and holes in various dimensions.

### Volumes of toratopes with multiple integrals

I've had a go at calculating the contents of various toratopes using multiple integrals. I've worked out an interesting process for doing it in general, but it's not at a stage where I can do it algorithmically yet. The trick is to change into rotatopic coordinates, which reduces the problem to an integral of the Jacobian over a lower dimensional shape. In some cases this has to be done several times.

I'll try to post everything some time next week. In the meantime, here's a sneak preview. I'm writing in LaTeX notation because it's quicker for me, and I'm using tau = 2pi

We want the volume of (((II)(II))(III)I), with radii A, a_1, a_{11}, a_{12}, a_2.

Use the rotatopic coordinates for (II)(II)(III)I.

Then the volume is a product of surface contents of two circles and a sphere, multiplied by the integral of the Jacobian of the coordinate transform, over the toratope ((II)II) shifted by the vector (a_{11}, a_{12}, a_2, 0).

This requires another coordinate transform, this time using rotatopic coordinates (II)II. What I ended up with is:

V= 2 \tau^5 a_{11} a_{12} (2/15 A^5 + 2/3 A^3 a_2^2)
Last edited by PWrong on Fri Sep 12, 2014 3:42 pm, edited 3 times in total.

PWrong
Pentonian

Posts: 1599
Joined: Fri Jan 30, 2004 8:21 am
Location: Perth, Australia

### Re: Volumes of toratopes with multiple integrals

Here's a smaller sneak preview of an even bigger shape, to given an idea of the direction this algorithm takes through the toratopes.

(((III)I)(((II)I)I)I)

Written with numbers to make it clearer what's going on:
((31)((21)1)1)

Coordinate transform:
312111

Next shape to integrate the Jacobian over (shifted by an appropriate vector):
(2(21)1)

Coordinate transform:
2211

Next shape:
(121)

Coordinate transform:
121

Next shape:
3

PWrong
Pentonian

Posts: 1599
Joined: Fri Jan 30, 2004 8:21 am
Location: Perth, Australia

### Re: Volumes of toratopes with multiple integrals

I feel like the main thing holding me back with writing the Mathematica code is the "Function" function. It only takes arguments with head Symbol, which makes it really frustrating when you have a large, automatically generated list of variables that depends on a toratope list.

I've come up with a function called SuperFunction, which might make things better. Basically it works just like Function, except it can take inputs with superscripts and unflattened lists. It just converts those into strings and then uses Function. It's probably a bad way to do this though. The people who work at Mathematica and actually know how Function works, could probably get Function to do what I want it to do easily. Once I start applying this it should be easier to get the volumes.

Code: Select all
SuperFunction[vars_, expr_] := Function[Evaluate[   Symbol[StringJoin [ ToString /@ List @@ #]] & /@ Flatten[vars]],   Evaluate[expr /.     MapThread[#1 -> #2 &, { Flatten[vars],       Symbol[StringJoin [ ToString /@ List @@ #]] & /@        Flatten[vars]}]]]

Example: here 'Function' gives an error, but SuperFunction changes the given variables and converts to Function.

Code: Select all
Function[{Subscript[x, 1], {Subscript[x, 2], Subscript[r, 3]}}, Subscript[x, 1] + Subscript[x, 2] + Subscript[r, 3]]]Function::flpar: Parameter specification {Subscript[x, 1],{Subscript[x, 2],Subscript[r, 3]}} in Function[{Subscript[x, 1],{Subscript[x, 2],Subscript[r, 3]}},Subscript[x, 1]+Subscript[x, 2]+Subscript[r, 3]] should be a symbol or a list of symbols.SuperFunction[{Subscript[x, 1], {Subscript[x, 2], Subscript[r, 3]}}, Subscript[x, 1] + Subscript[x, 2] + Subscript[r, 3]]]Function[{x1, x2, r3}, r3 + x1 + x2]

PWrong
Pentonian

Posts: 1599
Joined: Fri Jan 30, 2004 8:21 am
Location: Perth, Australia

### Re: Volumes of toratopes with multiple integrals

It's still really difficult to get a general formula with this method. I'll demonstrate with the shape (56), which only takes one step but gives a complicated formula.

Let Vn be the volume of a unit n-ball. The toratope is T = (56) = ((IIIII)(IIIIII)). Let the major radius be A and the minor radii be a, b. We use rotatopic coordinates corresponding to the rotatope 56. The subtoratope is (II), and the shift is (a, b).

The volume is the following integral over a disk of radius A:
V5 V6 Integral (x - a)^4 (y - b)^5 dx dy

In Mathematica:
Code: Select all
In[47]:= Simplify[ Integrate[(x - a)^4 (y - b)^5, {x, y} \[Element] Sphere[{0, 0}, A]], A > 0]Out[47]= -(1/  64) A b (15 A^8 + 80 A^6 b^2 + 48 A^4 b^4 +    16 a^4 (15 A^4 + 40 A^2 b^2 + 8 b^4) +    48 a^2 (5 A^6 + 20 A^4 b^2 + 8 A^2 b^4))

So the volume is a large polynomial of the radii. From a bit of investigation it looks like you need hypergeometric functions to describe the volume of toratopes of the form (mn).

PWrong
Pentonian

Posts: 1599
Joined: Fri Jan 30, 2004 8:21 am
Location: Perth, Australia

### Re: Volumes of toratopes with multiple integrals

Sorry, V_n should be the surface area of a sphere in and, not the volume. With the convention that V_0 = 1.

I have a general integral formula for toratopes of depth 2, that is (pqr...).
It's a formula that mathematica can always solve for a given toratope, but not if p,q,... are unknown.

For some deeper toratopes we can get a formula that's not much more complicated. But generally we need difficult integrals within integrals. ((21)1) is pretty straightforward but ((31)1) is much harder.

I think mathematica can always do it but it might be tricky to implement. I'm on my phone so I'll post the formulae after I get my computer working.

PWrong
Pentonian

Posts: 1599
Joined: Fri Jan 30, 2004 8:21 am
Location: Perth, Australia

### Re: Volumes of toratopes with multiple integrals

Actually I think it might be possible to reduce it to just an integral over a sphere. The integrand will be a very complicated sum of products of polynomials involving binomials and double factorials, but it should be expressible in one line. I think this will be a nice theorem.

I've invented some new notation to describe the indices of radii in a toratope. It's useful to take a sum or product over all the indices of a particular "backwards depth".

PWrong
Pentonian

Posts: 1599
Joined: Fri Jan 30, 2004 8:21 am
Location: Perth, Australia

### Re: Volumes of toratopes with multiple integrals

What's the new notation look like? Also, the formula generator is very cool, didn't know that was possible. So much to learn! Can mathematica convert the implicit function into an explicit polynomial? How about solving the polynomials for hyperplanes, and making exact roots? I know it's off topic, but the idea has been stuck in my mind.
in search of combinatorial objects of finite extent
ICN5D
Pentonian

Posts: 1047
Joined: Mon Jul 28, 2008 4:25 am
Location: Orlando, FL

### Re: Volumes of toratopes with multiple integrals

For a toratope like ((xy)(z(wt))), the index {221} would refer to the w, {1} refers to (xy), {21} refers to z, {22} refers to (wt) and so on.

I've been referring to indices with a small omega. The depth of omega is the number of numbers in it, e.g. depth{221} = 3. The depth of a toratope is the maximum depth of all its indices, so the depth of (((21)1)1) is 4.

The backwards depth (for lack of a better name) of omega is the depth of the subtoratope corresponding to omega. So bdepth{22} = depth (wt) = 1.

In my volume formula I take sums and products over the set of indices with bdepth 1.

PWrong
Pentonian

Posts: 1599
Joined: Fri Jan 30, 2004 8:21 am
Location: Perth, Australia

### Re: Volumes of toratopes with multiple integrals

I think Mathematica should be able to convert the implicit equations to polynomials. I'm not sure if there's a function that will do it or if you'd have to program one. For hyperplanes, I've experimented with multiplying the vector by a rectangular matrix with a time component, to reduce the dimension. That was pretty straightforward and it will work in general. But it's very slow at animating things.

PWrong
Pentonian

Posts: 1599
Joined: Fri Jan 30, 2004 8:21 am
Location: Perth, Australia

### Re: Volumes of toratopes with multiple integrals

I'm much closer to a general formula for volumes. It's a monster though. When I'm finished, it will have no integral signs, but lots of sums, products, and double factorials.

PWrong
Pentonian

Posts: 1599
Joined: Fri Jan 30, 2004 8:21 am
Location: Perth, Australia

### Re: Volumes of toratopes with multiple integrals

For hyperplanes, the matrix you use can depend on t in whatever way you like. I tried including lots of sines and cosines of t, 1.1 t, 1.2 t,... so that the plane would move around the whole space equally. This made the animations look more organic and alien than the examples you've made, but not as good at demonstrating the overall shape consistently.

PWrong
Pentonian

Posts: 1599
Joined: Fri Jan 30, 2004 8:21 am
Location: Perth, Australia

### Re: Volumes of toratopes with multiple integrals

PWrong, is your approach similar to my derivation of (33) and such?
Marek14
Pentonian

Posts: 1101
Joined: Sat Jul 16, 2005 6:40 pm

### Re: Volumes of toratopes with multiple integrals

I don't think so. My method is to start from a hypervolume integral over the toratope, convert to rotatopic coordinates, pull out the integrals of the angles, and reduce it to a volume integral over a lower dimensional toratope. Integrating the angles turns out to be harder than expected.

If I understood correctly, your approach was to use a generalisation of Pappus' centroid theorem, correct? I haven't checked if any of my result match up with yours yet. I'll figure out (33) and let you know.

PWrong
Pentonian

Posts: 1599
Joined: Fri Jan 30, 2004 8:21 am
Location: Perth, Australia

### Re: Volumes of toratopes with multiple integrals

My result for (33) is
2/3 pi^3 A^2 (6 a^2 A^2 + A^4 + 24 a^2 b^2 + 6 A^2 b^2)

PWrong
Pentonian

Posts: 1599
Joined: Fri Jan 30, 2004 8:21 am
Location: Perth, Australia

### Re: Volumes of toratopes with multiple integrals

PWrong wrote:My result for (33) is
2/3 pi^3 A^2 (6 a^2 A^2 + A^4 + 24 a^2 b^2 + 6 A^2 b^2)

My result is
2/3*pi^3*r^2*(24*R1^2*R2^2 + 6*r^2*(R1^2 + R2^2) + r^4) which seems to be identical.
Marek14
Pentonian

Posts: 1101
Joined: Sat Jul 16, 2005 6:40 pm

### Re: Volumes of toratopes with multiple integrals

This is my first step formula for toratopes of depth 2.

V_n is the surface area of a sphere in nD. The integral is taken over a ball B^k in nD. The (-1) is just there to cancel out the negative terms that fall out of the integral for some reason. As an alternative to this formula, you can replace (x_i - a_i) with x_i, and integrate over the ball offset by the vector (a_1, ... , a_k). I'm working on a general version that doesn't have any integrals at all.

You can do this integral in Mathematica like this.

Code: Select all
In[105]:= Integrate[ x^5 y^4 z^2, {x, y, z} \[Element] Ball[{a, b, c}, A]]Out[105]= ConditionalExpression[ 4/315 a^5 A^9 \[Pi] + 8/693 a^3 A^11 \[Pi] + (4 a A^13 \[Pi])/3003 +   8/35 a^5 A^7 b^2 \[Pi] + 16/63 a^3 A^9 b^2 \[Pi] +   8/231 a A^11 b^2 \[Pi] + 4/15 a^5 A^5 b^4 \[Pi] +   8/21 a^3 A^7 b^4 \[Pi] + 4/63 a A^9 b^4 \[Pi] +   4/35 a^5 A^7 c^2 \[Pi] + 8/63 a^3 A^9 c^2 \[Pi] +   4/231 a A^11 c^2 \[Pi] + 8/5 a^5 A^5 b^2 c^2 \[Pi] +   16/7 a^3 A^7 b^2 c^2 \[Pi] + 8/21 a A^9 b^2 c^2 \[Pi] +   4/3 a^5 A^3 b^4 c^2 \[Pi] + 8/3 a^3 A^5 b^4 c^2 \[Pi] +   4/7 a A^7 b^4 c^2 \[Pi], (a | b | c) \[Element] Reals && A > 0]

Or for a general function that simplifies with reasonable assumptions (positive radii), use this:

Code: Select all
ToratopeVolume1[tor_, alist_, A_] := Simplify[   Integrate[Product[Subscript[x, i]^tor[[i]], {i, Length[tor]}],    Evaluate[Table[Subscript[x, i], {i, Length[tor]}]] \[Element]     Ball[alist, A]], Alternatives @@ alist \[Element] Reals && A > 0]In[104]:= ToratopeVolume1[{3, 3}, {a, b}, A]Out[104]= 1/8 a A^2 b (3 A^2 (A^2 + 2 b^2) +    a^2 (6 A^2 + 8 b^2)) \[Pi]

PWrong
Pentonian

Posts: 1599
Joined: Fri Jan 30, 2004 8:21 am
Location: Perth, Australia