Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I'm using circuitikz to create some logic gate diagrams. In my course we use "inversion bubbles" as a convenient shortcut instead of drawing inverters everywhere. As in inputs A and B in this image:

enter image description here

Is it possible to create these bubbles using circuitikz? It's not in the documentation.

share|improve this question
add comment

1 Answer

up vote 2 down vote accepted

The logic gates that ship with plain TikZ (not circuitikz) have that feature. You set the state of the inputs using inputs=<string of n and i>, where n stands for normal input and i stands for inverted. Here's an example using inputs=ni:

\documentclass[border=5mm]{standalone}
\usepackage{tikz}
\usetikzlibrary{circuits.logic.US} 

\begin{document}
\begin{tikzpicture}[circuit logic US]
\node (a) [and gate, inputs=ni] {};
\draw (a.input 1) -- (a.input 1 -| -1,0)
 (a.input 2) -- (a.input 2 -| -1,0)
 (a.output) -- ++(0.5,0);
\end{tikzpicture}%
\end{document}

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.