Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Making a 3 equal sided Pyramid?

Tegg Bode
FrootLoop Roo Overlord
Join date: 12 Jan 2007
Posts: 5,707
11-21-2007 05:05
I used Pythogoras but can't seem to get SL to render the same as the calsulations
Tring to make a .5m side 3 side pyra mid pythagoras tells me to make Z=.433 but when I spin it and stick it ro the side face of the other it doesn't match, .358 looks better at 289.5 degrees
Any maths guru's know better?
_____________________
Level 38 Builder [Roo Clan]

Free Waterside & Roadside Vehicle Rez Platform, Desire (88, 17, 107)

Avatars & Roadside Seaview shops and vendorspace for rent, $2.00/prim/week, Desire (175,48,107)
Ordinal Malaprop
really very ordinary
Join date: 9 Sep 2005
Posts: 4,607
11-21-2007 05:15
A "3 equal sided pyramid"? Pyramids have five faces and eight edges... do you mean a tetrahedron (four faces, six edges, all faces are triangles)?
_____________________
http://ordinalmalaprop.com/forum/ - visit Ordinal's Scripting Colloquium for scripting discussion with actual working BBCode!

http://ordinalmalaprop.com/engine/ - An Engine Fit For My Proceeding, my Aethernet Journal

http://www.flickr.com/groups/slgriefbuild/ - Second Life Griefbuild Digest, pictures of horrible ad griefing and land spam, and the naming of names
Siro Mfume
XD
Join date: 5 Aug 2004
Posts: 747
11-21-2007 05:33
From: Ordinal Malaprop
A "3 equal sided pyramid"? Pyramids have five faces and eight edges... do you mean a tetrahedron (four faces, six edges, all faces are triangles)?


It would seem he does mean tetrahedron. If he's using equilateral triangles, he isn't putting a square in there anywhere.
Stephen Zenith
Registered User
Join date: 15 May 2006
Posts: 1,029
11-21-2007 05:36
From: Ordinal Malaprop
A "3 equal sided pyramid"? Pyramids have five faces and eight edges... do you mean a tetrahedron (four faces, six edges, all faces are triangles)?


Actually, pyramids can have any number of faces - n triangles, and one n sided polygon for the base, giving a pyramid of n+1 faces. A tetrahedron is a triangular-based pyramid, the "classic" pyramid is a square-based one, etc. And even then, the triangles and base don't have to be regular polygons.

Agree that there's no such thing as a 3-sided pyramid though.
_____________________
Ordinal Malaprop
really very ordinary
Join date: 9 Sep 2005
Posts: 4,607
11-21-2007 05:40
If it's a tetrahedron, I make it, er... ( (0.5^2) - 1/((4cos30)^2) ) ^ (1/2)
which is 0.408 - is that right?
_____________________
http://ordinalmalaprop.com/forum/ - visit Ordinal's Scripting Colloquium for scripting discussion with actual working BBCode!

http://ordinalmalaprop.com/engine/ - An Engine Fit For My Proceeding, my Aethernet Journal

http://www.flickr.com/groups/slgriefbuild/ - Second Life Griefbuild Digest, pictures of horrible ad griefing and land spam, and the naming of names
Ordinal Malaprop
really very ordinary
Join date: 9 Sep 2005
Posts: 4,607
11-21-2007 05:42
From: Stephen Zenith
Actually, pyramids can have any number of faces - n triangles, and one n sided polygon for the base, giving a pyramid of n+1 faces. A tetrahedron is a triangular-based pyramid, the "classic" pyramid is a square-based one, etc. And even then, the triangles and base don't have to be regular polygons.

I stand corrected, quite right.
_____________________
http://ordinalmalaprop.com/forum/ - visit Ordinal's Scripting Colloquium for scripting discussion with actual working BBCode!

http://ordinalmalaprop.com/engine/ - An Engine Fit For My Proceeding, my Aethernet Journal

http://www.flickr.com/groups/slgriefbuild/ - Second Life Griefbuild Digest, pictures of horrible ad griefing and land spam, and the naming of names
Tegg Bode
FrootLoop Roo Overlord
Join date: 12 Jan 2007
Posts: 5,707
11-21-2007 05:49
From: Ordinal Malaprop
If it's a tetrahedron, I make it, er... ( (0.5^2) - 1/((4cos30)^2) ) ^ (1/2)
which is 0.408 - is that right?


Cool will try that thx :)
_____________________
Level 38 Builder [Roo Clan]

Free Waterside & Roadside Vehicle Rez Platform, Desire (88, 17, 107)

Avatars & Roadside Seaview shops and vendorspace for rent, $2.00/prim/week, Desire (175,48,107)
Ordinal Malaprop
really very ordinary
Join date: 9 Sep 2005
Posts: 4,607
11-21-2007 05:52
Bear in mind though that you can't just rez a prism and set its x, y and z scale to that - an SL "tetrahedron" is a tapered prism. Hm, I will have to check the parameters for that purpose...

I'm not sure it's right anyway. Dear me, this is just basic trigonometry, my brain has really gone downhill these past few years.
_____________________
http://ordinalmalaprop.com/forum/ - visit Ordinal's Scripting Colloquium for scripting discussion with actual working BBCode!

http://ordinalmalaprop.com/engine/ - An Engine Fit For My Proceeding, my Aethernet Journal

