1

I am trying to align vertically this 3 circuits. I would like to align the on top, instead of bottom part (they automatically align bottom with that code).

Also, if possible, to know how to align the at the same 'pole' height. Thank you.

\documentclass{article}
\usepackage{graphicx} % Required for inserting images
\usepackage{tikz,circuitikz}
\usepackage[singlelinecheck=off]{caption}
\usepackage{float}


\begin{figure}[H]
\begin{minipage}{\textwidth}
 \renewcommand{\arraystretch}{1.0}
    \centering
    \Large
    \begin{tabular}{ccc}
    \scalebox{0.5}{
    \begin{circuitikz}[]
  \draw[]
  (0,3) to [R, l=$\mathbf{R_0}$,o-] (2,3) -- (2,4)
  to [C, l=$\mathbf{Q_{1}}$] (6,4) -- (6,3)
  to [short, -o] (7,3)
  (2,3) -- (2,2) to [R, l=$\mathbf{R_1}$] (6,2) -- (6,3); 
    \end{circuitikz}
    } & 
    \scalebox{0.5}{
     \begin{circuitikz}[]
  \draw[]
  (0,4) to [R, l=$R_0$,o-] (2,4) -- (2,5)
  to [C, l=$Q_{1}$] (8,5) -- (8,4)
  to [short, -o] (9,4)
  (2,4) -- (2,2) to [R, l=$R_1$] (4,2) -- (4,3)
  to [C, l=$Q_{2}$] (8,3)
  (4,2) -- (4,1) to [R, l=$R_2$] (8,1) -- (8,4); 
    \end{circuitikz}
    } & 
    \scalebox{0.5}{
    \begin{circuitikz}[]
  \draw[]
  (0,4) to [R, l=$R_0$,o-] (2,4) -- (2,5)
  to [C, l=$Q_{1}$] (9,5) -- (9,4)
  to [short, -o] (10,4)
  (2,4) -- (2,2) to [R, l=$R_1$] (4,2) -- (4,3)
  to [C, l=$Q_{2}$] (9,3)
  (4,2) -- (4,0) to [R, l=$R_2$] (6,0) -- (6,1)
  to [R, l=$R_3$] (9,1)
  (6,0) -- (6,-1) to [C, l=$Q_{3}$] (9,-1) -- (9,4); 
    \end{circuitikz}
    }\\ 
    \small(a) Randles & \small(b) 2 TC & \small(b) 3 TC
\end{tabular}
\end{minipage}
\vspace{-3pt}    
\captionsetup{labelfont=bf,labelsep=period,font=small}
    \caption{description}
    \label{fig:circuits}
\end{figure}

2 Answers 2

1

Another possibility is:

  • for pictures define baseline: baseline=(current bounding box.north)
  • use tabularray for table
  • remove minipages

\documentclass{article}
%\usepackage{geometry} 
\usepackage{circuitikz}
\usepackage[skip=1ex,
            labelfont=bf,labelsep=period,font=small,
            singlelinecheck=off]{caption, subcaption}
\usepackage{tabularray}

\begin{document}
    \begin{figure}[ht]
\tikzset{
    every picture/.append style = {baseline=(current bounding box.north), 
                                   scale=0.53, transform shape}
        }
\ctikzset{
    bipoles/capacitor/height=0.44,
    bipoles/capacitor/width=0.1,
        }
\begin{tblr}{colspec = {*{3}{Q[c]} }, 
             colsep  = 3pt,
             row{2}  = {font=\small, mode=math},
             row{3}  = {font=\small}
             }
    \begin{circuitikz}
\draw   (0,3) to [R, l=$\mathbf{R_0}$,o-] ++ (2,0) coordinate (aux)
              -- ++ (0, 1) 
              to [C, l=$\mathbf{Q_{1}}$]  ++ (2,0) -- ++ (0,-1)
              to [short, -o] ++ (1,0)
        (aux) -- ++ (0,-1) 
              to [R, l=$\mathbf{R_1}$]    ++ (2,0) -- ++ (0,1);
    \end{circuitikz}
    &   \begin{circuitikz}
        \draw   (0,4) to [R, l=$\mathbf{R_0}$,o-] ++ (2,0) coordinate (a)
                      -- ++ (0, 1)
                      to [C, l=$Q_{1}$]     ++ (4,0) -- ++ (0,-1)
                      to [short, -o] ++ (1,0)
                (a)   -- ++ (0,-1)
                      to [R, l=$R_1$]       ++ (2,0) coordinate (b)
                (b)   -- ++ (0, 1)
                      to [C, l=$Q_{2}$]     ++ (2,0)
                (b)   -- ++ (0,-1)
                      to [R, l=$R_2$]       ++ (2,0) -- ++ (0,2);
        \end{circuitikz}
    &   \begin{circuitikz}
        \draw   (0,5) to [R, l=$\mathbf{R_0}$,o-] ++ (2,0) coordinate (a)
                              -- ++ (0, 1)
                              to [C, l=$Q_{1}$]     ++ (6,0) -- ++ (0,-1)
                              to [short, -o] ++ (1,0)
                (a)   -- ++ (0,-1)
                      to [R, l=$R_1$]       ++ (2,0) coordinate (b)
                (b)   -- ++ (0, 1)
                      to [C, l=$Q_{2}$]     ++ (4,0)
                (b)   -- ++ (0,-1)
                      to [R, l=$R_2$]       ++ (2,0) coordinate (c)
                (c)   -- ++ (0, 1)
                      to [R, l=$R_3$]       ++ (2,0)
                (c)   -- ++ (0,-1)
                      to [C, l=$Q_{3}$]     ++ (2,0) -- ++ (0,3);
        \end{circuitikz}   \\
