0

I am new to tikz / circuitikz, each time I try to make a spring or snake I got only a straight line:

%%circuitikz  filename=p236 dpi=100
\begin{circuitikz}[snake]
\draw[snake=coil]                  (0,1) -- (3,1);
\draw[snake=coil,segment aspect=0] (0,0) -- (3,
\end{circuitikz}

I work in a jupyter notebook and I think the problems is I can't set lib which seams to be needed to accomplish it?

Any help? Henri

1 Answer 1

1

I do not get a straight line. Are you by chance afraid of snakes? ;-)

\documentclass[tikz,border=3.14mm]{standalone}
\usepackage{circuitikz}
\usetikzlibrary{snakes}
\standaloneenv{circuitikz}
\begin{document}
\begin{circuitikz}
\draw[snake=coil]                  (0,1) -- (3,1);
\draw[snake=coil,segment aspect=0] (0,0) -- (3,0);
\end{circuitikz}
\end{document}

enter image description here

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .