我怎样才能得到这个数字?

我怎样才能得到这个数字?

我尝试画出这个图形,但画得不太好。你能帮我吗?在此处输入图片描述

\documentclass{article}
\usepackage{tikz}
\begin{document}
\begin{center}
 %%%%%%%%%%%%%%%%%%%%%%%%%
\begin{tikzpicture}[radius=0.4cm]
%\begin{tikzpicture}[framed,radius=0.4cm]
\draw (1,1) circle node (A) {};
\draw (2.3,1.1) circle node (B) {};
\draw (4.5,0.8) circle node (C) {};
\draw[black,thick,dashed] (5.1,1.8) circle node (D) {D};
\draw (0.4,3.3) circle node (E) {};
\draw (2.1,2.8) circle node  (R2) {R2};
\draw (3.8,3.5) circle node (R3) {R3};
\draw (4.8,4.2) circle node (H) {};
\draw [black,thick,dashed] (0.8,4.9) circle node (S) {S};
\draw (2.1,4.1) circle node (R1) {R1};
\draw (3.8,2.0) circle node (R4) {R4};
\draw (3.5,0.6) circle node (L) {};
\draw (3.0,5.0) circle node (M) {} ;  
\draw (4.1,5.1) circle node (N) {} ;         
\draw (0.9,2.1) circle node (P) {};
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\path[->,font=\scriptsize]
([yshift= 3pt]S) edge ([yshift= 3pt]R1)
([yshift= -3pt]R1) edge ([yshift= -3pt]S);
%%%%%%%%%%%%%%%
\path[->,font=\scriptsize]
([yshift= 3pt,thin,dashed,blue]R1) edge ([yshift= 3pt,thin,dashed,blue]R2)
([yshift= -3pt]R2) edge ([yshift= -3pt]R1);
%%%%%%%%%%%%%%%%%%
\path[->,font=\scriptsize]
([yshift= 3pt]R2) edge ([yshift= 3pt]R3)
([yshift= -3pt]R3) edge ([yshift= -3pt]R2);
%%%%%%%%%%%%%%%%%%%%%
\path[->,font=\scriptsize]
([yshift= 3pt]R3) edge ([yshift= 3pt]R4)
([yshift= -3pt]R4) edge ([yshift= -3pt]R3);
 %%%%%%%%%%%%%%%%%%%%
 \path[->,font=\scriptsize]
 ([yshift= 3pt]R4) edge ([yshift= 3pt]D)
 ([yshift= -3pt]D) edge ([yshift= -3pt]R4);
 \end{tikzpicture}
\end{center} 
\end{document}

答案1

\documentclass{standalone}
\usepackage{tikz}
\begin{document}

\begin{tikzpicture}[radius=0.4cm]

% simple circles
\draw (1,1) circle node (A) {};
\draw (2.3,1.1) circle node (B) {};
\draw (4.5,0.8) circle node (C) {};
\draw (3.5,0.6) circle node (L) {};
\draw (3.0,5.0) circle node (M) {} ;  
\draw (4.1,5.1) circle node (N) {} ;         
\draw (0.9,2.1) circle node (P) {};
\draw (4.8,4.2) circle node (H) {};
\draw (0.4,3.3) circle node (E) {};

% Dashed
\node[thick,dashed,draw,red] (D) at (5.1,1.8) {D};
\draw[thick,dashed,blue] (D) circle (0.4cm);
\node[thick,dashed,draw,red] (S) at (0.8,4.9) {S};
\draw[thick,dashed,blue] (S) circle (0.4cm);

% Solid lines
\node[thick,draw,red] (R2) at (2.1,2.8) {R2};
\draw[thick,blue] (R2) circle (0.4cm);
\node[thick,draw,red] (R3) at (3.8,3.5) {R3};
\draw[thick,blue] (R3) circle (0.4cm);
\node[thick,draw,red] (R1) at (2.1,4.1) {R1};
\draw[thick,blue] (R1) circle (0.4cm);
\node[thick,draw,red] (R4) at (3.8,2.0) {R4};
\draw[thick,blue] (R4) circle (0.4cm);

% arrows
\draw[-latex,thick] (S) -- (R1);
\draw[latex-,blue,dashed,thick,transform canvas={yshift=-1.5mm}] (S) -- (R1);
\draw[-latex,thick] (R1) -- (R2);
\draw[latex-,blue,dashed,thick,transform canvas={xshift=-1.5mm}] (R1) -- (R2);
\draw[-latex,thick] (R2) -- (R3);
\draw[latex-,blue,dashed,thick,transform canvas={yshift=-1.5mm}] (R2) -- (R3);
\draw[-latex,thick] (R3) -- (R4);
\draw[latex-,blue,dashed,thick,transform canvas={xshift=1.5mm}] (R3) -- (R4);
\draw[-latex,thick] (R4) -- (D);
\draw[latex-,blue,dashed,thick,transform canvas={yshift=-1.5mm}] (R4) -- (D);
 \end{tikzpicture}
\end{document}

在此处输入图片描述

相关内容