我正在尝试绘制此框图
但我找不到任何类似的图表或任何教程来了解如何操作。有人能帮助我吗?
我已经这样做了:
%Flowcharting techniques for easy maintenance
%Author: Brent Longborough
\documentclass[x11names]{article}
\usepackage{tikz}
\usepackage{geometry}
\usepackage{amssymb}
\usepackage{booktabs}
\usepackage{empheq}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{mathtools}
\usepackage{float}
\usetikzlibrary{shapes,arrows,chains}
\begin{document}
\pgfdeclarelayer{marx}
\pgfsetlayers{main,marx}
\begin{tikzpicture}[%
>=triangle 60, % Nice arrows; your taste may be different
start chain=going below, % General flow is top-to-bottom
node distance=6mm and 60mm, % Global setup of box spacing
every join/.style={norm}, % Default linetype for connecting boxes
]
\tikzset{
base/.style={draw, on chain, on grid, align=center, minimum height=5ex},
base2/.style={draw, on chain, on grid, align=center, minimum height=7ex},
pric/.style={base2, rectangle, text width=6em},
proc/.style={base, rectangle, text width=18em},
pruc/.style={base, circle, text width=3em},
test/.style={base, diamond, aspect=1.5, text width=8em},
term/.style={proc, rounded corners},
coord/.style={coordinate, on chain, on grid, node distance=6mm and 25mm},
nmark/.style={draw, cyan, circle, font={\sffamily\bfseries}},
norm/.style={->, draw, lcnorm},
norm/.style={->, draw, lcnorm},
free/.style={->, draw, lcfree},
cong/.style={->, draw, lccong},
it/.style={font={\small\itshape}}
}
\node [pruc, join] (p0) {};
\node [term, join] {};
\node [term, join] {};
\node [term, join] (t0) {};
\node [pric] (t1) {};
\node [test] (t2) {};
\node [term, join=by free] {};
\node [pruc, join] (p0) {};
\draw [<-,lcnorm] (t0) -- (t1);
\draw [<-,lcnorm] (t1) -- (t2);
\end{tikzpicture}
% =================================================
\end{document}
但我不知道如何绘制位于左侧和右侧的中间框。
提前致谢。
答案1
它是否足够接近你喜欢画的东西?
\documentclass[tikz, margin=3mm]{standalone}
\usetikzlibrary{arrows.meta, chains, shapes}
\makeatletter
\tikzset{
suppress join/.code={\def\tikz@after@path{}},
}
\makeatother
\begin{document}
\begin{tikzpicture}[%
node distance = 4mm and -4mm, % Global setup of box spacing
start chain = going above, % General flow is top-to-bottom
%
LA/.style = {Stealth-},
base/.style = {draw,
minimum size=3ex, inner sep=2mm, align=center,
on chain, join=by LA},
sbox/.style = {base, rectangle, text width=6em},
wbox/.style = {base, rectangle, text width=18em},
term/.style = {sbox, rectangle, rounded corners},
test/.style = {base, diamond, aspect=1.5,
inner xsep=0mm, text width=8em},
]
% from bottom to top
\node (n1) [term] {};
\node (n2) [wbox] {};
\node (n3) [test] {};
\node (n4) [sbox, suppress join,
minimum height=5ex] {};
% left column
\node (n5a) [sbox, suppress join, above left=of n4] {};
\node (n6a) [sbox] {};
\node (n7a) [sbox] {};
% right column
\node (n5b) [sbox, suppress join, above right=of n4] {};
\node (n6b) [sbox] {};
\node (n7b) [sbox] {};
% top column
\node (n8) [wbox, suppress join, above=of n7a.north -| n4] {};
\node (n9) [wbox] {};
\node (n10) [wbox] {};
\node (n11) [term] {};
%
\draw[LA] (n4) edge (n3)
(n8) edge (n4);
\draw[LA] (n7a) edge (n7a |- n8.south) (n3) -| (n5a);
\draw[LA] (n7b) edge (n7b |- n8.south) (n3) -| (n5b);
\end{tikzpicture}
\end{document}