# How to draw a truncated triangle? TikZ or PSTricks

I would like to draw the following diagram.

How do I do it? I tried this:

\documentclass{article}

\usepackage{tikz}
\usepackage{pst-poly}

\begin{document}
\begin{pspicture}
\PstTriangle
\PstHexagon[linestyle=dashed]
\end{pspicture}
\end{document}


But this is nowhere near what I desire.

• Could you give some details on what's not working? Oct 16 '20 at 10:37
• @Bernard There is no problem with the MWE. It is just that I have no idea how to create the image I desire. Using pst-poly package, I can create, a hexagon and a triangle but not how to put one into the another. Oct 16 '20 at 10:43
• Do you want an equilateral triangle or any triangle? Oct 16 '20 at 10:52
• @Bernard An equilateral triangle would be better but any triangle would suffice. Oct 16 '20 at 11:38

Here is a way to go with pst-eucl:

\documentclass{article}

\usepackage{pst-eucl}

\begin{document}

\begin{pspicture}
\psset{linejoin=1, PointSymbol=none, dash=3pt 2pt, arrowsize=3pt, arrowinset=0.12}
\pstGeonode[PosAngle=90](0,3){A}
\pstTriangleSSS[PosAngle={-135,-45}](U){A}(4,4,4){B}{C}
\pstHomO[HomCoef=0.65, PosAngle={180,0}]{A}{B, C}[F, G]
\psset{HomCoef=0.35}
\pstHomO[PosAngle={180,0}]{A}{B, C}[D, E]
\psset{PosAngle=-90} \pstHomO{B}{C}[H] \pstHomO{C}{B}[K]
\foreach \s/\t in {D/E, F/H, G/K} {\psline[linestyle=dashed](\s)(\t)}
%%Translated polygon:
\pstTranslation[DistCoef=1.5, PointName=none]{B}{C}{D,E,F,G,H,K}[D1,E1,F1,G1,H1,K1]
\pspolygon(D1)(E1)(G1)(K1)(H1)(F1)
\ncline[nodesepA=1.3cm, nodesepB=0.7cm]{->}{G}{F1}
\end{pspicture}

\end{document}


• Thanks for answering. But the above code doesn't produce the same image on my system. It just produces a vertical line with an arrow and letters placed on top of each other. I compiled with XeLaTeX, fully updated. Thanks for letting me know about the pst-eucl package. Btw, is there any way to remove the letter labels? Oct 16 '20 at 16:19
• I too compiled with xelatex. Did you compile with the --shell-escape switch? To remove the point names, just use \psset{PointName=none} as I did for the translated hexagon. I let the points being displayed just to make the code easier to follow. Further, you'll have the possibility to remove all the PositionAngle= which will be useless. Oct 16 '20 at 17:00
• The code works flawlessly on Overleaf. But I can't figure out why it doesn't work on my system. I tried with --shell-escape and without it as well. I've installed TeXLive Full (freshly updated) on Manjaro; it doesn't give any errors as well. Oct 16 '20 at 17:16

Another solution with TikZ but using intersections and shift.

## Code

\documentclass[tikz, margin=10pt]{standalone}

\usetikzlibrary{calc, intersections, arrows.meta}

\newcommand\bisec{3cm} % distance from corner to center
\newcommand\myshift{\bisec*2.5} % shifting polygon

\begin{document}
\begin{tikzpicture}
\draw[thick, name path=triangle]
($(0,0)+(90:\bisec)$) node[above] {$A$} --
($(0,0)+(210:\bisec)$) node[below left] {$B$} --
($(0,0)+(-30:\bisec)$) node[below right] {$C$} -- cycle;

\path[name path=inverse triangle]
($(0,0)+(270:\bisec)$) --
($(0,0)+(150:\bisec)$) --
($(0,0)+(30:\bisec)$) -- cycle;

\path[%
name intersections={of=triangle and inverse triangle,
by={F,D,H,K,E,G}}]
\foreach \s in {F,D,H,K,E,G}{(\s)}; % replace \path with \fill and add "circle (2pt)" after (\s), to see the intersections

\draw[thick,dashed]
(F) node[left] {$F$} -- (H) node[below] {$H$}
(D) node[left] {$D$} -- (E) node[right] {$E$}
(K) node[below] {$K$} -- (G) node[right] {$G$};
%
\draw[thick, -{Stealth}] ($(0,0)+(0:\bisec)$) -- ($(\myshift,0)+(-\bisec,0)$);
\draw[thick]
($(F)+(\myshift,0)$) -- ($(D)+(\myshift,0)$) --
($(E)+(\myshift,0)$) -- ($(G)+(\myshift,0)$) --
($(K)+(\myshift,0)$) -- ($(H)+(\myshift,0)$) -- cycle;

\end{tikzpicture}
\end{document}


Using TiKz:

\documentclass[tikz,margin=3mm]{standalone}

\usetikzlibrary{shapes.geometric}

\begin{document}

\begin{tikzpicture}
\node (H) at (0,0)[regular polygon, regular polygon sides=6,
minimum size=4cm, draw, dashed] {};
\draw (H.corner 1)--++(120:2)coordinate(U)--(H.corner 2);
\draw (H.corner 3)--++(240:2)coordinate(L)--(H.corner 4);
\draw (H.corner 5)--++(0:2)coordinate(R)--(H.corner 6);
\draw [thick](U)--(L)--(R)--cycle;

\begin{scope}[xshift=2cm]
\node (S) at (6,0)[regular polygon, regular polygon sides=6,
minimum size=4cm, draw] {};
\draw [latex-,shorten >=1.5cm,shorten <=0.5cm](S.corner 3)--(180:0.5);
\end{scope}
\end{tikzpicture}

\end{document}