R(QR)       &   R(Q(R(QR))) &   R(Q(R(Q(R(QR)))))   \\
(a) Randles &   (b) 2 TC    &   (c) 3 TC
\end{tblr}
    \caption{Representación de los circuitos equivalentes modelados en este trabajo.}
    \label{fig:circuitos}
\end{figure}

\end{document}

enter image description here

(red lines indicate page layout)

Note:

  • You may consider to increase text block by use of the geometry package and accordingly enlarge image scale value (for example at \usepackage[margin=25mm]{geometry} to scale=0.75) and by this make scheme better readable:

enter image description here

  • I took a liberty and redraw schemes with use of the relative coordinates. You may liked this way of drawing them.
2
  • Thank you for you answer. My knowledge about latex is still somewhat limited. I will give you the answer, I guess it is more efficient than mine (but I keep my answer since I prefer code I feel capable to deal with). May 20 at 16:30
  • @AnibalMarrero, as you wish. However, now you have a unique opportunity to learn something new ... it may be very useful in the future projects.
    – Zarko
    May 20 at 16:54
0

Finally I managed to solve it using the minipage environment command \raisebox.

\documentclass{article}
\usepackage{graphicx} % Required for inserting images
\usepackage{tikz,circuitikz}
\usepackage[singlelinecheck=off]{caption}
\usepackage{float}

\begin{document}

\begin{figure}[H]
\begin{minipage}{\textwidth}
 \renewcommand{\arraystretch}{1.0}
    \centering
    \Large
    \begin{tabular}{ccc}
    \raisebox{0.8\height}{\scalebox{0.5}{
    \begin{circuitikz}[]
  \draw[]
  (0,3) to [R, l=$\mathbf{R_0}$,o-] (2,3) -- (2,4)
  to [C, l=$\mathbf{Q_{1}}$] (6,4) -- (6,3)
  to [short, -o] (7,3)
  (2,3) -- (2,2) to [R, l=$\mathbf{R_1}$] (6,2) -- (6,3); 
    \end{circuitikz}
    }} & 
    \raisebox{0.14\height}{\scalebox{0.5}{
     \begin{circuitikz}[]
  \draw[]
  (0,4) to [R, l=$R_0$,o-] (2,4) -- (2,5)
  to [C, l=$Q_{1}$] (8,5) -- (8,4)
  to [short, -o] (9,4)
  (2,4) -- (2,2) to [R, l=$R_1$] (4,2) -- (4,3)
  to [C, l=$Q_{2}$] (8,3)
  (4,2) -- (4,1) to [R, l=$R_2$] (8,1) -- (8,4); 
    \end{circuitikz}
    }} & 
    \raisebox{-0.19\height}{\scalebox{0.5}{
    \begin{circuitikz}[]
  \draw[]
  (0,4) to [R, l=$R_0$,o-] (2,4) -- (2,5)
  to [C, l=$Q_{1}$] (9,5) -- (9,4)
  to [short, -o] (10,4)
  (2,4) -- (2,2) to [R, l=$R_1$] (4,2) -- (4,3)
  to [C, l=$Q_{2}$] (9,3)
  (4,2) -- (4,0) to [R, l=$R_2$] (6,0) -- (6,1)
  to [R, l=$R_3$] (9,1)
  (6,0) -- (6,-1) to [C, l=$Q_{3}$] (9,-1) -- (9,4); 
    \end{circuitikz}
    }}\\ 
    \small$R(QR)$ & \small$R(Q(R(QR)))$ & \small$R(Q(R(Q(R(QR)))))$ \\
    \small(a) Randles & \small(b) 2 TC & \small(c) 3 TC
\end{tabular}
\end{minipage}
\vspace{-3pt}    
\captionsetup{labelfont=bf,labelsep=period,font=small}
    \caption{Representación de los circuitos equivalentes modelados en este trabajo.}
    \label{fig:circuitos}
\end{figure}

\end{document}

Another options/solutions/advises will be apreciated anyway. I hope my answer will be useful anyway.

You must log in to answer this question.

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