Draw an icosahedron with triangulated faces

diagramspst-solides3dtikz-pgf

I would like to draw something like this by using TikZ. Here I have found several answers on how to draw such a Platonic solid but no one has the faces divided like this. I do not really care about colours. What really matters to me is to draw such icosahedron as an origami like the picture below. Here I've found a way fro drawing an icosahedron but without subdivision of the faces.

How can I do?

Thanks!

enter image description here

Best Answer

You can find the needed points in each triangle with the calc library: they are the midpoint of each edge and the centroid of the triangles. Then you can make a macro to draw a triangle with those divisions.

Something like this:

\documentclass[tikz,border=2mm]{standalone}
\usetikzlibrary{calc,perspective}

\definecolor{color1}{HTML}{1A5960}
\definecolor{color2}{HTML}{B7DAB9}
\definecolor{color3}{HTML}{AE5689}

\newcommand{\mytriangle}[4] % 3 poiints, 'shadow' opacity
{
  \coordinate (center) at ($1/3*(#1)+1/3*(#2)+1/3*(#3)$);
  \coordinate (m12)    at ($(#1)!0.5!(#2)$);
  \coordinate (m13)    at ($(#1)!0.5!(#3)$);
  \coordinate (m23)    at ($(#2)!0.5!(#3)$);
  \draw[fill=color1] (center) -- (m12) -- (#1) -- (m13) -- cycle;
  \draw[fill=color2] (center) -- (m12) -- (#2) -- (m23) -- cycle;
  \draw[fill=color3] (center) -- (m13) -- (#3) -- (m23) -- cycle;
  \draw[thick,fill=black,fill opacity=#4]  (#1) -- (#2)  -- (#3) -- cycle;
}

\begin{document}
\begin{tikzpicture}[line cap=round,line join=round,3d view={40}{35}]
% Dimensiones
\pgfmathsetmacro\ph{(1+sqrt(5))/2} % golden ratio
\pgfmathsetmacro\ed{3}             % edge   (half)
\pgfmathsetmacro\hh{\ed*\ph}       % height (half)
% VĂ©rtices
\coordinate (A1) at ( \hh,-\ed,  0);
\coordinate (B1) at ( \hh, \ed,  0);
\coordinate (C1) at (-\hh, \ed,  0);
\coordinate (D1) at (-\hh,-\ed,  0);
\coordinate (A2) at ( \ed,  0,-\hh);
\coordinate (B2) at (-\ed,  0,-\hh);
\coordinate (C2) at (-\ed,  0, \hh);
\coordinate (D2) at ( \ed,  0, \hh);
\coordinate (A3) at (  0, \hh,-\ed);
\coordinate (B3) at (  0, \hh, \ed);
\coordinate (C3) at (  0,-\hh, \ed);
\coordinate (D3) at (  0,-\hh,-\ed);
% Faces
\mytriangle{A2}{A1}{D3}{0.4};
\mytriangle{A1}{B1}{A2}{0.5};
\mytriangle{D1}{C3}{D3}{0.2};
\mytriangle{A1}{D3}{C3}{0.3};
\mytriangle{C3}{D2}{A1}{0.0};
\mytriangle{B1}{A1}{D2}{0.1};
\mytriangle{D2}{B3}{B1}{0.3};
\mytriangle{C2}{D1}{C3}{0.2};
\mytriangle{D2}{C3}{C2}{0.1};
\mytriangle{B3}{C2}{D2}{0.2};
\end{tikzpicture}
\end{document}

enter image description here

Related Question