{a, b, c} = {{1, 0, 0}, {0, 1, 0}, {0, 0, 1}};
f[{a_, b_, c_}] := {{a, Mean[{a, b}], Mean[{a, c}]}, {b, Mean[{b, c}],
Mean[{b, a}]}, {c, Mean[{c, a}], Mean[{c, b}]}};
Nest[Flatten[Map[f, #], 1] &, f[{a, b, c}], 4] //
Graphics3D[Triangle /@ #, ViewPoint -> {1, 1, 1.2}] &
原来还有更方便的做法:
RegionPlot3D[SierpinskiMesh[4, 2], ColorFunction -> "Rainbow",
PlotLegends -> {LegendLayout -> "ReversedColumn"}]