带包围圆的节点图

带包围圆的节点图

我正在尝试绘制类似这样的图像:

在此处输入图片描述

但是,我只想将三个节点绘制为文本(“A”,“B”,“C”),带有双箭头和较大的重叠圆圈......

我在以下方面取得了一些成功:

\begin{tikzpicture}[->,>=stealth',shorten >=1pt,auto,node distance=2.8cm,semithick]
  \tikzstyle{style}=[fill=white,draw=none,text=white]
  \tikzstyle{line} = [draw, -latex']

  \node[state]         (A)              {A};
  \node[state]         (B) [right of=A] {B};
  \node[state]         (C) [right of=B] {C};

  \path [line, <->] (A) -- (B);
  \path [line, <->] (B) -- (C);
\end{tikzpicture}

但是我无法得到重叠的外圆。它们应该重叠,使得围绕 A 的圆包含 B,围绕 B 的圆包含 A 和 C,而围绕 C 的圆包含 B。

答案1

也许 :

\documentclass{article}

\usepackage{tikz}
\usetikzlibrary{arrows,calc,through}

\begin{document}

\begin{tikzpicture}[->,>=stealth',shorten >=1pt,auto,node distance=2.8cm,semithick]
  \tikzset{style/.style={fill=white,draw=none,text=white}}
  \tikzset{line/.style = {draw, -latex'}}

  \node        (A)              {A};
  \node        (B) [right of=A] {B};
  \node        (C) [right of=B] {C};
  \node [draw] at (A) [circle through={($(B)+(1,1)$)}] {};
  \node [draw] at (B) [circle through={($(A)-(1,1)$)}] {};
  \node [draw] at (C) [circle through={($(B)-(1,1)$)}] {};
  \path [line, <->] (A) -- (B);
  \path [line, <->] (B) -- (C);
\end{tikzpicture}  
\end{document} 

在此处输入图片描述

相关内容