7

I'm new to LaTeX and I don't know how to put a block diagram in an electrical circuit.

enter image description here

I'm all done with it except the block with G.

Here is my code :

    \begin{circuitikz}[scale=3]
\draw (0,1.5) 
to [ european resistor=$R$] (1.35,1.5)
to [fullgeneric=$L$] (2,1.5)
to [capacitor=$C$] (3,1.5)
to [short,i=$i(t)$](3,0)
to(0,0)
to(0,1.5)

;


\end{circuitikz}

So what's the hack with that block, I don't have any idea.

1
  • 1
    I still prefer elmech, assuming this is a generator. May 29 '19 at 20:59
3

\documentclass[margin=3mm]{standalone}
\usepackage{circuitikz}
\usepackage{amsmath}          % <---
\newcommand\ds{\displaystyle} % <---

\begin{document}
    \begin{circuitikz}[scale=3, european]
\draw (0,1) to [R=$R$] ++ (1,0)
            to [L=$L$] ++ (1,0)
            to [C=$C$] ++ (1,0)
            to [short,i=$i(t)$] ++ (0,-1)
            to [twoport,t=\Large $G$, 
                l={$\xrightarrow[\ds u_e(t)]{}$}]   (0,0) % <---
            -- (0,1);
\end{circuitikz}
\end{document}

gives:

enter image description here

addendum:

If you like to have circuit's elements on opposite side, than you can write:

\draw (0,1) to [R,a=$R$] ++ (1,0)
            to [L,a=$L$] ++ (1,0)
            to [C,a=$C$] ++ (1,0)
            to [short,i=$i(t)$] ++ (0,-1)
            to [twoport,t=\Large $G$,
                l={$\xrightarrow[\ds u_e(t)]{}$}]   (0,0) % <---
            -- (0,1);

or

\draw (0,1) to [R,l_=$R$] ++ (1,0)
            to [L,l_=$L$] ++ (1,0)
            to [C,l_=$C$] ++ (1,0)
            to [short,i=$i(t)$] ++ (0,-1)
            to [twoport,t=\Large $G$,
                l={$\xrightarrow[\ds u_e(t)]{}$}]   (0,0) % <---
            -- (0,1);

in both cases the result is the same:

enter image description here

0

I solve now the problem with the G inside the block but I can't to draw a vector u_e(t),

 to [twoport,t=\Large $G$] (0,0)
1
  • Please edit your question, or post a comment. This is not what answers are used for :)
    – Tvde1
    May 29 '19 at 17:51

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.