我尝试在 LaTeX 中制作惠斯通电桥方案,但目前我得到的结果是:
\begin{circuitikz}
\draw (0,0) to (8,0);
\draw (0,0) to (0,2);
\draw (0,2) to [battery1] (8,2);
\draw (8,0) to (8,2);
\filldraw[black] (0,0) circle (1pt) node[anchor=north]{A};
\filldraw[black] (4,1) circle (1pt) node[anchor=north]{B};
\filldraw[black] (8,0) circle (1pt) node[anchor=north]{C};
\filldraw[black] (3,0) circle (1pt) node[anchor=north]{D};
\end{circuitikz}
我发布了一张我想要的图片。谢谢你的帮助!:)
答案1
起点:
\documentclass[border=10pt]{standalone}
\usepackage[europeanresistors]{circuitikz}
\begin{document}
\begin{circuitikz}
\draw (0,0)
node[circ, label={left:$A$}]{}
to
(0,3.5)
to[battery2]
(6,3.5)
to
(6,0)
node[circ, label={right:$C$}]{};
\draw (0,0)
to
node[currarrow, label={above right:$R_1$}] {}
(2.5,0)
node[circ, label={below right:$D$}]{}
to
node[currarrow, label={above right:$R_2$}]{}
(6,0);
\draw (0,0)
to[R=$R_3$, i_>=\null]
(3,2)
node[circ, label={above:$B$}]{}
to[R=$R_4$, i>_=\null]
(6,0);
\draw (2.5,0)
to[out=90, in=270]
node[circle, draw, thick, fill=white] {$G$}
node[currarrow, sloped, pos=0.8]{}
(3,2);
\draw (0,-0.25) -- ++(0,-0.5)
(2.5,-0.25) -- ++(0,-0.5)
(6,-0.25) -- ++(0,-0.5);
\draw[<->] (0,-0.5) -- node[below] {$l_1$} (2.5,-0.5);
\draw[<->] (2.5,-0.5) -- node[below] {$l_2$} (6,-0.5);
\end{circuitikz}
\end{document}