# CircuiTikZ inductor style

Hello, friends, once more.

I guess this is an easy one for you, I would like to know how to get both styles for the inductor, like in the picture. I like both, but specially the first one. Thanks in advance. I have not found this specific issue, I know the second one is gotten by [cute inductor] but not a clue about the first one.

• You should check if your questions have an answer and, in that case, apart from upvoting (in case you think the answer deserves it) accept them (clicking the green tick). Nov 13 '14 at 19:36
• Hello, could you please provide a minimal working example (MWE)? You seem to know how to place an inductor and you just want to change the style.
– yo'
Nov 13 '14 at 19:41
• \documentclass{standalone} \usepackage{tikz,american} \begin{document} \begin{tikzpicture} \draw (0,0) to[cute inductor] (0,3) ; \end{tikzpicture} \end{document} Nov 13 '14 at 20:52
• Please always provide a fully compilable MWE in the question rather than in the comments. What you have in the comment above will not compile. Nov 13 '14 at 21:47

You can specify the desired symbol via the options:

## Code:

\documentclass{article}
\usepackage[american]{circuitikz}
\begin{document}
\begin{tikzpicture}
\draw (0,0) to[cute inductor] (3,0) ;
\node [below=5pt] at (1.5,0) {cute inductor};

\draw (4,0) to[american inductor] (7,0) ;
\node [below=5pt] at (5.5,0) {american inductor};
\end{tikzpicture}
\end{document}

• Sorry about the wrong-placed code. I lost a code where the first inductor was drawn, this one is based on semicircles and I like it a lot, if I had it, I definitely share it. American inductor as in your example is too bland to my tastes... I hope you get a clue on how to help me, no one else has been able to solve this issue. It is not a big deal, but I would like to know how to do things better. Thanks in advance, @PeterGrill. Nov 14 '14 at 2:03

I'm not sure if it helps, but here is a solution for the first symbol without circuitikz. I adjusted the symbol I normally use slightly to be able to let the semicircles go on for more than 180 degrees.

\documentclass[tikz]{standalone}

\tikzset{
inductor/.style args={#1}{
sloped,
allow upside down,
minimum height=4mm,
minimum width=10mm,
path picture={%
\draw[white] (-4.5mm,0) -- (4.5mm,0);
\draw[line join=bevel] (-5mm,0)-- (-4mm,0)
-- (5mm,0);
}
},
inductor/.default={40}
}

\begin{document}
\begin{tikzpicture}
\draw (0,0) -- node[inductor]{} ++(2,0) node[right]{\verb|inductor|};
\draw (0,-1) -- node[inductor={0}]{} ++(2,0) node[right]{\verb|inductor={0}|};
\end{tikzpicture}
\end{document}


This is the result:

• Welcome to TeX.SX! Thanks for your help. Nov 25 '17 at 14:34