3

I would like to have a figure similar like this enter image description here as far as I could get, this has been my humble attempt

\documentclass{article}
\usepackage[american]{circuitikz}
\usepackage{float}

    \begin{document}
    \begin{figure}[H]
                \begin{minipage}{.5\textwidth}
                    \centering
                    \begin{circuitikz}
                        \draw(0,0)
                        to[short,*-*](4,0)
                        ;
                        \draw(0,1.5)
                        to[short,*-](0.2,1.5)
                        to[/tikz/circuitikz/bipoles/length=0.8cm,L,l_=$ L_f $] (2,1.5)
                        to[/tikz/circuitikz/bipoles/length=0.8cm,L,l_=$ L_f $] (3.8,1.5)
                        to[short,-*](4,1.5)
                        ;
                        \draw(2,1.5)
                        to[/tikz/circuitikz/bipoles/length=0.8cm,C=$ C_f $] (2,0)
                        ;   
                    \end{circuitikz}
                \end{minipage}%
                \begin{minipage}{0.5\textwidth}
                    \centering
                    \begin{circuitikz}
                        \draw(7.1,0)
                        to[short,*-*](5,0)
                        to[short,-*](4.5,0)
                        to[short,-*](2.5,0)
                        to[short,-*](2,0)
                        to[short,*-*](0,0)
                        ;
                        \draw(0,1.5)
                        to[short,*-](0.2,1.5)
                        to[/tikz/circuitikz/bipoles/length=0.8cm,L,l_=$ L_f $] (2,1.5)
                        to[short,*-*](2.5,1.5)
                        to[short](4.5,1.5)
                        to[short,*-*](5,1.5)
                        to[/tikz/circuitikz/bipoles/length=0.8cm,L,l_=$ L_f $] (7,1.5)
                        to[short,-*](7.1,1.5)
                        ;
                        \draw(3.55,1.5)
                        to[/tikz/circuitikz/bipoles/length=0.8cm,C=$ C_f $] (3.55,0)
                        ;
                        \draw[dashed](0.4,1.8)--(1.8,1.8);
                        \draw[dashed](0.4,1.8)--(0.4,-0.2);
                        \draw[dashed](0.4,-0.2)--(1.8,-0.2);
                        \draw[dashed](1.8,-0.2)--(1.8,1.8);
    
    
                        \draw[dashed](2.65,1.8)--(4.35,1.8);
                        \draw[dashed](2.65,1.8)--(2.65,-0.2);
                        \draw[dashed](2.65,-0.2)--(4.35,-0.2);
                        \draw[dashed](4.35,-0.2)--(4.35,1.8);
    
                        \draw[dashed](5.3,1.8)--(6.7,1.8);
                        \draw[dashed](5.3,1.8)--(5.3,-0.2);
                        \draw[dashed](5.3,-0.2)--(6.7,-0.2);
                        \draw[dashed](6.7,-0.2)--(6.7,1.8);
    
                    \end{circuitikz}
                \end{minipage}
                \caption{Example of ladder LC network as cascaded connection of two basic two-port networks.}
            \end{figure}
        \end{document}

Producting the following outputenter image description here As it can be seen, need that < > symbol in the middle. I have tried raisebox but it doesn't work, and I would appreciate if the figures in both minipages could be a bit closer from each other, as it is another thig that I struggle with when using minipages.

Thank you.

1
  • any news? now you have two answers ... – Zarko Jun 26 '18 at 6:50
2

You don't really need the minipages. Circuitikz IS a tikzpicture. Wouldn't $\leftrightarrow$ be a better symbol?

\documentclass{article}
\usepackage[american]{circuitikz}
\usepackage{float}

    \begin{document}
    \begin{figure}[H]
                    \begin{circuitikz}[baseline=(current bounding box.center)]
                        \draw(0,0)
                        to[short,*-*](4,0)
                        ;
                        \draw(0,1.5)
                        to[short,*-](0.2,1.5)
                        to[/tikz/circuitikz/bipoles/length=0.8cm,L,l_=$ L_f $] (2,1.5)
                        to[/tikz/circuitikz/bipoles/length=0.8cm,L,l_=$ L_f $] (3.8,1.5)
                        to[short,-*](4,1.5)
                        ;
                        \draw(2,1.5)
                        to[/tikz/circuitikz/bipoles/length=0.8cm,C=$ C_f $] (2,0)
                        ;   
                    \end{circuitikz}
