회로의 일부(커패시터...)를 서로 상대적으로 배치합니다. 회로 부품의 이름을 사용하여 "컨트롤"을 통해 메시 화살표를 "직관적으로" 배치

회로의 일부(커패시터...)를 서로 상대적으로 배치합니다. 회로 부품의 이름을 사용하여 "컨트롤"을 통해 메시 화살표를 "직관적으로" 배치

이 질문은 계속 내또 다른. 내 평판 때문에 답변에 의견을 추가할 수 없습니다. 그래서 나는 감사할 기회를 이용한다존 코밀로내 첫 질문에 대한 그의 대답에 대해. 또한 잘못된 영어로 인해 죄송합니다.

질문에:

회로의 경우 다음 구문을 사용합니다 circuitikz.

\begin{circuitikz}
  \draw
  (0,0) to [V = $U$] (0,3)
        to [short, i = $I$, -*] (3,3) -- (6,3)
        to [R = $R_2$, v = $U_2$, i = $I_2$] (6,0) -- (0,0)
  (3,3) to [R = $R_1$, v = $U_1$, i = $I_1$, -*] (3,0);
\end{circuitikz}

이는 매우 쉽고 직관적입니다. 그러나 회로에 메시 화살표를 추가하려면 다음을 사용합니다(위 코드에 추가로, 예를 들어 메시 하나).

\draw
 %
 % mesh one (detailed explanation of the implementation)
 %
 [<-,% direction of the arrow
 > = triangle 45,% kind of the arrow end
 path picture =% allows ''to paint a picture'' inside of an other ''picture''
 {\node[anchor = center]% position of the inner ''picture''
 at (path picture bounding box.center)% bordering rectangle,
                                      % centered inside the arrow (arrow is the outer ''picture'')
 {$M_1$};}]% text of the inner ''picture''
 (1.75,1)% coordinates of the arrow end
 arc% arc-shaped arrow
 (-60:% angle of the arrow start
 170:% angle of the arrow end
 .5);% radius of the arc

두 코드 조각의 결과를 보려면 위의 링크(내 초기 질문)를 참조하세요.

"단지" 하나의 화살표에 대한 이 정도의 코드는 나에게는 다소 복잡하고 직관적이지 않은 것 같습니다.

내가 원하는 것:

1.PGF51페이지 매뉴얼(하위 섹션 3.8)의 "Petri-Net" 예와 같이 회로의 일부(이름이 있는 노드)를 서로 상대적으로 배치합니다 .

페트리넷

구문 과 결합됩니다 circuitikz(첫 번째 코드 예제 참조).

2.John Kormylo가 내 초기 질문에 대한 답변에서 했던 것처럼 회로 부품의 이름을 사용하여 매크로 controls(설명서 748페이지 )를 사용하여 메시 화살표를 직관적으로 배치합니다.PGF

\node (M 3) [below] at (0,0) {\phantom{$M_3$}};% reserving space for M 3 under the circuit
\draw
[->, > = triangle 45] (current bounding box.east) .. controls
                      (current bounding box.south east) ..
                      (M 3.south) node[above, pos = .95] {$M_3$};% see below
% above: location of the inscription ''M_3'' relative to the arrow end
% pos=: location of the inscription ''M_3'' on the ''x''-axis (arrow beginning is zero,
%                                                              arrow end is one)

이것이 가능한가? 그렇다면 어떻게 해야 합니까? 제 의도를 이해해주시길 바랍니다.

귀하의 답변과 도움에 미리 감사드립니다!

답변1

호의 중심에 노드를 배치하는 대신 노드 주위에 호를 배치했습니다. 동일한 결과, 더 적은 키 입력. 동일한 옵션을 계속해서 반복하지 않는 방법도 여러 가지가 있습니다. 변경 사항은 범위 기간 동안에만 지속되므로 범위를 사용했습니다.

대부분의 단순화는 주석을 제거했기 때문입니다.

\documentclass{scrartcl}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenx}
\usepackage{amsmath}
\usepackage[european]{circuitikz}
\usepackage{showframe}
\begin{document}
  \noindent
  \begin{minipage}[t]{.5\linewidth}
    \begin{circuitikz}[baseline=(current bounding box.north)]
      %
      % circuit
      %
      \draw
      (0,0) to [V = $U$] (0,3)
            to [short, i = $I$, -*] (3,3) -- (6,3)
            to [R = $R_2$, v = $U_2$, i = $I_2$] (6,0) -- (0,0)
      (3,3) to [R = $R_1$, v = $U_1$, i = $I_1$, -*] (3,0);
      %
      % mesh arrows
      %
      \begin{scope}[>=triangle 45]
        \draw[<-] (1.5,1.5) node{$M_1$} +(.25,-.433) arc(-60:170:.5);
        \draw[<-] (4.5,1.5) node{$M_2$} +(.25,-.433) arc(-60:170:.5);
        \node (mesh3) [below] at (0,0) {\phantom{$M_3$}};% reserve space below circuit for M_3
        \draw[->, thick] (current bounding box.east)% not the only way, just easy
          .. controls (current bounding box.south east) .. 
          (mesh3.south) node[above,pos=.9] {$M_3$};
      \end{scope}
    \end{circuitikz}
  \end{minipage}
  \hfill
  \begin{minipage}[t]{.45\linewidth}
    %
    % equations for mesh and knot
    %
    \begin{align*}
      &K  : \quad I   = I_1 + I_2\\
      &M_1: \quad -U  = -U_1\Leftrightarrow U = U_1 = R_1I_1\\
      &M_2: \quad U_1 = -U_2\\
      &M_3: \quad -U  = -U_2\Leftrightarrow U = U_2 = R_2I_2
    \end{align*}
  \end{minipage}
\end{document}

관련 정보