Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.
First time visiting? Here are some places to start:- Looking for a certain topic? Check out the categories filter or use Search (upper right).
- Need support? Ask a question to our Community Support category.
- Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
- Be respectful, on topic and if you see a problem, Flag it.
If you would like to contact our Community Manager personally, feel free to send a private message or an email.
Create tetrahedron?
alexander_potochkin
Member Posts: 45 ✭✭
Hello
What is the right way to create a tetrahedron in onShape?
I can make an equilateral triangle and then loft it to a specific point,
but in this case I need to manually calculate the correct height of the tetrahedron.
Is there any better way to make it?
Thanks much!
What is the right way to create a tetrahedron in onShape?
I can make an equilateral triangle and then loft it to a specific point,
but in this case I need to manually calculate the correct height of the tetrahedron.
Is there any better way to make it?
Thanks much!
Tagged:
0
Best Answers
-
This is how I do it. I use a hexahedron/cube for reference geometry.
https://cad.onshape.com/documents/c139928c548f4436bea91dfc/w/957c1ccb7ac94f13a7d49f98/e/716f71e783b94399945fb48c
EDIT: In this way you have the origin of the tetrahedron at the same place as the origin of the planes. You can rotate it however you want.
5 -
@alexander_potochkin, @andrew_troup @brucebartlett @clayton_ertley , No need to calculate height manually. Now Onshape provided variable option with the help of that you can create very easily as shown in below video. You have to define only edge length (Variable a) other will update automatically.