http://www.flickr.com/groups/slgriefbuild/ - Second Life Griefbuild Digest, pictures of horrible ad griefing and land spam, and the naming of names
Ordinal Malaprop
really very ordinary
Join date: 9 Sep 2005
Posts: 4,607
11-21-2007 06:03
Having said that, after having rezzed a few prisms and so on in-world, I have NO idea what the XYZ dimensions of the prism are meant to be - they're not its edges, that's for sure.
_____________________
http://ordinalmalaprop.com/forum/ - visit Ordinal's Scripting Colloquium for scripting discussion with actual working BBCode!

http://ordinalmalaprop.com/engine/ - An Engine Fit For My Proceeding, my Aethernet Journal

http://www.flickr.com/groups/slgriefbuild/ - Second Life Griefbuild Digest, pictures of horrible ad griefing and land spam, and the naming of names
Chosen Few
Alpha Channel Slave
Join date: 16 Jan 2004
Posts: 7,496
11-21-2007 07:11
From: Ordinal Malaprop
Having said that, after having rezzed a few prisms and so on in-world, I have NO idea what the XYZ dimensions of the prism are meant to be - they're not its edges, that's for sure.

Yeah, prisms are really weird. I can't understand why LL would have set them up the way they did. It seems to make zero sense.

The Z dimension is pretty easy, same as the bounding box, but X, Y, and the center point are all kinds of wonky. The postive X edge of the bounding box is tangent with the apex of the path triangle, as it should be, but the negative X edge does not touch the triangle's base. This makes the whole thing sit off-center inside the box. What's up with that?

Now you might say, well, that would be expected if you're trying to house an equilateral inside a square. If the apex touches the top of the box, the base wouldn't reach all the way to the bottom of the square, or you'd lose the equality. That would be a fine explanation except what about the other two points? If the goal is to put the largest possible equilateral triangle inside the box, then each of the two base points should touch a Y side of the box. But they don't. They both sit well inside the box.

So, not only is the triangle considerably off center, it's also way too small. This makes it almost impossible to intuit with any precision the exact size and location of a prism in SL. It's simply ridiculous.

That said, there's got to be a fixed mathematics behind the thing. I've never tried to figure out what it is, but if someone is so inclined, it's probably not that hard. I'm sure the height and width of the triangle are just percentages of their bounding box counterparts. And since you know the apex is always on the postive X edge of the box, you can calculate its position relative to the center pretty easily. Put all that together, and the size and location of the actual triangle are simple (but stupidly tedious) to figure out.

The prism was by far the goof of all time in SL prim design.
_____________________
.

Land now available for rent in Indigo. Low rates. Quiet, low-lag mainland sim with good neighbors. IM me in-world if you're interested.
Deanna Trollop
BZ Enterprises
Join date: 30 Jan 2006
Posts: 671
11-21-2007 07:59
From: Chosen Few
but the negative X edge does not touch the triangle's base. This makes the whole thing sit off-center inside the box. What's up with that?
The center of a prism base triangle isn't it's geometric center (half-width, half height), but rather its barycenter, the intersection of lines passing through each side's bisector and the opposite corner.

It looks strange if you only think in terms of the bounding box. Stack a prism on an equal scale box, and it looks wonky. Stack it on an equal scale cylinder, and it looks more natural. It's just a little counter-intuitive, since the base shape is formed by revolving a point around the z axis an odd number of times.

From: someone
If the goal is to put the largest possible equilateral triangle inside the box, then each of the two base points should touch a Y side of the box.
But then the triangle would be "off center." If you put a circular hollow in such a positioned triangle, and said hollow was centered on the z axis, then it would be closer to the sides which make the +X apex than to the -X side.

From: someone
That said, there's got to be a fixed mathematics behind the thing.
There are indeed. If X and Y scale are equal, the each side of the triangle is 0.866 of that size (more precisely, sqrt(3)/2 ). Also note that hollow sizes are half what they are for boxes and cylinders, i.e. a prism with a 90 hollow will have a hole diameter the same as a box of equal X/Y scale with a 45 hollow.
Chosen Few
Alpha Channel Slave
Join date: 16 Jan 2004
Posts: 7,496
11-21-2007 08:12
Thanks for the explanation, Deanna. That's really helpful. :)
_____________________
.

Land now available for rent in Indigo. Low rates. Quiet, low-lag mainland sim with good neighbors. IM me in-world if you're interested.
Deanna Trollop
BZ Enterprises
Join date: 30 Jan 2006
Posts: 671
11-21-2007 08:37
Welkies, Chosen 1.

And to answer the OP, to make a perfect tetrahedron, use a tapered prism with a z scale 0.7071 of it's X/Y scale ( sqrt(2)/2 ).
Tegg Bode
FrootLoop Roo Overlord
Join date: 12 Jan 2007
Posts: 5,707
11-21-2007 23:40
zzzCool thx people, i am trying to build a d20 dice from these prims, was going to build it large then shrink it, but that' won't work I now see.
I will study Ze dices shape further :)
_____________________
Level 38 Builder [Roo Clan]

Free Waterside & Roadside Vehicle Rez Platform, Desire (88, 17, 107)

Avatars & Roadside Seaview shops and vendorspace for rent, $2.00/prim/week, Desire (175,48,107)
Deanna Trollop
BZ Enterprises
Join date: 30 Jan 2006
Posts: 671
11-22-2007 08:55
From: Tegg Bode
i am trying to build a d20 dice from these prims
Hmmm, a d20 (regular icosahedron) could be done with 10 prims.