# Transformation Matrices - Tetrahedra

• Jan 11th 2011, 09:20 AM
perrelet
Transformation Matrices - Tetrahedra
Hello everyone!

I was wondering if anyone out there could help me with some 3d geometry transformations.

What I've got:

I have a tetrahedron (A) in Cartesian space, centred at the origin, with vertices at:
(1,1,1) , (-1,-1,1) , (-1,1-1) & (1,-1,-1).

What I would like:

A tetrahedron (B) with vertices at:
(-1,-1,-1), (0,-1,0), (-1,0,0), (0,0,-1)

The question:

How does one find the transformation matrix to transform tetrahedron A into tetrahedron B?

Any help will be greatly appreciated :)
• Jan 11th 2011, 09:33 AM
snowtea
This can't be expressed as a linear transformation A.

Your original vectors v1+v2+v3+v4 = 0
However, your new vectors v1'+v2'+v3'+v4' = (-2,-2,-2)
If this was a linear transformation:
Av1 + Av2 + Av3 + Av4 = A(v1+v2+v3+v4) = 0

If you wanted this transformation, you will at least have to use affine transformations.
• Jan 11th 2011, 09:57 AM
perrelet

Trying to solve the matrices I just realised (as you say) it is unsolvable as a linear transform. So how would one find the affine transformation?
• Jan 11th 2011, 10:12 AM
snowtea
For affine transformations, you just add in a scale factor (which is normally the unit).

For example, (1,1,1) would be represented as (1,1,1,1).
Then you can do a linear transformation in 4 dimensions.

In general, an affine vector (a,b,c,d) is the same thing as the 3d vector (a/d, b/d, c/d).

However, I'm not sure this is the best way for you to go.
What are you trying to do?
• Jan 11th 2011, 10:16 AM
perrelet
I'm using structure synth to create a fractal. So I want to put map tetrahedrons onto the 4 face's of a larger tetrahedron. In sturcture synth you only have option of using a 3x3 transformation matrix though...
• Jan 11th 2011, 10:25 AM
snowtea
Actually, most 3d drawing software allow affine transformations. They are needed for translations and also perspective projections.

My suggestion is for a fractal, the tetrahedron should at least be similar (which is not the case for your example).
If they are similar, you can easily draw it with a scaling, rotation, and translation (which is an affine transformation).
Also, perhaps it is easier to use the scaling rotation and translation primitive instead of constructing the matrix yourself (essentially let the computer do it for you).
• Jan 11th 2011, 12:00 PM
perrelet
The tetrahedrons are self similar, I can post a screen shot if you'd like... The second one is a smaller version of the larger, but all lengths are scaled linearly and then rotated and translated...
• Jan 11th 2011, 12:05 PM
perrelet
So to clarify the larger tetrahedron (red) has edges all of length 2sqrt(2) and smaller has edges sqrt(2). All faces are equilateral -> so they must be self similar...
• Jan 11th 2011, 12:21 PM
snowtea
Quote:

Originally Posted by perrelet
The tetrahedrons are self similar, I can post a screen shot if you'd like... The second one is a smaller version of the larger, but all lengths are scaled linearly and then rotated and translated...

Yes, they are definitely similar :)
I didn't do a thorough calculation.
Some kind of 3D Koch curve I see.

So you must have been able to describe the transformations :) to draw that picture.
• Jan 11th 2011, 12:42 PM
perrelet
Hey snowtea :)

I drew that picture by explicitly stating the coordinates of both tetrahedra to the program. However I want the program to build the second by reiterating the first and applying a transformation, as this method will allow me to add levels of tetrahedra arbitrarily deep into the figure...

I've tried to solve the system of equations by transforming each vertex on one tetrahedron into the vertex on another, as (for example) follows:

(1,1,1) => (0,-1,0)
(-1,-1,1) => (-1,-1,-1)
(1,-1,-1) => (0,0,-1)
(-1,1,-1) => (-1,0,0)

But when I solve the system for the transformation matrix as it is done in 2D in this thread: https://nrich.maths.org/discus/messa...tml?1140864401. My system of equations is not solvable...

Not sure why?
• Jan 11th 2011, 12:52 PM
snowtea
Like a said, it is not a linear transformation (in 3 dimensions), so of course you won't be able to solve it.

Express it as a composition of simple transformations (on your coordinate axes) in this order:

Scaling then Rotation then Translation.

Then you can use the exact same drawing routine since your new coordinate axes are transformed.

Note: You will have to use quite a bit of trig.