You can refer below document link for tetrahedron creation.
https://cad.onshape.com/documents/b4d69938124444a5964aa70c/w/0134d50029bf4711a734b71a/e/c19d7dad093249fd9668b605
9
Answers
-
Once we have 3D sketches the construction will become trivially easy. In the meantime you'll have to be ingenious.0
-
Draw a triangle and blind extrude (with a arbitrary number larger than the desired height) add draft and your extrude should finish with a point giving 4 faces. You will have to do some math to work out the angle to extrude at.0
-
Could not help myself. I used 2 sketches, the second one works out the angle to extrude at, I have linked sizes so all faces come out equal.
I tried to link angle with a variable but that does not seem possible yet.
https://cad.onshape.com/documents/5f90e0c61c164cb5bf4141cf/w/b4350e5bf94349dc871ed0bb/e/de54a518e7af4756bf334182
0 -
Wow, Bruce thanks a lot!I need some time to comprehend your solution(not at my computer right now)
Will it properly recalculate if I change the size of the base triangle?What do you mean by " link angle with a variable" ?thanks again0 -
@brucebartlett
One slight snag with your construction: the side you have set equal to the side which is 200mm long measures only 173.205, which is to be expected because an equal relation is true in the plane of the sketch, not in 3D.
So the equality is NOT with the length of the other line, but with the projection of that line onto the sketch plane
This is discussed elsewhere on this forum, including here:
https://forum.onshape.com/discussion/1576/equal-constraint-use-with-care-between-sketches
I don't know offhand what the angle of a tetrahedron is, but if you check it I think you might find it's rather more than the 65.9 suggested by your model0 -
Good pick up, I have fixed so all sides are now equal (well almost 200 vs 200.002). When time permits I'll will have to read that post.andrew_troup said:@brucebartlett
One slight snag with your construction: the side you have set equal to the side which is 200mm long measures only 173.205, which is to be expected because an equal relation is true in the plane of the sketch, not in 3D.
So the equality is NOT with the length of the other line, but with the projection of that line onto the sketch plane
This is discussed elsewhere on this forum, including here:
https://forum.onshape.com/discussion/1576/equal-constraint-use-with-care-between-sketches
I don't know offhand what the angle of a tetrahedron is, but if you check it I think you might find it's rather more than the 65.9 suggested by your model0 -
@brucebartlett ;
I guess the obvious remedy would be to link the line length in sketch 2 to the line length in sketch 1 using a variable
(I haven't had a chance to explore them thoroughly but I presume this would be straightforward, although your post suggests this does not yet work for angles)0 -
I just put another line across the triangle on sketch 1 and linked to sketch 2 via a = constraint.
I just can not work out how to get the angle into the draft on the extrude.0 -
@brucebartlett
The linked post is very wordy, because we were trying to find our way to the root of the issue.
Here's the executive summary:
# Constraints which operate between sketches ALWAYS project the remote sketch entity to the destination plane before solving the constraint.
The only exception is the pierce constraint (where a projection would be inherently meaningless: it would not result in the specified result)
Currently AFAIK the only other Onshape situation which does not ever rely on this sort of projection is constraint to a remote plane (rather than to a sketch entity).
NOTE: This # behaviour is common to all similar MCAD modellers: it is not a bug.
In other words, this behaviour is (justifiably, almost unavoidably) BY DESIGN.
0 -
Ok, i am having flashbacks - why are we now doing a tetrahedron?
Philip Thomas - Onshape0 -
Don't worry, @philip_thomas; only three more to go... (and two of them are trivial ...)0
-
This is how I do it. I use a hexahedron/cube for reference geometry.
https://cad.onshape.com/documents/c139928c548f4436bea91dfc/w/957c1ccb7ac94f13a7d49f98/e/716f71e783b94399945fb48c
EDIT: In this way you have the origin of the tetrahedron at the same place as the origin of the planes. You can rotate it however you want.
5 -
Further more, you don't have to scale afterwards to get the size you need.
You can see in my model that I used a cube with an edge length of 60mm. This method will always yield a tetrahedron with an edge length of 84.852. Meaning that the ratio of the
Cube edge length to tetrahedron edge length is (1 : 1.3642). You can use this ratio to predetermine the edge length of the tetrahedron.
0 -
@clayton_ertley
Nice! Kudos to you0 -
Thanks! I design rubik's cubes among plenty others. We were left to design our own platonic solids. I had to use actual cartesian coordinates for each and every vertex to get a dodecahedron. it was very tedious.
0 -
@alexander_potochkin, @andrew_troup @brucebartlett @clayton_ertley , No need to calculate height manually. Now Onshape provided variable option with the help of that you can create very easily as shown in below video. You have to define only edge length (Variable a) other will update automatically.

You can refer below document link for tetrahedron creation.
https://cad.onshape.com/documents/b4d69938124444a5964aa70c/w/0134d50029bf4711a734b71a/e/c19d7dad093249fd9668b605
9 -
Thank you Clayton, Andrew and Viru!
Now I definitely know what onShape tools I should have a look to.
What a wonderful community here!
Have a great day.
Alex.
0 -
With big help from the community I made my very own version of tetrahedron.
I made a cube and sliced a tetrahedron out of it.
https://cad.onshape.com/documents/d21a14adc0ef4fa09095b29d/w/79bbbe32437a42df9980f7ea/e/30a56b8e579348c084f6f188
Thanks again
0 -
I would use the fact that a cube contains all the points of a tetrahedron at it's corners. Not as quite simple to draw but requires no calculations and is driven by the one variable.
Draw a square and extrude with side length as a variable.
Create a plane that intersects three of the points of the cube so that they make an equilateral triangle.
Sketch a circle on the new plane that also intersects all three points. (doesn't have to be a circle but I found it easiest)
Extrude (by variable) and Subtract the circle from the cube, lopping off the corner.
Repeat the Plane/Sketch/Extrude for the remaining three corners.
It might take a little more time to draw but it is much more satisfying as it's a perfect tetrahedron.1 -
since @patrick_moore decided to revive this thread I'll throw my solution in there too:
- sketch triangle
- sketch one of the other edges (using an equal constraint)
- loft to the point
Of course, to do it in one feature you could use the Polyhedron feature too
. Go here to see both examples. 0 -
nice @Evan_Reese ! I love the way equal constraint can be used across different sketches. Instead using a construction line making the new line equal to one of the triangle sides works too.
www.accuratepattern.com0 -
Assuming I understand your suggestion, it would make it equal to the projection of the edge, so I don't think it would end up right. see what I mean?bruce_williams said:nice @Evan_Reese ! I love the way equal constraint can be used across different sketches. Instead using a construction line making the new line equal to one of the triangle sides works too.0 -
Solution based on @brucebartlett's suggestion to draft an extrude, but without using the measure featurescript. The dihedral angle for a tetrahedron is arccos(1/3), so 90 deg - acos(1/3) gives the correct draft angle. This gives an exact result (60.00000 mm measured side length for all sides).
https://cad.onshape.com/documents/93f2dfdea0555d930849c033/w/738de8482a5a2e6f9d440e97/e/a1b6010751a1e7e89ecc3d2a
Get in touch: contact@alnis.dev | My personal site: https://alnis.dev
@alnis is my personal account. @alnis_ptc is my official PTC account.2







