Since you already load the calc
library, you can make use of the syntax provided by it which allows you calculate coordinates relative to two existing coordinates.
As has already been suggested by the other answer, the syntax ($(nodeA)!0.5!(nodeB)$)
means "set the coordinate halfways (50%) between nodeA
and nodeB
. So, 0.5
here means 50% of the distance between the two coordinates.
What is nice with this syntax is that you can even place coordinates that are not between the two coordinates using numbers smaller than 0 or larger than 1.
\documentclass[border=10pt]{standalone}
\usepackage{tikz}
\usetikzlibrary{calc, positioning, decorations.pathmorphing}
\begin{document}
\begin{tikzpicture}
[
node distance = 17mm and 31mm,
b/.style={rectangle, draw=black!60, fill=gray!15, very thick, minimum size=35},
c/.style={circle, draw=black!60, fill=gray!15, very thick, minimum size=35}
]
%Nodes
\node[b] (posFk) {$F_k$};
\node[c] (posak) [below=of posFk] {$\alpha_k$};
\node[c] (posmuk) [below=of posak] {$\mu_k$};
\node[b] (posFtk) [below=of posmuk] {$\tilde{F}_k$};
\node[b] (posFF) [left=of posFk] {$F_2$};
\node[c] (posakk) [below=of posFF] {$\alpha_2$};
\node[c] (posmukk) [below=of posakk] {$\mu_2$};
\node[b] (posFtkk) [below=of posmukk] {$\tilde{F}_2$};
\node[b] (posFFF) [left=of posFF] {$F_1$};
\node[c] (posakkk) [below=of posFFF] {$\alpha_1$};
\node[c] (posmukkk) [below=of posakkk] {$\mu_1$};
\node[b] (posFtkkk) [below=of posmukkk] {$\tilde{F}_1$};
%Curved lines for the quiver
\draw[-, very thick] (posmuk.east)
.. controls +(right:17mm) and +(right:17mm)
.. (posFk.east);
\draw[-, very thick] (posak.west)
.. controls +(left:17mm) and +(left:17mm)
.. (posFtk.west);
\draw[-, very thick] (posmukk.east)
.. controls +(right:17mm) and +(right:17mm)
.. (posFF.east);
\draw[-, very thick] (posakk.west)
.. controls +(left:17mm) and +(left:17mm)
.. (posFtkk.west);
\draw[-, very thick] (posmukkk.east)
.. controls +(right:17mm) and +(right:17mm)
.. (posFFF.east);
\draw[-, very thick] (posakkk.west)
.. controls +(left:17mm) and +(left:17mm)
.. (posFtkkk.west);
%Lines for each column of the quivers
%Right
\draw[-, very thick, dashed] (posFk.south)
to node[right] {} (posak.north);
\draw[-, very thick, decorate,decoration={coil,aspect=0,segment length=5.9mm}] (posak.south)
to node[right] {} (posmuk.north);
\draw[-, very thick, dashed] (posmuk.south)
to node[right] {} (posFtk.north);
%Middle
\draw[-, very thick, dashed] (posFF.south)
to node[right] {} (posakk.north);
\draw[-, very thick, decorate,decoration={coil,aspect=0,segment length=5.9mm}] (posakk.south)
to node[right] {} (posmukk.north);
\draw[-, very thick, dashed] (posmukk.south)
to node[right] {} (posFtkk.north);
%Left
\draw[-, very thick, dashed] (posFFF.south)
to node[right] {} (posakkk.north);
\draw[-, very thick, decorate,decoration={coil,aspect=0,segment length=5.9mm}] (posakkk.south)
to node[right] {} (posmukkk.north);
\draw[-, very thick, dashed] (posmukkk.south)
to node[right] {} (posFtkkk.north);
%Horizontal lines connecting the quiver
\draw[-, very thick] (posakkk.east) to node[right] {} (posakk.west);
\draw[-, very thick] (posmukkk.east) to node[right] {} (posmukk.west);
%\draw[-, very thick] (posakk.east) to node[right] {} (posak.west);
%\draw[-, very thick] (posmukk.east) to node[right] {} (posmuk.west);
\draw[-, very thick, blue] (posakk.east) -- ($(posakk)!0.33!(posak)$);
\draw[-, very thick, dashed, blue] ($(posakk)!0.33!(posak)$) -- ($(posakk)!0.67!(posak)$);
\draw[-, very thick, blue] ($(posakk)!0.67!(posak)$) -- (posak.west);
\draw[-, very thick, blue] (posmukk.east) -- ($(posmukk)!0.33!(posmuk)$);
\draw[-, very thick, dashed, blue] ($(posmukk)!0.33!(posmuk)$) -- ($(posmukk)!0.67!(posmuk)$);
\draw[-, very thick, blue] ($(posmukk)!0.67!(posmuk)$) -- (posmuk.west);
\draw[-, very thick, blue] (posak.east) -- ($(posakk)!1.33!(posak)$);
\draw[-, very thick, dashed, blue] ($(posakk)!1.33!(posak)$) -- ($(posakk)!1.67!(posak)$);
\draw[-, very thick, blue] (posmuk.east) -- ($(posmukk)!1.33!(posmuk)$);
\draw[-, very thick, dashed, blue] ($(posmukk)!1.33!(posmuk)$) -- ($(posmukk)!1.67!(posmuk)$);
%Diagonal lines connecting the quiver
\draw[-, very thick, dashed] (posakkk.east) to node[right] {} (posmukk.west);
\draw[-, very thick, dashed] (posmukkk.east) to node[right] {} (posakk.west);
\end{tikzpicture}
\end{document}
Also, maybe the -|
and |-
operators can be helpful:
\documentclass[border=10pt]{standalone}
\usepackage{tikz}
\usetikzlibrary{calc, positioning, decorations.pathmorphing}
\begin{document}
\begin{tikzpicture}
[
node distance = 17mm and 31mm,
b/.style={rectangle, draw=black!60, fill=gray!15, very thick, minimum size=35},
c/.style={circle, draw=black!60, fill=gray!15, very thick, minimum size=35}
]
%Nodes
\node[b] (posFk) {$F_k$};
\node[c] (posak) [below=of posFk] {$\alpha_k$};
\node[c] (posmuk) [below=of posak] {$\mu_k$};
\node[b] (posFtk) [below=of posmuk] {$\tilde{F}_k$};
\node[b] (posFF) [left=of posFk] {$F_2$};
\node[c] (posakk) [below=of posFF] {$\alpha_2$};
\node[c] (posmukk) [below=of posakk] {$\mu_2$};
\node[b] (posFtkk) [below=of posmukk] {$\tilde{F}_2$};
\node[b] (posFFF) [left=of posFF] {$F_1$};
\node[c] (posakkk) [below=of posFFF] {$\alpha_1$};
\node[c] (posmukkk) [below=of posakkk] {$\mu_1$};
\node[b] (posFtkkk) [below=of posmukkk] {$\tilde{F}_1$};
%Curved lines for the quiver
\draw[-, very thick] (posmuk.east)
.. controls +(right:17mm) and +(right:17mm)
.. (posFk.east);
\draw[-, very thick] (posak.west)
.. controls +(left:17mm) and +(left:17mm)
.. (posFtk.west);
\draw[-, very thick] (posmukk.east)
.. controls +(right:17mm) and +(right:17mm)
.. (posFF.east);
\draw[-, very thick] (posakk.west)
.. controls +(left:17mm) and +(left:17mm)
.. (posFtkk.west);
\draw[-, very thick] (posmukkk.east)
.. controls +(right:17mm) and +(right:17mm)
.. (posFFF.east);
\draw[-, very thick] (posakkk.west)
.. controls +(left:17mm) and +(left:17mm)
.. (posFtkkk.west);
%Lines for each column of the quivers
%Right
\draw[-, very thick, dashed] (posFk.south)
to node[right] {} (posak.north);
\draw[-, very thick, decorate,decoration={coil,aspect=0,segment length=5.9mm}] (posak.south)
to node[right] {} (posmuk.north);
\draw[-, very thick, dashed] (posmuk.south)
to node[right] {} (posFtk.north);
%Middle
\draw[-, very thick, dashed] (posFF.south)
to node[right] {} (posakk.north);
\draw[-, very thick, decorate,decoration={coil,aspect=0,segment length=5.9mm}] (posakk.south)
to node[right] {} (posmukk.north);
\draw[-, very thick, dashed] (posmukk.south)
to node[right] {} (posFtkk.north);
%Left
\draw[-, very thick, dashed] (posFFF.south)
to node[right] {} (posakkk.north);
\draw[-, very thick, decorate,decoration={coil,aspect=0,segment length=5.9mm}] (posakkk.south)
to node[right] {} (posmukkk.north);
\draw[-, very thick, dashed] (posmukkk.south)
to node[right] {} (posFtkkk.north);
%Horizontal lines connecting the quiver
\draw[-, very thick] (posakkk.east) to node[right] {} (posakk.west);
\draw[-, very thick] (posmukkk.east) to node[right] {} (posmukk.west);
%\draw[-, very thick] (posakk.east) to node[right] {} (posak.west);
%\draw[-, very thick] (posmukk.east) to node[right] {} (posmuk.west);
\draw[-, very thick, blue] (posakk.east) -- ($(posakk)!0.4!(posak)$);
\node[blue] at ($(posakk)!0.5!(posak)$) {$\ldots$};
\draw[-, very thick, blue] ($(posakk)!0.6!(posak)$) -- (posak.west);
\draw[-, very thick, blue] (posmukk.east) -- ($(posmukk)!0.4!(posmuk)$);
\node[blue] at ($(posmukk)!0.5!(posmuk)$) {$\ldots$};
\draw[-, very thick, blue] ($(posmukk)!0.6!(posmuk)$) -- (posmuk.west);
\draw[-, very thick, blue] (posak.east) -- ($(posakk)!1.4!(posak)$);
\node[blue] at ($(posakk)!1.5!(posak)$) {$\ldots$};
\draw[-, very thick, blue] (posmuk.east) -- ($(posmukk)!1.4!(posmuk)$);
\node[blue] at ($(posmukk)!1.5!(posmuk)$) {$\ldots$};
%Diagonal lines connecting the quiver
\draw[-, very thick, dashed] (posakkk.east) to node[right] {} (posmukk.west);
\draw[-, very thick, dashed] (posmukkk.east) to node[right] {} (posakk.west);
\coordinate (helperA) at ($(posakk)!0.5!(posmukk)$);
\coordinate (helperB) at ($(posakk)!0.4!(posak)$);
\coordinate (helperC) at ($(posakk)!0.6!(posak)$);
\node[blue] at ($(posakk)!0.5!(posmuk)$) {$\ldots$};
\draw[-, very thick, dashed, blue] (posakk.east) -- (helperA -| helperB) -- (posmukk.east);
\draw[-, very thick, dashed, blue] (posak.west) -- (helperA -| helperC) -- (posmuk.west);
\coordinate (helperD) at ($(posak)!0.5!(posmuk)$);
\coordinate (helperE) at ($(posakk)!1.4!(posak)$);
\coordinate (helperF) at ($(posakk)!1.5!(posak)$);
\node[blue] at (helperD -| helperF) {$\ldots$};
\draw[-, very thick, dashed, blue] (posak.east) -- (helperD -| helperE) -- (posmuk.east);
\end{tikzpicture}
\end{document}
calc
library that is helpful in this regard: For example,($(posakk)!0.5!(posakkk)$)
is the coordinate that sits exactly halfway betweenposakk
andposakkk
.trail off
dash pattern in another answer. Similar things can be done with dots, you just need to sync up the length of the line with the dash pattern. That can be done manually as in my link or somewhat automatically, see my previous link.