答案1
以下是孙子和普通的曾孙:
\documentclass[12pt]{article}
\usepackage{geometry}
\geometry{left=1.0in,right=1.0in,top=1.0in,bottom=1.0in}
\usepackage{setspace}
\usepackage{float}
\usepackage{ulem}
\usepackage{caption,subcaption}
\usepackage{tikz}
\usetikzlibrary{shapes,arrows,intersections,arrows.meta,shadows,positioning}
\usepackage[unicode, bookmarks, colorlinks, breaklinks]{hyperref}
\hypersetup{colorlinks=true, pdfstartview=FitV, linkcolor=blue, citecolor=black, plainpages=false, pdfpagelabels=true, urlcolor=blue}
\normalem
\onehalfspacing
\begin{document}
\begin{figure}[H]
\centering
\begin{tikzpicture}[
sibling distance=6cm,
edge from parent/.append style={->},
growth parent anchor=south,
>=Latex,
nodes={draw, fill=cyan,
text width=4cm,
text centered}
]
% root of the the initial tree, level 1
\node (root) {Grandpa}
% The first level, as children of the initial tree
child {node {Father}
child {node (C1) {Child}
child {node (C11) {Grand child}}}
child {node (C2) {Child}
child {node (C21) {Grand child}
child {node (C211) {Grand grand child}}}
}
child {node (C3) {Child}
child {node (C31) {Grand child}}}
};
\draw [->] (C31) -- (C211);
\draw [->] (C11) -- (C211);
\end{tikzpicture}
\caption{Common Grandchild}
\label{fig: Causal}
\end{figure}
\end{document}