Una línea que cruza el nodo raíz en tikzpicture

Una línea que cruza el nodo raíz en tikzpicture

Estoy enfrentando un pequeño problema. Tengo una línea que cruza un nodo raíz. ¿Cómo solucionarlo?

\tikzset{
        basic/.style  = {draw, text width=1.5cm, drop shadow, font=\sffamily, rectangle},
        root/.style   = {basic, rounded corners=6pt, thin, align=center,
            fill=green!60, text width=13cm},
        level 2/.style = {basic, rounded corners=4pt, thin,align=center, fill=green!60,
            text width=8em},
        level 3/.style = {basic, thin, align=left, fill=pink!60, text width=8em, align=center}
    }
    \hspace*{0cm}{
        \begin{tikzpicture}[
        level 1/.style={sibling distance=70mm},
        edge from parent/.style={->,draw},
        >=latex]

        \begin{scope}[every node/.style={level 3}]

        \node[root] (c1) {AAAAA};

        \node [below of = c1, xshift=-4cm, yshift=0cm] (c11) {S};
        \node [below of = c11] (c12) {D};
        \node [below of = c12] (c13) {R};

        \node [below of = c1, xshift=4cm, yshift=.15cm] (c14) {W};
        \node [below of = c14, yshift=-0.5cm] (c15) {K};
        \node [below of = c15, yshift=-0.5cm] (c16) {M};
        \end{scope}

        \foreach \value in {1,2,3}
        \draw[->] (c1.120) |- (c1\value.east);

        \foreach \value in {4,5,6}
        \draw[->] (c1.270) |- (c1\value.west);
        \end{tikzpicture}}

Respuesta1

Sintaxis c1.120significa un punto en la intersección del c1borde del nodo y una línea con un ángulo de 120 grados desde el centro del nodo. En su caso, este punto está en el borde superior y \draw[->] (c1.120) |- (c1\value.east);cruza el nodo. Si desea respetar esta sintaxis, sólo necesita seleccionar un ángulo que coloque el punto de inicio en el borde inferior, como c1.250.

ingrese la descripción de la imagen aquí

\documentclass[tikz,border=2mm]{standalone}
\usetikzlibrary{positioning}

\begin{document}
\begin{tikzpicture}
\node[draw, minimum width=2cm, minimum height=1cm] (c1) {};

\node[draw, minimum width=2cm, minimum height=1cm, below left= 0.5cm and 0.5cm of c1] (c2) {};

\draw (c1.center) -- (120:2cm);
\draw (c1.center) -- (0:2cm);
\draw (0:1.5cm) arc [start angle=0, end angle=120, radius=1.5cm] node[midway, above right] {$120^\circ$};
\draw[fill=red] (c1.120) circle (2pt);
\draw (c1.120) |- (c2);

\begin{scope}[xshift=5cm]
\node[draw, minimum width=2cm, minimum height=1cm] (c1) {};
\node[draw, minimum width=2cm, minimum height=1cm, below left= 0.5cm and 0.5cm of c1] (c2) {};
\draw (c1.center) -- (250:2cm);
\draw (c1.center) -- (0:2cm);
\draw (0:1.5cm) arc [start angle=0, end angle=250, radius=1.5cm] node[midway, above left] {$250^\circ$};
\draw[fill=red] (c1.250) circle (2pt);
\draw (c1.250) |- (c2);
\end{scope}
\end{tikzpicture}
\end{document}

información relacionada