\hfill $<>$ \hfill
                    \begin{circuitikz}[baseline=(current bounding box.center)]
                        \draw(7.1,0)
                        to[short,*-*](5,0)
                        to[short,-*](4.5,0)
                        to[short,-*](2.5,0)
                        to[short,-*](2,0)
                        to[short,*-*](0,0)
                        ;
                        \draw(0,1.5)
                        to[short,*-](0.2,1.5)
                        to[/tikz/circuitikz/bipoles/length=0.8cm,L,l_=$ L_f $] (2,1.5)
                        to[short,*-*](2.5,1.5)
                        to[short](4.5,1.5)
                        to[short,*-*](5,1.5)
                        to[/tikz/circuitikz/bipoles/length=0.8cm,L,l_=$ L_f $] (7,1.5)
                        to[short,-*](7.1,1.5)
                        ;
                        \draw(3.55,1.5)
                        to[/tikz/circuitikz/bipoles/length=0.8cm,C=$ C_f $] (3.55,0)
                        ;
                        \draw[dashed](0.4,1.8)--(1.8,1.8);
                        \draw[dashed](0.4,1.8)--(0.4,-0.2);
                        \draw[dashed](0.4,-0.2)--(1.8,-0.2);
                        \draw[dashed](1.8,-0.2)--(1.8,1.8);


                        \draw[dashed](2.65,1.8)--(4.35,1.8);
                        \draw[dashed](2.65,1.8)--(2.65,-0.2);
                        \draw[dashed](2.65,-0.2)--(4.35,-0.2);
                        \draw[dashed](4.35,-0.2)--(4.35,1.8);

                        \draw[dashed](5.3,1.8)--(6.7,1.8);
                        \draw[dashed](5.3,1.8)--(5.3,-0.2);
                        \draw[dashed](5.3,-0.2)--(6.7,-0.2);
                        \draw[dashed](6.7,-0.2)--(6.7,1.8);

                    \end{circuitikz}
                \caption{Example of ladder LC network as cascaded connection of two basic two-port networks.}
            \end{figure}
        \end{document}

demo

2

as supplement to John Kormylo's answer (which solve op problem) focused on off-topic issues how to write circuits' codes shorter and concise:

\documentclass[margin=3mm]{standalone}
\usepackage[american]{circuitikz}
\ctikzset{bipoles/length=0.8cm} 

\begin{document}
    \begin{circuitikz}[baseline=(current bounding box.center)]
]
\draw   (0,1.5)     to [L,l_=$L_f$,*-] ++ (2.2,0)
                    to [L,l_=$L_f$,-*] ++ (2.2,0)
        (2.2,1.5)   to [C=$C_f$,*-*]   ++ (0,-1.5)
        (0,0)       to [short,*-*]        (4.4,0)
        ;
    \end{circuitikz}
\hfill $\longleftrightarrow$ \hfill
    \begin{circuitikz}[baseline=(current bounding box.center),
    box/.style = {draw, dashed, minimum height=20mm, minimum width=18mm},
                        ]
\draw   (0,1.5)     to [short,*-o]  ++ (0.2,0)
                    to [L,l_=$L_f$] ++ (1.8,0)
                    to [short,o-o]  ++ (0.4,0)
                    --              ++ (1.8,0)
                    to [short,o-o]  ++ (0.4,0)
                    to [L,l_=$L_f$] ++ (1.8,0)
                    to [short,o-*]  ++ (0.2,0)
        (3.3,1.5)   to [C=$C_f$,*-*]   ++ (0,-1.5)
        (0,0)       to [short,*-o]  ++ (0.2,0) -- ++ (1.8,0) 
                    to [short,o-o]  ++ (0.4,0) -- ++ (1.8,0)
                    to [short,o-o]  ++ (0.4,0) -- ++ (1.8,0)
                    to [short,o-*]  ++ (0.2,0)
        ;
\node[box]  at (1.1,0.8) {};
\node[box]  at (3.3,0.8) {};
\node[box]  at (5.5,0.8) {};
    \end{circuitikz}
\end{document}

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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