Skip to main content
added 10 characters in body
Source Link
Sjoerd C. de Vries
  • 66.4k
  • 15
  • 192
  • 337

You can plot it using the GraphLayout option, which has, since v9, the "PlanarEmbedding" as a possible value:

You can plot it using the GraphLayout option, which has, since v9, the "PlanarEmbedding" value:

You can plot it using the GraphLayout option, which has, since v9, "PlanarEmbedding" as a possible value:

trim baroque programming
Source Link
Mr.Wizard
  • 275.2k
  • 34
  • 606
  • 1.5k
truncatedCube = {{0, 1, 1, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1}, {1, 0, 1, 0, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1}, {1, 1, 0, 1, 1, 0, 0, 0, 1, 1, 0, 0, 1, 1}, {1, 0, 1, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0}, {0, 1, 1, 1, 0, 1, 1, 0, 1, 0, 1, 0, 1, 0}, {1, 1, 0, 1, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0}, {0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0}, {1, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {1, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 1, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0}, {1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 1, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}}; AdjacencyGraph[truncatedCube, GraphLayout -> "PlanarEmbedding", VertexLabels -> Thread[Range[Length@truncatedCube]Array[# -> Range[Length@truncatedCube]]# &, Length @ truncatedCube], PlotRangePadding -> 0.5] 
truncatedCube = {{0, 1, 1, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1}, {1, 0, 1, 0, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1}, {1, 1, 0, 1, 1, 0, 0, 0, 1, 1, 0, 0, 1, 1}, {1, 0, 1, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0}, {0, 1, 1, 1, 0, 1, 1, 0, 1, 0, 1, 0, 1, 0}, {1, 1, 0, 1, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0}, {0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0}, {1, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {1, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 1, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0}, {1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 1, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}}; AdjacencyGraph[truncatedCube, GraphLayout -> "PlanarEmbedding", VertexLabels -> Thread[Range[Length@truncatedCube] -> Range[Length@truncatedCube]], PlotRangePadding -> 0.5] 
truncatedCube = {{0, 1, 1, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1}, {1, 0, 1, 0, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1}, {1, 1, 0, 1, 1, 0, 0, 0, 1, 1, 0, 0, 1, 1}, {1, 0, 1, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0}, {0, 1, 1, 1, 0, 1, 1, 0, 1, 0, 1, 0, 1, 0}, {1, 1, 0, 1, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0}, {0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0}, {1, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {1, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 1, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0}, {1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 1, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}}; AdjacencyGraph[truncatedCube, GraphLayout -> "PlanarEmbedding", VertexLabels -> Array[# -> # &, Length @ truncatedCube], PlotRangePadding -> 0.5] 
added 50 characters in body
Source Link
Sjoerd C. de Vries
  • 66.4k
  • 15
  • 192
  • 337

You can plot it using the GraphLayout option, which has, since v9, the "PlanarEmbedding" value:

You can plot it using the GraphLayout option:

You can plot it using the GraphLayout option, which has, since v9, the "PlanarEmbedding" value:

added 110 characters in body
Source Link
Sjoerd C. de Vries
  • 66.4k
  • 15
  • 192
  • 337
Loading
deleted 10 characters in body
Source Link
Sjoerd C. de Vries
  • 66.4k
  • 15
  • 192
  • 337
Loading
Source Link
Sjoerd C. de Vries
  • 66.4k
  • 15
  • 192
  • 337
Loading