我有三个图表,树状图,我想把它们整齐地组织起来。我希望 a 和 b 彼此相邻,两者占用的水平空间都是 c 的一半。C 应该在下面。
我还希望树 a 和 b 垂直对齐,即两者的顶部位于同一水平,而且它们的标题从同一水平开始。
这让我很头疼。目前我还在努力完成手头的第一个任务。它们全都漂浮在垂直的柱子上。
\usepackage{tikz}
\usetikzlibrary{shapes,arrows,arrows}
\usepackage{subcaption}
\begin{figure}[t]
\centering
\begin{subfigure} [t] {0.4\textwidth}
\centering
\begin{tikzpicture}[>=stealth',shorten >=3pt,auto,node distance=14mm,
main node/.style={font=\sffamily},
small node/.style={font=\sffamily,color={black!50} }]
\node[main node] (12) {$(1,2)$};
%
\node[main node] (1) [below of=12] {$ (1) $};
\node[small node] (2) [right of=1] {$ (2) $};
\draw (12) edge (1) ;
\end{tikzpicture}
\caption{3-simplex Voronoi Regions}
\label{fig:3-simplex voronoi regions}
\end{subfigure}
\begin{subfigure} [t] {0.4\textwidth}
\centering
\begin{tikzpicture}[>=stealth',shorten >=3pt,auto,node distance=14mm,
main node/.style={font=\sffamily},
small node/.style={font=\sffamily,color={black!50} }]
\node[main node] (123) {$ (1,2,3) $};
%
\node[main node] (12) [below of=123] {$(1,2)$};
\node[main node] (13) [right of=12] {$(1,3)$};
\node[small node] (23) [right of=13] {$(2,3)$};
%
\node[main node] (1) [below of=12] {$ (1) $};
\node[small node] (2) [right of=1] {$ (2) $};
\node[small node] (3) [right of=2] {$ (3) $};
\draw (123) edge (12) edge (13);
\draw (12) edge (1);
\draw (13) edge (1);
\end{tikzpicture}
\caption{2-simplex Voronoi Regions}
\label{fig:2-simplex voronoi regions}
\end{subfigure}
\begin{subfigure} {\textwidth}
\centering
\begin{tikzpicture}[>=stealth',shorten >=3pt,auto,node distance=14mm,
main node/.style={font=\sffamily},
small node/.style={font=\sffamily,color={black!50} }]
\node[main node] (1234) {$ (1,2,3,4) $};
%
\node[main node] (123) [below of=1234] {$ (1,2,3) $};
\node[main node] (124) [right of=123] {$ (1,2,4) $};
\node[main node] (134) [right of=124] {$ (1,3,4) $};
\node[small node] (234) [right of=134] {$ (2,3,4) $};
%
\node[main node] (12) [below of=123] {$(1,2)$};
\node[main node] (13) [right of=12] {$(1,3)$};
\node[main node] (14) [right of=13] {$(1,4)$};
\node[small node] (23) [right of=14] {$(2,3)$};
\node[small node] (24) [right of=23] {$(2,4)$};
\node[small node] (34) [right of=24] {$(3,4)$};
%
\node[main node] (1) [below of=12] {$ (1) $};
\node[small node] (2) [right of=1] {$ (2) $};
\node[small node] (3) [right of=2] {$ (3) $};
\node[small node] (4) [right of=3] {$ (4) $};
\draw (1234) edge (123) edge (124) edge (134);
\draw (123) edge (12) edge (13);
\draw (124) edge (12) edge (14);
\draw (134) edge (13) edge (14);
\draw (12) edge (1);
\draw (13) edge (1);
\draw (14) edge (1);
\end{tikzpicture}
\caption{3-simplex Voronoi Regions}
\label{fig:3-simplex voronoi regions}
\end{subfigure}
\end{figure}