Currently I am trying to make a nice layout of logic gates for digital electronics. I have not been able to nest a tabular environment inside of a circuitikz picture, and I'm quite new at nesting in general so I haven't had much success. The only way I can make it work is if I make the table out of nodes, the equation a singular node, and the picture just stays a circuitikz picture for the corresponding logic gate.
I would like to have a systematic way of grouping the three together in some sort of horizontal array. If I had a region of space split into three sections, I could nest the equation, table, and picture all in one array. I believe this is quite complicated, but perhaps there is a trivial fix?
I have looked around but there aren't many examples involving the work I have been doing with circuitikz. Any insight is much appreciated. I have attached the following code below. I realize it is not done in the best way, but I'm VERY new to TikZ and such packages. If you mess around with it at all you will need to include the circuitikz package for successfull compilation.
\begin{figure}[H]
\centering
\begin{circuitikz}
\draw (0,0) node[nor port] {};
\draw (-2,0) node[anchor=east] {{\bf {\green NOR}}};
\draw (1.5,0) node[anchor=west] {$\mathcal{O}=\overline{{\rm A}+{\rm B}}$};
\node at (6,0.5) {${\rm A}\;\;\;\;{\rm B}\;\;\;\;\mathcal{O}$};
\draw (4.95,0.2) -- (7,0.2);
\node at (6,-0.15) {0\;\;\;\;\;0\;\;\;\;\;1};
\node at (6,-0.55) {0\;\;\;\;\;1\;\;\;\;\;0};
\node at (6,-0.95) {1\;\;\;\;\;0\;\;\;\;\;0};
\node at (6,-1.35) {1\;\;\;\;\;1\;\;\;\;\;0};
\draw (0,-3) node[nand port] {};
\draw (-2,-3) node[anchor=east] {{\bf {\green NAND}}};
\draw (1.5,-3) node[anchor=west] {$\mathcal{O}=\overline{{\rm A}\cdot{\rm B}}$};
\node at (6,-2.5) {${\rm A}\;\;\;\;{\rm B}\;\;\;\;\mathcal{O}$};
\draw (4.95,-2.8) -- (7,-2.8);
\node at (6,-3.15) {0\;\;\;\;\;0\;\;\;\;\;1};
\node at (6,-3.55) {0\;\;\;\;\;1\;\;\;\;\;1};
\node at (6,-3.95) {1\;\;\;\;\;0\;\;\;\;\;1};
\node at (6,-4.35) {1\;\;\;\;\;1\;\;\;\;\;0};
\draw (0,-6) node[xor port] {};
\draw (-2,-6) node[anchor=east] {{\bf {\green XOR}}};
\draw (0.5,-6) node[anchor=west] {$\mathcal{O}=({\rm A}+{\rm B})\cdot\overline{({\rm A}\cdot {\rm B})}$};
\node at (6,-5.5) {${\rm A}\;\;\;\;{\rm B}\;\;\;\;\mathcal{O}$};
\draw (4.95,-5.8) -- (7,-5.8);
\node at (6,-6.15) {0\;\;\;\;\;0\;\;\;\;\;0};
\node at (6,-6.55) {0\;\;\;\;\;1\;\;\;\;\;1};
\node at (6,-6.95) {1\;\;\;\;\;0\;\;\;\;\;1};
\node at (6,-7.35) {1\;\;\;\;\;1\;\;\;\;\;0};
\end{circuitikz}
\end{figure}
EDIT

:-)– Hendrik Vogt Jan 19 '11 at 19:56\usepackageand\newcommand. – Caramdir Jan 20 '11 at 01:40