1
$\begingroup$

I'd like to plot the TetrahedronFiveCompound as in this image

TetrahedronFiveCompound

from https://mathworld.wolfram.com/Tetrahedron5-Compound.html. If possible without the black edges and choosing each tetrahedron's color. I can't find the way to do that in the options for PolyhedronData.

$\endgroup$

2 Answers 2

0
$\begingroup$

An extended comment...

The notebook that you can download from the MathWorld Tetrahedron5-Compound page includes the following code:

Off[General::spell1];
Needs["Graphics`Polyhedra`"]
vertices = Vertices[Dodecahedron];
Triangles[{f1_, f2_, f3_, f4_}] := 
    {{f1, f2, f3},
    {f1, f3, f4},
    {f1, f4, f2},
    {f4, f3, f2}}
tetrapoints = {{1, 9, 12, 20}, {2, 10, 13, 16},{3, 6, 14, 17}, {4, 7, 15, 18}, {5, 8, 11, 19}};
poly = (vertices[[#]] &) /@ Flatten[ Triangles /@ tetrapoints, 1];
linearcombination[r_, a_, b_] := (1 - r)*a + (r)*b
HollowTriangle[t_] :=
    
 Block[{a = t[[1]], b = t[[2]], c = t[[3]], aa, bb, cc},
        aa = linearcombination[1/8, a, (b + c)/2];
        bb = linearcombination[1/8, b, (c + a)/2];
        cc = linearcombination[1/8, c, (a + b)/2];
        {{a, b, bb, aa}, {b, c, cc, bb}, {c, a, aa, cc}} ]
On[General::spell1]
tetrapict = Show[Graphics3D[ Polygon /@ Flatten[ HollowTriangle /@ poly,1]],ViewVertical -> {.52, .38, .85}, Boxed -> False]

Which would produce:

enter image description here

Except that more current versions of Mathematica, no longer support the Vertices[] function.

Well, ... maybe you could still download an old Combinatorica package.

I didn't find an obvious direct equivalent of Vertices[] in the new functionality, but someone here can (hopefully) direct you to it.

Maybe someone more familiar with GraphEmbedding (see documentation) or the integration of the earlier Combinatorica package can help.

All of the above said, this would only get you an image of the

TetrahedronFiveCompound

You (or others on this site) then need to figure out how to get to the specifics of what you want to achieve, plotting a similar image,

If possible without the black edges and choosing each tetrahedron's color.

I'll give this some more thought as I can.

$\endgroup$
1
  • $\begingroup$ I didn't realize I could download the code from Mathworld! I thought it was some kind of default drawing mode, but it seems it is more manual than that. I'll see if I can tweak the code. Thank you! $\endgroup$ Commented May 21, 2021 at 18:24
1
$\begingroup$
data=PolyhedronData["TetrahedronFiveCompound", "Polyhedra"];
Graphics3D[
 Riffle[ColorData[97] /@ Range[5], 
  data]]

enter image description here

$\endgroup$
1
  • $\begingroup$ Thank you, I meant without faces, but this is nice too. $\endgroup$ Commented May 21, 2021 at 18:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.