有没有一种简单的方法可以缩放 circuitikz 中一种非双极元件(晶体管)的尺寸?改变全部双极子元件很容易,你只需这样做即可/tikz/circuitikz/bipoles/length=xyz
,但非双极子似乎没有等效的,无论如何,我只是想改变电路中的 MOSFET,使它们都小一些。
示例(这只是一个半桥,我有另一个具有多个半桥的电路,因此我不想在每个 MOSFET 上手动缩放它们)
\documentclass{standalone}
\usepackage[american]{circuitikz}
\begin{document}
\begin{circuitikz}[/tikz/circuitikz/bipoles/length=0.9cm, scale=0.9, font=\sffamily]
\draw (0,0) to[R=$R_{sa}$, i^<= $I_a$] (0,2)
to [Tnigfetd,n=mos1](0,3.5)
to [Tnigfetd,n=mos1](0,5.5)
to [short, -o](1.5,5.5);
\draw (0,0) to [short=$R_{p1}$, -o](1.5,0);
\draw (0,3.5) to [short, *-o](0.5,3.5) node [right] {A};
\end{circuitikz}
\end{document}
答案1
nigfetd 的默认值是 height=1.1 和 width = 0.7。
\documentclass{standalone}
\usepackage[american]{circuitikz}
\begin{document}
% before
\begin{circuitikz}[/tikz/circuitikz/bipoles/length=0.9cm, scale=0.9, font=\sffamily]
\draw (0,0) to[R=$R_{sa}$, i^<= $I_a$] (0,2)
to [Tnigfetd,n=mos1](0,3.5)
to [Tnigfetd,n=mos1](0,5.5)
to [short, -o](1.5,5.5);
\draw (0,0) to [short=$R_{p1}$, -o](1.5,0);
\draw (0,3.5) to [short, *-o](0.5,3.5) node [right] {A};
\end{circuitikz}
% after
\begin{circuitikz}[/tikz/circuitikz/bipoles/length=0.9cm, scale=0.9, font=\sffamily,
/tikz/circuitikz/tripoles/nigfetd/height=.8,
/tikz/circuitikz/tripoles/nigfetd/width=.5]
\draw (0,0) to[R=$R_{sa}$, i^<= $I_a$] (0,2)
to [Tnigfetd,n=mos1](0,3.5)
to [Tnigfetd,n=mos1](0,5.5)
to [short, -o](1.5,5.5);
\draw (0,0) to [short=$R_{p1}$, -o](1.5,0);
\draw (0,3.5) to [short, *-o](0.5,3.5) node [right] {A};
\end{circuitikz}
\end{document}