Regular Octahedron

Author

Eric W. Weisstein
January 4, 2024

This notebook downloaded from http://mathworld.wolfram.com/notebooks/Polyhedra/RegularOctahedron.nb.

For more information, see Eric's MathWorld entry http://mathworld.wolfram.com/RegularOctahedron.html.

©2024 Wolfram Research, Inc. except for portions noted otherwise

Figure

GraphicsRow[{
Graphics3D[{Opacity[.5],PolyhedronData["Octahedron","Polyhedron"]},Boxed->False],
Graphics3D[{PolyhedronData["Octahedron","Lines"]},Boxed->False],
PolyhedronData["Octahedron","Net"]
},ImageSize->700]

Solid

Orientations

PolyhedronData["Octahedron","Orientations"]

PolyhedronData["Octahedron","DefaultOrientation"]

Show[PolyhedronData[{"Octahedron",#}],Boxed->False]&/@PolyhedronData["Octahedron","Orientations"]

axes=Line[{-#,#}]&/@Permutations[{.8,0,0}];

Show[GraphicsArray[Graphics3D[{Polyhedron[Octahedron,#],{Red,Thickness[.02],axes}},PlotLabel->#,Boxed->False,ViewPoint->{5,1,0}]&/@{"C3","C4"}]]

Show[GraphicsArray[Graphics3D[{Polyhedron[Octahedron,#],{Red,Thickness[.02],axes}},PlotLabel->#,Boxed->False,ViewPoint->{0,0,5}]&/@{"C3","C4"}]]

Polyhedron

Graphics3D[{FaceForm[Green,Red],PolyhedronData["Octahedron","Polyhedron"]}]

Region

PolyhedronData["Octahedron","Region"]

Solid and Dual

GraphicsRow[PolyhedronData["Octahedron",#]&/@{"Graphics3D","Dual","DualCompound"}]

UniformPolyhedron

uniform=UniformPolyhedron[stdname="Octahedron"]

PolyhedronFaceTally[uniform]

UniformPolyhedron/@{
stdname,
UniformPolyhedronIndex[stdname,"Wenninger"],
{"Coxeter",UniformPolyhedronIndex[stdname,"Coxeter"]},
{"Kaleido",UniformPolyhedronIndex[stdname,"Kaleido"]},
{"Uniform",UniformPolyhedronIndex[stdname,"Maeder"]},
{"Wenninger",UniformPolyhedronIndex[stdname,"Wenninger"]}
}

SameQ@@%

Graphics3D/@(polys=Polygon[uniform[[1]],#]&/@uniform[[2]])

Graphics3D[#,Boxed->False]&/@{uniform,polys}

Bulatov

BulatovUniformName[UniformPolyhedronIndex[stdname,"Kaleido"]]

BulatovUniformGraphics3D[UniformPolyhedronIndex[stdname,"Kaleido"],Boxed->False]

bulatov=BulatovUniformPolyhedron[UniformPolyhedronIndex[stdname,"Kaleido"]]

Graphics3D/@(polys=Polygon[bulatov[[1]],#]&/@bulatov[[2]])

PolyhedronFaceTally[bulatov]

Graphics3D[#,Boxed->False]&/@{bulatov,polys}

Maeder

MaederUniformName[UniformPolyhedronIndex[stdname,"Maeder"]]

wythoff=MaederWythoffSymbol[UniformPolyhedronIndex[stdname,"Maeder"]]

Import["https://www.mathconsult.ch/static/unipoly/"<>If[maederindex<10,"0",""]<>ToString[UniformPolyhedronIndex[stdname,"Maeder"]]<>".html","Images"][[1]]

maeder=MaederUniformPolyhedron[UniformPolyhedronIndex[stdname,"Maeder"]]

Graphics3D/@(polys=Polygon[maeder[[1]],#]&/@maeder[[2]])

PolyhedronFaceTally[maeder]

Graphics3D[#,Boxed->False]&/@{maeder,polys}

Net

PolyhedronData["Octahedron","Net"]

PolyhedronData["Octahedron","Net","Colored"]

NetPrintout[Octahedron,"Octahedron.pdf"]

All

tri[x_]:=Line[x+#&/@{{0,0},{1,0},{1,Sqrt[3]}/2,{0,0}}]
dtri[x_]:=Line[x+#&/@{{0,0},{-1,Sqrt[3]}/2,{1,Sqrt[3]}/2,{0,0}}]

With[{h=Sqrt[3]/2},
Show[GraphicsArray[
Partition[
Graphics[#,
AspectRatio->Automatic,PlotRange->{{-1/2,3.5},{-1,1.8}}]&/@
{
{dtri/@{{0,0},{1,0},{2,0},{3/2,-h}},tri/@{{0,0},{1/2,h},{1,0},{2,0}}},
{dtri/@{{0,0},{1,0},{2,0},{1/2,-h}},tri/@{{0,0},{1,0},{3/2,h},{2,0}}},
{dtri/@{{0,0},{1,0},{2,0},{1/2,-h}},tri/@{{0,0},{1,0},{1/2,h},{2,0}}},
{dtri/@{{0,0},{1,0},{2,0},{1/2,-h}},tri/@{{0,0},{1,0},{2,0},{-1/2,h}}},
{dtri/@{{0,0},{1,0},{2,0},{5/2,-h}},tri/@{{0,0},{1,0},{2,0},{-1/2,h}}},
{dtri/@{{0,0},{1,0},{2,0},{3/2,-h}},tri/@{{0,0},{1,0},{1/2,h},{3/2,-h}}},
{dtri/@{{0,0},{1,0},{2,0},{5/2,-h}},tri/@{{0,0},{1,0},{2,0},{1/2,h}}},
{dtri/@{{1/2,0},{3/2,0},{2,h},{3,h}},tri/@{{-1/2,0},{1/2,0},{1,h},{2,h}}
},

{dtri/@{{0,0},{1,0},{3/2,-h},{5/2,-h}},tri/@{{0,0},{1,0},{-1/2,h},{3/2,-h}}},

{dtri/@{{0,h},{3/2,0},{2,-h}},tri/@{{-1/2,0},{1/2,0},{3/2,0},{0,h}}},
{dtri/@{{1/2,0},{3/2,0},{2,-h},{2,h}},tri/@{{1/2,0},{3/2,0},{1,h},{-1/2,0}}}
},4,4,{1,1},{}]
]]
]

Vertex coordinates

Show[GraphicsArray[
Graphics3D[Polyhedron[Octahedron,#],
Ticks->None,Axes->True,AxesLabel->TraditionalForm/@{x,y,z}]&/@{"C3","C4Diamond","C4Square"}]]

Union/@(PolyhedronEdgeLengths[Polyhedron[Octahedron,#]]&/@{"C3","C4Diamond","C4Square"})

PolyhedronVertices[Polyhedron[Octahedron,#]]&/@{"C3","C4Diamond","C4Square"}

{Sqrt[12],Sqrt[2],2Sqrt[2]}(PolyhedronVertices[Polyhedron[Octahedron,#]]&/@{"C3","C4Diamond","C4Square"})

Faces

Graphics3D/@PolyhedronData["Octahedron","Polygons"]

Properties: {"Octahedron", "C2"}

Initialization

<<MathWorld`Polyhedra`

p=PolyhedronData[pname={"Octahedron","C2"},"Polyhedron"]

vol=PolyhedronData[pname,"Volume"]

Centroid

PolyhedronData[pname,"Centroid"]

Graphics3D[{AbsolutePointSize[10],
Point[{0,0,0}],{Blue,Point[PolyhedronData[pname,"Centroid"]]},Opacity[.2],PolyhedronData[pname,"GraphicsComplex"]}]

RegionCentroid[p]

PolyhedronCentroid[p]

InertiaTensor

PolyhedronData[pname,"InertiaTensor"]

(i=((MomentOfInertia[p,{0,0,0}])/vol))//Timing

PolyhedronInertiaTensor[p]//Timing

MeanCylindricalRadius

PolyhedronData[pname,"MeanCylindricalRadius"]

N[%]

((NIntegrate[(Sqrt[(x^2)+(y^2)]),{x,y,z}∈p])/vol)

ClosestMeanCylindricalRadius[%]

Integrate over polyhedron

(rxy=((Integrate[(Sqrt[(x^2)+(y^2)]),{x,y,z}∈p])/vol)//FullSimplify)

N[rxy]

Divergence theorem

(rxy=MeanCylindricalRadius[p,"Simplification"->RootReduce,Debug->True])//Timing

N[rxy]

LogSimplify[rxy]//FullSimplify

N[%]

CAD

cad=CylindricalDecomposition[PolyhedronData[pname,"RegionFunction"][x,y,z],{x,y,z},"Function"]

((NIntegrate[(Sqrt[(x^2)+(y^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol)

(rxy=((Integrate[(Sqrt[(x^2)+(y^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol))//Timing

CAD over  1/8

reg=FullSimplify[PolyhedronData[pname,"RegionFunction"][x,y,z]&&x>0&&y>0&&z>0]

Show[Graphics3D[{Opacity[.2],p}],RegionPlot3D[ImplicitRegion[reg,{x,y,z}],PlotPoints->50]]

((Volume[ImplicitRegion[reg,{x,y,z}]])/vol)//FullSimplify

cad=CylindricalDecomposition[reg,{x,y,z},"Function"]

8((NIntegrate[(Sqrt[(x^2)+(y^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol)

(rxy=8((Integrate[(Sqrt[(x^2)+(y^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol))//Timing

N[rxy,20]

TrigToExp[rxy]//FullSimplify

N[%]

Boole Integrate doing z integral first

{{xmin,xmax},{ymin,ymax},{zmin,zmax}}==CoordinateBounds[p]

ineq=PolyhedronData[pname,"RegionFunction"][x,y,z]

(i1=Integrate[Boole[ineq](Sqrt[(x^2)+(y^2)]),{z,zmin,zmax}])//Timing

NIntegrate[(i1/vol),{x,xmin,xmax},{y,ymin,ymax}]

(i2=Integrate[(i1/vol),{x,xmin,xmax},{y,ymin,ymax}])//Timing

MeanSphericalRadius

PolyhedronData[pname,"MeanSphericalRadius"]

((NIntegrate[(Sqrt[(x^2)+(y^2)+(z^2)]),{x,y,z}∈p])/vol)

ClosestMeanSphericalRadius[%]

Integrate over polyhedron

(rxyz=((Integrate[(Sqrt[(x^2)+(y^2)+(z^2)]),{x,y,z}∈p])/vol))//Timing

N[rxyz]

Divergence theorem

(rxyz=MeanSphericalRadius[p,"Simplification"->FullSimplify,Debug->True])//Timing

N[rxyz]

LogSimplify[rxyz]//FullSimplify

CAD

cad=CylindricalDecomposition[PolyhedronData[pname,"RegionFunction"][x,y,z],{x,y,z},"Function"]

((NIntegrate[(Sqrt[(x^2)+(y^2)+(z^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol)

(rxyz=((Integrate[(Sqrt[(x^2)+(y^2)+(z^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol))//Timing

N[rxyz,20]

rxysimp1=ResourceFunction["LogSimplify"][rxy]//FullSimplify

CAD over  1/XX

reg=FullSimplify[PolyhedronData[pname,"RegionFunction"][x,y,z]&&0<y<Tan[Pi/5]x]

Show[Graphics3D[{Opacity[.2],p}],RegionPlot3D[ImplicitRegion[reg,{x,y,z}],PlotPoints->50]]

((Volume[ImplicitRegion[reg,{x,y,z}]])/vol)//FullSimplify

cad=CylindricalDecomposition[reg,{x,y,z},"Function"]

XX((NIntegrate[(Sqrt[(x^2)+(y^2)+(z^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol)

(rxyz=XX((Integrate[(Sqrt[(x^2)+(y^2)+(z^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol))//Timing

ByteCount[rxyzlog=LogSimplify[rxyz,"ZeroTestNumericalPrecision"->10000,WorkingPrecision->10000,Debug->True]]//Timing

ByteCount[rxyzcollect=Collect[TrigToExp[rxyzlog],Log[_]]//RootReduce]//Timing

Boole Integrate doing z integral first

{{xmin,xmax},{ymin,ymax},{zmin,zmax}}=CoordinateBounds[p]

ineq=PolyhedronData[pname,"RegionFunction"][x,y,z]

(i1=Integrate[Boole[ineq](Sqrt[(x^2)+(y^2)+(z^2)]),{z,zmin,zmax}])//Timing

NIntegrate[(i1/vol),{x,xmin,xmax},{y,ymin,ymax}]

(i2=Integrate[(i1/vol),{x,xmin,xmax},{y,ymin,ymax}])//Timing

MeanSquareCylindricalRadius

PolyhedronData[pname,"MeanSquareCylindricalRadius"]

N[%]

((NIntegrate[(x^2)+(y^2),{x,y,z}∈p])/vol)

Integrate over Polyhedron

(rxy2=((Integrate[(x^2)+(y^2),{x,y,z}∈p])/vol)//FullSimplify)

N[rxy2]

Divergence theorem

(rxy2=MeanSquareCylindricalRadius[p,"Simplification"->FullSimplify,Debug->True])//Timing

MeanSquareSphericalRadius

PolyhedronData[pname,"MeanSquareSphericalRadius"]

((NIntegrate[(x^2)+(y^2)+(z^2),{x,y,z}∈p])/vol)

Integrate over polyhedron

(rxy2=((Integrate[(x^2)+(y^2)+(z^2),{x,y,z}∈p])/vol)//FullSimplify)

N[rxy2]

Integrate over region

reg=PolyhedronData[pname,"RegionFunction"][x,y,z]

(rxy=((Integrate[((x^2)+(y^2)+(z^2))Boole[reg],{x,y,z}∈FullRegion[3]])/vol))

Divergence theorem

(rxy2=MeanSquareSphericalRadius[p,"Simplification"->FullSimplify,Debug->True])//Timing

Boole Integrate doing z integral first

{{xmin,xmax},{ymin,ymax},{zmin,zmax}}==CoordinateBounds[p]

ineq=PolyhedronData[pname,"RegionFunction"][x,y,z]

(i1=Integrate[Boole[ineq]((x^2)+(y^2)+(z^2)),{z,zmin,zmax}])//Timing

NIntegrate[(i1/vol),{x,xmin,xmax},{y,ymin,ymax}]

(i2=Integrate[(i1/vol),{x,xmin,xmax},{y,ymin,ymax}])//Timing

Polygons

PolyhedronData[pname,"FaceCount"]

PolyhedronFaceTally[p]

Graphics3D/@PolyhedronData[pname,"Polygons"]

Show[%]

Polyhedra

polyhedra=PolyhedronData[pname,"Polyhedra"]

Length[polyhedra]

Graphics3D[polyhedra]

Graphics3D[Table[{Hue[(i/(Length[polyhedra]))],polyhedra[[i]]},{i,Length[polyhedra]}]]

PolyhedronData[pname,"PolyhedronIndices"]

Region

PolyhedronData[pname,"Region"]

RegionFunction

PolyhedronData[pname,"RegionFunction"]

{RegionPlot3D[ImplicitRegion[PolyhedronData[pname,"RegionFunction"][x,y,z],{x,y,z}]],
Graphics3D[p]}

Collect[#,{x,y,z},RootReduce]&/@PolyhedronInequalities[p,{x,y,z}]

ineq=FullSimplify[%]

ineq/.{x->#,y->#2,z->#3}

{Region@ImplicitRegion[ineq,{x,y,z}],Graphics3D[p]}

SurfaceArea

PolyhedronData[pname,"SurfaceArea"]

SurfaceArea[p]

Total[Area/@PolyhedronData[pname,"Polygons"]]

SurfaceArea[PolyhedronData[pname,"Region"]]

Volume

PolyhedronData[pname,"Volume"]

Volume[p]//FullSimplify

PolyhedronVolume[p]//FullSimplify

Volume[PolyhedronData[pname,"Region"]]//FullSimplify

Volume[ImplicitRegion[Evaluate@PolyhedronData[pname,"RegionFunction"][x,y,z],{x,y,z}]]//FullSimplify

Properties: {"Octahedron", "C3"}

Initialization

<<MathWorld`Polyhedra`

p=PolyhedronData[pname={"Octahedron","C3"},"Polyhedron"]

vol=PolyhedronData[pname,"Volume"]

Centroid

PolyhedronData[pname,"Centroid"]

Graphics3D[{AbsolutePointSize[10],
Point[{0,0,0}],{Blue,Point[PolyhedronData[pname,"Centroid"]]},Opacity[.2],PolyhedronData[pname,"GraphicsComplex"]}]

RegionCentroid[p]

PolyhedronCentroid[p]

InertiaTensor

PolyhedronData[pname,"InertiaTensor"]

(i=((MomentOfInertia[p,{0,0,0}])/vol))//Timing

PolyhedronInertiaTensor[p]//Timing

MeanCylindricalRadius

PolyhedronData[pname,"MeanCylindricalRadius"]

N[%]

((NIntegrate[(Sqrt[(x^2)+(y^2)]),{x,y,z}∈p])/vol)

ClosestMeanCylindricalRadius[%]

Integrate over polyhedron

(rxy=((Integrate[(Sqrt[(x^2)+(y^2)]),{x,y,z}∈p])/vol)//FullSimplify)

N[rxy]

Divergence theorem

(rxy=MeanCylindricalRadius[p,"Simplification"->FullSimplify,Debug->True])//Timing

N[rxy]

LogSimplify[rxy]//FullSimplify

CAD

cad=CylindricalDecomposition[PolyhedronData[pname,"RegionFunction"][x,y,z],{x,y,z},"Function"]

((NIntegrate[(Sqrt[(x^2)+(y^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol)

(rxy=((Integrate[(Sqrt[(x^2)+(y^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol))//Timing

CAD over  1/XX

reg=FullSimplify[PolyhedronData[pname,"RegionFunction"][x,y,z]&&0<y<Tan[Pi/3]x&&z>0]

Show[Graphics3D[{Opacity[.2],p}],RegionPlot3D[ImplicitRegion[reg,{x,y,z}],PlotPoints->50]]

((Volume[ImplicitRegion[reg,{x,y,z}]])/vol)//FullSimplify

cad=CylindricalDecomposition[reg,{x,y,z},"Function"]

12((NIntegrate[(Sqrt[(x^2)+(y^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol)

(rxy=12((Integrate[(Sqrt[(x^2)+(y^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol))//Timing

N[rxy]

ByteCount[rxylog=LogSimplify[rxy,"ZeroTestNumericalPrecision"->10000,WorkingPrecision->10000,Debug->True]]//Timing

rxylog

FullSimplify[rxylog]

N[%]

MeanSphericalRadius

PolyhedronData[pname,"MeanSphericalRadius"]

((NIntegrate[(Sqrt[(x^2)+(y^2)+(z^2)]),{x,y,z}∈p])/vol)

ClosestMeanSphericalRadius[%]

Integrate over polyhedron

(rxyz=((Integrate[(Sqrt[(x^2)+(y^2)+(z^2)]),{x,y,z}∈p])/vol))//Timing

N[rxyz]

Divergence theorem

(rxyz=MeanSphericalRadius[p,"Simplification"->FullSimplify,Debug->True])//Timing

N[rxyz]

LogSimplify[rxyz]//FullSimplify

CAD

cad=CylindricalDecomposition[PolyhedronData[pname,"RegionFunction"][x,y,z],{x,y,z},"Function"]

((NIntegrate[(Sqrt[(x^2)+(y^2)+(z^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol)

(rxyz=((Integrate[(Sqrt[(x^2)+(y^2)+(z^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol))//Timing

N[rxyz,20]

rxysimp1=ResourceFunction["LogSimplify"][rxy]//FullSimplify

CAD over  1/XX

reg=FullSimplify[PolyhedronData[pname,"RegionFunction"][x,y,z]&&0<y<Tan[Pi/5]x]

Show[Graphics3D[{Opacity[.2],p}],RegionPlot3D[ImplicitRegion[reg,{x,y,z}],PlotPoints->50]]

((Volume[ImplicitRegion[reg,{x,y,z}]])/vol)//FullSimplify

cad=CylindricalDecomposition[reg,{x,y,z},"Function"]

XX((NIntegrate[(Sqrt[(x^2)+(y^2)+(z^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol)

(rxyz=XX((Integrate[(Sqrt[(x^2)+(y^2)+(z^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol))//Timing

ByteCount[rxyzlog=LogSimplify[rxyz,"ZeroTestNumericalPrecision"->10000,WorkingPrecision->10000,Debug->True]]//Timing

ByteCount[rxyzcollect=Collect[TrigToExp[rxyzlog],Log[_]]//RootReduce]//Timing

Boole Integrate doing z integral first

{{xmin,xmax},{ymin,ymax},{zmin,zmax}}=CoordinateBounds[p]

ineq=PolyhedronData[pname,"RegionFunction"][x,y,z]

(i1=Integrate[Boole[ineq](Sqrt[(x^2)+(y^2)+(z^2)]),{z,zmin,zmax}])//Timing

NIntegrate[(i1/vol),{x,xmin,xmax},{y,ymin,ymax}]

(i2=Integrate[(i1/vol),{x,xmin,xmax},{y,ymin,ymax}])//Timing

MeanSquareCylindricalRadius

PolyhedronData[pname,"MeanSquareCylindricalRadius"]

N[%]

((NIntegrate[(x^2)+(y^2),{x,y,z}∈p])/vol)

Integrate over Polyhedron

(rxy2=((Integrate[(x^2)+(y^2),{x,y,z}∈p])/vol)//FullSimplify)

N[rxy2]

Divergence theorem

(rxy2=MeanSquareCylindricalRadius[p,"Simplification"->FullSimplify,Debug->True])//Timing

MeanSquareSphericalRadius

PolyhedronData[pname,"MeanSquareSphericalRadius"]

((NIntegrate[(x^2)+(y^2)+(z^2),{x,y,z}∈p])/vol)

Integrate over polyhedron

(rxy2=((Integrate[(x^2)+(y^2)+(z^2),{x,y,z}∈p])/vol)//FullSimplify)

N[rxy2]

Integrate over region

reg=PolyhedronData[pname,"RegionFunction"][x,y,z]

(rxy=((Integrate[((x^2)+(y^2)+(z^2))Boole[reg],{x,y,z}∈FullRegion[3]])/vol))

Divergence theorem

(rxy2=MeanSquareSphericalRadius[p,"Simplification"->FullSimplify,Debug->True])//Timing

Boole Integrate doing z integral first

{{xmin,xmax},{ymin,ymax},{zmin,zmax}}==CoordinateBounds[p]

ineq=PolyhedronData[pname,"RegionFunction"][x,y,z]

(i1=Integrate[Boole[ineq]((x^2)+(y^2)+(z^2)),{z,zmin,zmax}])//Timing

NIntegrate[(i1/vol),{x,xmin,xmax},{y,ymin,ymax}]

(i2=Integrate[(i1/vol),{x,xmin,xmax},{y,ymin,ymax}])//Timing

Orientations

PolyhedronData[pname,"Orientations"]

PolyhedronData[pname,"DefaultOrientation"]

Show[PolyhedronData[{pname,#}],Boxed->False]&/@PolyhedronData[pname,"Orientations"]

Polygons

PolyhedronData[pname,"FaceCount"]

PolyhedronFaceTally[p]

Graphics3D/@PolyhedronData[pname,"Polygons"]

Show[%]

Polyhedra

polyhedra=PolyhedronData[pname,"Polyhedra"]

Length[polyhedra]

Graphics3D[polyhedra]

Graphics3D[Table[{Hue[(i/(Length[polyhedra]))],polyhedra[[i]]},{i,Length[polyhedra]}]]

PolyhedronData[pname,"PolyhedronIndices"]

Region

PolyhedronData[pname,"Region"]

RegionFunction

PolyhedronData[pname,"RegionFunction"]

{RegionPlot3D[ImplicitRegion[PolyhedronData[pname,"RegionFunction"][x,y,z],{x,y,z}]],
Graphics3D[p]}

Collect[#,{x,y,z},RootReduce]&/@PolyhedronInequalities[p,{x,y,z}]

ineq=FullSimplify[%]

ineq/.{x->#,y->#2,z->#3}

{Region@ImplicitRegion[ineq,{x,y,z}],Graphics3D[p]}

SurfaceArea

PolyhedronData[pname,"SurfaceArea"]

SurfaceArea[p]

Total[Area/@PolyhedronData[pname,"Polygons"]]

SurfaceArea[PolyhedronData[pname,"Region"]]

Volume

PolyhedronData[pname,"Volume"]

Volume[p]//FullSimplify

PolyhedronVolume[p]//FullSimplify

Volume[PolyhedronData[pname,"Region"]]//FullSimplify

Volume[ImplicitRegion[Evaluate@PolyhedronData[pname,"RegionFunction"][x,y,z],{x,y,z}]]//FullSimplify

Properties: {"Octahedron", "C4x"} == "Octahedron"

Initialization

<<MathWorld`Polyhedra`

p=PolyhedronData[pname="Octahedron","Polyhedron"]

vol=PolyhedronData[pname,"Volume"]

Centroid

PolyhedronData[pname,"Centroid"]

Graphics3D[{AbsolutePointSize[10],
Point[{0,0,0}],{Blue,Point[PolyhedronData[pname,"Centroid"]]},Opacity[.2],PolyhedronData[pname,"GraphicsComplex"]}]

RegionCentroid[p]

PolyhedronCentroid[p]

Circumsphere

sphere=PolyhedronData[pname,"Circumsphere"]

sphere=Circumsphere[p]

(sphere=MyCircumsphere[p])//Timing

Graphics3D[{{Opacity[.2],Yellow,sphere},p},Boxed->False]

Compound

PolyhedronData[pname,"Compound"]

Convex

PolyhedronData[pname,"Convex"]

ConvexPolyhedronQ[p]

ConvexHullOf

hullof=DeleteCases[Select[PolyhedronData[All],PolyhedronData[#,"ConvexHullName"]===pname&],pname]

GraphicsGrid[Partition[Graphics3D[{
{Green,Opacity[1],PolyhedronData[#,"Polyhedron"]},
{Blue,Opacity[.6],PolyhedronData[#,"ConvexHull","Polyhedron"]}},Boxed->False,PlotLabel->Style[PolyhedronData[#,"Name"],Directive[14,Black,Italic,FontFamily->"Times"]]]&/@hullof,UpTo[3]],Dividers->All,ImageSize->200]

DihedralAngles

PolyhedronData[pname,"DihedralAngles"]//Tally

SimplifyNumericallyDistinct[DihedralAngles[p]]//Tally

EdgeCount

PolyhedronData[pname,"EdgeCount"]

EdgeLengths

PolyhedronData[pname,"EdgeLengths"]

PolyhedronData[pname,"Lines"]/.Line[l_]:>EuclideanDistance@@l//FullSimplify//Union//Quiet

lens=SimplifyNumericallyDistinct[PolyhedronEdgeLengths[p]];//Quiet

(distinctlens=Mean/@Split[Sort[lens],Abs[#1-#2]<1.*^-10&])//N//Quiet

v=PolyhedronCoordinates[p];

colors=With[{n=Length[distinctlens]},Table[Hue[i/n],{i,0,n-1}]]

Graphics3D[{Thick,Sequence@@Nearest[Thread[distinctlens->colors],EuclideanDistance@@v[[#]]],Line[v[[#]]]}&/@PolyhedronEdges[p],Boxed->False]//Quiet

FaceCount

PolyhedronData[pname,"FaceCount"]

Faces

GeneralizedDiameter

PolyhedronData[pname,"GeneralizedDiameter"]

GeneralizedDiameter[p]//FullSimplify//Quiet

InertiaTensor

PolyhedronData[pname,"InertiaTensor"]

(i=((MomentOfInertia[p,{0,0,0}])/(Volume[p])))//Timing

PolyhedronInertiaTensor[p]//Timing

Insphere

PolyhedronData[pname,"Insphere"]

Insphere[p]

sphere=MyInsphere[p]

Graphics3D[{{Opacity[.5],p},{Red,sphere}},Boxed->False]

MeanCylindricalRadius

PolyhedronData[pname,"MeanCylindricalRadius"]

N[%]

((NIntegrate[(Sqrt[(x^2)+(y^2)]),{x,y,z}∈p])/vol)

Integrate over polyhedron

((NIntegrate[(Sqrt[(x^2)+(y^2)]),{x,y,z}∈p])/vol)//Timing

(rxy=((Integrate[(Sqrt[(x^2)+(y^2)]),{x,y,z}∈p])/vol))//Timing

CAD

cad=CylindricalDecomposition[PolyhedronData[pname,"RegionFunction"][x,y,z],{x,y,z},"Function"]

((NIntegrate[(Sqrt[(x^2)+(y^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol)

((Integrate[(Sqrt[(x^2)+(y^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol)//Timing

Inequalities

{{xmin,xmax},{ymin,ymax},{zmin,zmax}}=MinMax/@Transpose[PolyhedronCoordinates[p]]

ineq=PolyhedronData[pname,"RegionFunction"][x,y,z]

(i1=Integrate[Boole[ineq](Sqrt[(x^2)+(y^2)]),{z,zmin,zmax}])//Timing

NIntegrate[(i1/vol),{x,xmin,xmax},{y,ymin,ymax}]

(i2=Integrate[(i1/vol),{x,xmin,xmax},{y,ymin,ymax}])//Timing

One integral at a time from inequalities

ineq=PolyhedronData[pname,"RegionFunction"][x,y,z]//FullSimplify

MaxValue[{#,ineq},{x,y,z}]&/@{x,y,z}

((8NIntegrate[(Sqrt[(x^2)+(y^2)])Boole[ineq],{x,0,∞},{y,0,∞},{z,0,∞}])/(PolyhedronData[pname,"Volume"]))

((16NIntegrate[(Sqrt[(x^2)+(y^2)])Boole[ineq],{x,0,∞},{y,x,∞},{z,0,∞}])/(PolyhedronData[pname,"Volume"]))

(i1=Assuming[0<x<y<1/Sqrt[2],FullSimplify[Integrate[(Sqrt[(x^2)+(y^2)])Boole[ineq],{z,0,∞}]]])//Timing

(i2=Assuming[0<x<1/Sqrt[2],FullSimplify[Integrate[i1,{y,x,1/Sqrt[2]}]]])//Timing

((16NIntegrate[i2,{x,0,1/Sqrt[2]}])/(PolyhedronData[pname,"Volume"]))

(i3=Integrate[i2,{x,0,1/Sqrt[2]}])//Timing

FullSimplify[((16i3)/(PolyhedronData[pname,"Volume"]))]

N[%]

Table[(((1+Sqrt[2]))^n),{n,4}]//Expand

(1/32) (4 (Sqrt[2])+4Log[1+Sqrt[2]])//FullSimplify

N[%]

MeanInteriorLineSegmentLength

lbar=PolyhedronData[pname,"MeanInteriorLineSegmentLength"]

N[%]

Dominik Beck.  "Mean distance in polyhedra."  https://arxiv.org/abs/2309.13177

N[((((3/4)))^(1/3))((4/105)+((13(Sqrt[2]))/105)-((4Pi)/45)+((109Log[3])/(630Sqrt[2]))+((16ArcCot[(Sqrt[2])])/315)+((158(Sqrt[2])ArcCoth[(Sqrt[2])])/315))]

Solve[vol (a^3)==1,a,PositiveReals]//FullSimplify

1/((3^(1/3))/(2^(1/6)))((((3/4)))^(1/3))((4/105)+((13(Sqrt[2]))/105)-((4Pi)/45)+((109Log[3])/(630Sqrt[2]))+((16ArcCot[(Sqrt[2])])/315)+((158(Sqrt[2])ArcCoth[(Sqrt[2])])/315))//FullSimplify//Expand

N[(13/105)+((2 (Sqrt[2]))/105)-((2 (Sqrt[2]) π)/45)+(8/315) (Sqrt[2]) ArcCot[(Sqrt[2])]+((158 ArcCoth[(Sqrt[2])])/315)+((109 Log[3])/1260)]

ineq=PolyhedronData[pname,"RegionFunction"]

{{xmin,xmax},{ymin,ymax},{zmin,zmax}}=RegionBounds[ImplicitRegion[ineq[x,y,z],{x,y,z}]]

(1/(vol^2)) NIntegrate[Sqrt[(x1-x2)^2+(y1-y2)^2+(z1-z2)^2]Boole[ineq[x1,y1,z1]&&ineq[x2,y2,z2]],
{x1,xmin,xmax},{y1,ymin,ymax},{z1,zmin,zmax},
{x2,xmin,xmax},{y2,ymin,ymax},{z2,zmin,zmax}]

(1/(vol^2)) NIntegrate[Sqrt[(x1-x2)^2+(y1-y2)^2+(z1-z2)^2]Boole[ineq[x1,y1,z1]&&ineq[x2,y2,z2]],
{x1,xmin,xmax},{y1,ymin,ymax},{z1,zmin,zmax},
{x2,xmin,xmax},{y2,ymin,ymax},{z2,zmin,zmax},
Method->{"GlobalAdaptive","MaxErrorIncreases"->1*^4}]//Timing

Monte Carlo

reg=PolyhedronData[pname,"Region"]

Length[lines=Partition[RandomPoint[N@reg,10^7],2]]//Timing

Graphics3D[{{Opacity[.03],EdgeForm[],DiscretizeRegion[reg]},Red,Line/@Take[lines,UpTo@1000]},AspectRatio->Automatic]

lengths=Norm/@Subtract@@@lines;//Timing

Histogram[lengths,{.01}]

Mean[lengths]

MeanSquareCylindricalRadius

PolyhedronData[pname,"MeanSquareCylindricalRadius"]

((Integrate[(x^2)+(y^2),{x,y,z}∈p])/vol)

Rule[#,((Integrate[(x^2)+(y^2),{x,y,z}∈PolyhedronData[{"Octahedron",#},"Polyhedron"]])/vol)]&/@PolyhedronData["Octahedron","Orientations"]

MeanSphericalRadius

PolyhedronData[pname,"MeanSphericalRadius"]

((NIntegrate[(Sqrt[(x^2)+(y^2)+(z^2)]),{x,y,z}∈p])/vol)

ClosestMeanCylindricalRadius[%]

Integrate [unevaluated]

(rxy=((Integrate[(Sqrt[(x^2)+(y^2)+(z^2)]),{x,y,z}∈p])/vol))//Timing

Divergence theorem [wrong complex integral]

(rxy=MeanSphericalRadius[p,"Simplification"->FullSimplify,Debug->True])//Timing

CAD

cad=CylindricalDecomposition[PolyhedronData[pname,"RegionFunction"][x,y,z],{x,y,z},"Function"]

((NIntegrate[(Sqrt[(x^2)+(y^2)+(z^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol)

(rxyz=((Integrate[(Sqrt[(x^2)+(y^2)+(z^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol))//Timing

CAD over  1/16 [unevaluated]

reg=FullSimplify[PolyhedronData[pname,"RegionFunction"][x,y,z]&&0<y<x&&z>0]

cad=CylindricalDecomposition[reg,{x,y,z},"Function"]

16((NIntegrate[(Sqrt[(x^2)+(y^2)+(z^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol)

(rxy=16((Integrate[(Sqrt[(x^2)+(y^2)+(z^2)])Boole[cad],{x,y,z}∈FullRegion[3]])/vol))//Timing

N[rxy,20]

ResourceFunction["LogSimplify"][rxy]//FullSimplify

One integral at a time from inequalities

ineq=PolyhedronData[pname,"RegionFunction"][x,y,z]//FullSimplify

MaxValue[{#,ineq},{x,y,z}]&/@{x,y,z}

((8NIntegrate[(Sqrt[(x^2)+(y^2)+(z^2)])Boole[ineq],{x,0,∞},{y,0,∞},{z,0,∞}])/vol)

((16NIntegrate[(Sqrt[(x^2)+(y^2)+(z^2)])Boole[ineq],{x,0,∞},{y,x,∞},{z,0,∞}])/vol)

((16NIntegrate[(Sqrt[(x^2)+(y^2)+(z^2)])Boole[ineq],{x,0,∞},{y,0,x},{z,0,∞}])/vol)

(i1=Assuming[0<x<y<1/Sqrt[2],FullSimplify[Integrate[(Sqrt[(x^2)+(y^2)+(z^2)])Boole[ineq],{z,0,1/(Sqrt[2])}]]])//Timing

(i2=Assuming[0<x<1/Sqrt[2],FullSimplify[Integrate[i1,{y,0,x}]]])//Timing

(i1=Assuming[0<x<1/Sqrt[2]&&0<z<1/(Sqrt[2]),FullSimplify[Integrate[(Sqrt[(x^2)+(y^2)+(z^2)])Boole[ineq],{y,0,x}]]])//Timing

(i2=Assuming[0<x<1/Sqrt[2],FullSimplify[Integrate[i1,{z,0,1/(Sqrt[2])}]]])//Timing

((16NIntegrate[i2,{x,0,1/Sqrt[2]}])/(PolyhedronData[pname,"Volume"]))

(i3=Integrate[i2,{x,0,1/Sqrt[2]}])//Timing

FullSimplify[((16i3)/(PolyhedronData[pname,"Volume"]))]

N[%]

Table[(((1+Sqrt[2]))^n),{n,4}]//Expand

MeanSphericalSquareRadius

PolyhedronData[pname,"MeanSquareSphericalRadius"]

((Integrate[(x^2)+(y^2)+(z^2),{x,y,z}∈p])/vol)

Rule[#,((Integrate[(x^2)+(y^2)+(z^2),{x,y,z}∈PolyhedronData[{pname,#},"Polyhedron"]])/vol)]&/@PolyhedronData["Octahedron","Orientations"]

NotationRules

PolyhedronData[pname,"NotationRules"]

Orientations

PolyhedronData[pname,"Orientations"]

PolyhedronData[pname,"DefaultOrientation"]

Region

PolyhedronData[pname,"Region"]

RegionFunction

PolyhedronData[pname,"RegionFunction"][x,y,z]

FullSimplify[%]

Collect[#,{x,y,z},RootReduce]&/@PolyhedronInequalities[p,{x,y,z}]

FullSimplify[%]

%146/.{x->#1,y->#2,z->#3}

SimplePolyhedron

PolyhedronData[pname,"Simple"]

SimplePolyhedronQ[p]

Skeleton

PolyhedronData[pname,"Skeleton"]

PolyhedronData[pname,"Skeleton","Name"]

SurfaceArea

PolyhedronData[pname,"SurfaceArea"]

SurfaceArea[p]//Timing

Total[Area/@PolyhedronData[pname,"Polygons"]]//Timing

VertexCount

PolyhedronData[pname,"FaceCount"]

VertexSubsetHulls

PolyhedronData[pname,"VertexSubsetHulls"]

Platonic

(h=VertexSubsetHulls[p,"Platonic","Skip"->{}])//Timing

Volume

PolyhedronData[pname,"Volume"]

Volume[p]//FullSimplify

PolyhedronVolume[p]//FullSimplify

Properties: {"Octahedron", "C4"}

Initialization

<<MathWorld`Polyhedra`

p=PolyhedronData[pname={"Octahedron","C4"},"Polyhedron"]

MeanCylindricalRadius

((NIntegrate[(Sqrt[(x^2)+(y^2)]),{x,y,z}∈p])/(PolyhedronData[pname,"Volume"]))

((NIntegrate[(Sqrt[(x^2)+(y^2)]),{x,y,z}∈PolyhedronData["Octahedron","Polyhedron"]])/vol)

(rxy=((Integrate[(Sqrt[(x^2)+(y^2)]),{x,y,z}∈p])/vol))//Timing

N[%]

ineq=PolyhedronData[pname,"RegionFunction"][x,y,z]//FullSimplify

MaxValue[{#,ineq},{x,y,z}]&/@{x,y,z}

2NIntegrate[(Sqrt[(x^2)+(y^2)])Boole[ineq],{x,-∞,∞},{y,-∞,∞},{z,0,∞}]

(i=Integrate[(Sqrt[(x^2)+(y^2)])Boole[ineq],{x,-∞,∞}])//Timing

NotationRules

PolyhedronData[pname,"NotationRules"]

Projections

PolyhedronProjectionGraph[PolyhedronData["Octahedron","Polyhedron"],#]&/@{{0,0,1},{0,1,1},{1,0,3},{1,1,1},{2,1,1},{3,1,1},{2,1,5}}

GraphData["OctahedralGraph","Graph","Perspective"]

Vertex subset hulls

VertexSubsetHulls["Octahedron","Platonic"]//Timing

Construction

OctahedronExact:=OctahedronExact=octahedron[1]

OctahedronExactZ:=OctahedronExactZ=Antiprism[3]

octahedron1:=Module[{i,j,k},
		Graphics3D[Table[Polygon[{{i,0,0},{0,j,0},{0,0,k}}],
			{i,-1,1,2},{j,-1,1,2},{k,-1,1,2}]]]

octahedron2:=Module[{t=Sqrt[2]},
	Graphics3D[{
	Polygon[{{-1,-1,0},{1,-1,0},{0,0,t}}],Polygon[{{-1,-1,0},{1,-1,0},{0,0,-t}}],
	Polygon[{{-1,1,0},{1,1,0},{0,0,t}}],Polygon[{{-1,1,0},{1,1,0},{0,0,-t}}],
	Polygon[{{1,-1,0},{1,1,0},{0,0,t}}],Polygon[{{-1,-1,0},{-1,1,0},{0,0,t}}],
	Polygon[{{1,-1,0},{1,1,0},{0,0,-t}}],Polygon[{{-1,-1,0},{-1,1,0},{0,0,-t}}]
	}]
]

(* s = Sqrt[2] *)

octahedron[s0_:1]:=Module[{s=s0/Sqrt[2]},
	Orient[{
	Polygon[{{0,0,s},{s,0,0},{0,s,0}}],
	Polygon[{{0,0,s},{0,s,0},{-s,0,0}}],
	Polygon[{{0,0,s},{-s,0,0},{0,-s,0}}],
	Polygon[{{0,0,s},{0,-s,0},{s,0,0}}],
	Polygon[{{s,0,0},{0,-s,0},{0,0,-s}}],
	Polygon[{{s,0,0},{0,0,-s},{0,s,0}}],
	Polygon[{{0,0,-s},{0,-s,0},{-s,0,0}}],
	Polygon[{{0,s,0},{0,0,-s},{-s,0,0}}]
	}]
]

<<PolyhedronOperations`

Show[Graphics3D[Polyhedron[Octahedron,"C4Square"]]]

(Subscript[C, 4])Diamond

poly=Polyhedron[Octahedron,"C4Square"]/.Polygon[x_]:>Polygon[RotationMatrixZ[Pi/4].#&/@x];

Show[Graphics3D[poly]]

poly2=Map[Simplify,Flatten[poly],{3}];
(v=PolyhedronVertices[poly2])//InputForm
First/@poly2/.Thread[v->Range[Length[v]]]

(Subscript[C, 2])

θ=ArcCos[FullSimplify[Divide@@Through[{Midradius,Circumradius}[Octahedron]]]]

Show[Graphics3D[poly=FullSimplify[(Polyhedron[Octahedron]/.Polygon[x_]:>Polygon[RotationMatrixZ[π/4].#&/@x])/.Polygon[x_]:>Polygon[RotationMatrixY[θ].#&/@x]],ViewPoint->2{0,0,1}]]

FullSimplify[RootReduce[poly[[1,#[[1]],1,#[[2]]]]&/@(First[Position[PolyhedronFaces[Octahedron],#]]&/@Range[6])]]//InputForm

(Subscript[C, 3])

θ=ArcCos[FullSimplify[Divide@@Through[{Inradius,Circumradius}[Octahedron]]]]

Show[Graphics3D[poly=FullSimplify[Polyhedron[Octahedron]/.Polygon[x_]:>Polygon[RotationMatrixY[θ].#&/@x]]],ViewPoint->2{0,0,1}]

FullSimplify[RootReduce[poly[[1,#[[1]],1,#[[2]]]]&/@(First[Position[PolyhedronFaces[Octahedron],#]]&/@Range[6])]]//InputForm

Inequalities

WriteLiveForm["octineq.m",
InequalityPlot3D[ Abs[x]+Abs[y]+Abs[z]≤1, {x, -1, 1}, {y, -1, 1}, {z, -1, 1},Boxed->True,opts]
]

<<Graphics`InequalityGraphics`

i=FullSimplify[PolyhedronInequalities[Polyhedron[Octahedron],{x,y,z}]][[1]]

Integrate[Boole[And@@i],{x,-∞,∞},{y,-∞,∞},{z,-∞,∞}]

InequalityPlot3D[Abs[x]+Abs[y]+Abs[z]<1,{x},{y},{z}]

Integrate[Boole[Abs[x]+Abs[y]+Abs[z]<1],{x},{y},{z}]

Table[{n,Integrate[# Boole[Abs[x]+Abs[y]+Abs[z]<1],{x},{y},{z}]&/@({x,y,z}^n)},{n,6}]//ColumnForm

Octahedron hexagon

octahedron:=Module[{i,j,k},
		Flatten[Table[Polygon[{{i,0,0},{0,j,0},{0,0,k}}],
			{i,-1,1,2},{j,-1,1,2},{k,-1,1,2}]]
];

hexagonOct:=Module[{h=1/2},
		{{h,-h,0},{h,0,h},{0,h,h},{-h,h,0},
				{-h,0,-h},{0,-h,-h}}
]

WriteLiveForm["octhex1.m",
		Show[Graphics3D[SplitLines[{hexagonOct,frame[octahedron[1]]},1]],
		Boxed->False,ViewPoint->{.3,-2,.5}]]

WriteLiveForm["octhex2.m",
	Show[PolyhedronPolygon[octahedron,hexagonOct],
		opts,ViewPoint->{.3,-2,.5}]]

Show[GraphicsArray[{
	Show[Graphics3D[{hexagonOct,frame[octahedron]}],
		Boxed->False,ViewPoint->{.3,-2,.5},DisplayFunction->Identity],
	Show[Graphics3D[{line[hexagonOct[[1]]],octahedron[[1]]}],
		Boxed->False,ViewPoint->{.3,-2,.5},DisplayFunction->Identity]}],
	DisplayFunction->$DisplayFunction]

Octahedral loop

Stan Wagon
Oct 30, 2013

p0=PolyhedronData["Octahedron"][[1]];
v=PolyhedronData["Octahedron", "Faces"];
p1=GraphicsComplex[p0[[1]]/. {x_, y_, z_} :> RotationMatrix[π/4, {0,0,1}].({x,y,z} ), p0[[2]]];
verts=p1[[1]];
vec=Mean[verts[[{3,5,6}]]];
vec1=Mean[verts[[{3,1,2}]]];
rot = RotationMatrix[π/3,vec];
rot1 = RotationMatrix[π/3,vec{-1,1,1}];

imOct=Graphics3D[{{PointSize[.02], Thickness[.01],Line[verts[[{6,3,5}]]];
Line[verts[[{1,2,3}]]]};
xxx={
{Red,p1}, 
{Blue,p2=GraphicsComplex[p1[[1]]/. {x_, y_, z_} :> rot.({x,y,z} + 2 vec), p1[[2]]]},
{Red,p3= GraphicsComplex[p1[[1]]/. {x_, y_, z_} :> rot.rot.({x,y,z} +4 vec), p1[[2]]]},
{Blue,p4=GraphicsComplex[p1[[1]]/. {x_, y_, z_} :> rot1.({x,y,z} +2 vec1), p1[[2]]]},
{Red, p5=GraphicsComplex[p1[[1]]/. {x_, y_, z_} :> rot1.rot1.({x,y,z} +4 vec1), p1[[2]]]},
{Red,p6=GraphicsComplex[p1[[1]]/. {x_, y_, z_} :> {x,y,z} +{0,0,-2(ww=2Sqrt[2]/3 )}, p1[[2]]]},

{Yellow,FaceForm@Blue,p7=GraphicsComplex[p2[[1]]/. {x_, y_, z_} :> ({x,y,-2 ww -z}) , p2[[2]]]},

{Yellow,FaceForm@Blue,p8=GraphicsComplex[p4[[1]]/. {x_, y_, z_} :> ({x,y,-2 ww -z}) , p4[[2]]]},

},
Line[{{0,0,0},  4 vec}];{}
}, Axes->None, Boxed->False, PlotRange->({{-2,2}, {-.8,.8}, {-2.7,.8}}),Lighting->"Neutral"]/. Blue->Lighter@Lighter@Blue/. Red->Lighter@Red

POV-Ray

Octahedron=x^8+14x^4 y^4+y^8;
POVCoefficients[Octahedron,{x,y,z}]

Stellation

FaceIntersections[poly_]:=Module[{pairs=KSubsets[Take[#,3]&/@First/@poly,2]},
DeleteCases[Intersection3D@@@Map[Plane,pairs,{2}],{}]
]

poly=Octahedron;
Show[Graphics3D[{Polyhedron[poly],{Red,lines=FaceIntersections[Polyhedron[poly]]},PointSize[.02],points=Intersection3D@@@KSubsets[lines,2]}]]