1

I need this

enter image description here

and this is my code so far:

enter image description here

  \begin{center}
  \shorthandoff{:!}
  \begin{figure}[H]     % Montage pour essai à vide
  \centering
  \begin{adjustbox}         {scale=1} % scaling factor du schéma
     \begin{circuitikz}[american, cute inductors]
        \draw
        %%-----V in-----%% 
        (0, 0) to [sV,l={V$_g$}] (0,4)
        to [short] ++(3,0) coordinate (1)
        to [short, i_={I$_{m}$}] ++(0,-1) coordinate (2)
        to [short] ++(-.5,0) 
        to [short, i_={I$_{fe}$}] ++(0,-.5) 
        to [R,l={R$_{fe}$}] ++(0,-2)
        to [short] ++(+.5,0) coordinate (3)
        to [short] ++(0,-.5) coordinate (4)
        to [short] (0,0)

        %-----------
        (2) to [short] ++(+.5,0) 
        to [short, i={I$_{\psi}$}] ++(0,-.5) 
        to [L,l={X$_{\psi}$}] ++(0,-2)
        to [short] (3)

       %-------------
       (1) to [short, i={I$_{2}$}] ++(2,0) 
        to [R,l={R$_{eq}$}] ++(2,0)
        to [L,l={X$_{eq}$}] ++(2,0)
        node[transformer, anchor=A1,yscale=1.9] (T) {}
        (T.A2)  to [short] (4)

        (T.B1)   to [short] ++(1,0)
        to [generic] ++(0,-4)
        to [short] (T.B2)
                ;
        \end{circuitikz}  
    \end{adjustbox}
    \caption{Montage pour essai à vide} \label{MontageEssaiVide}
    \end{figure}
  \shorthandon{:!}
  \end{center}

I have played a bit with the american / european current and voltage arrow, but can't make it work with my circuit.

So I would like to knw how to make Curved arrows with label in the middle ?

How can I add $Z_c$ insde the generic component ?

How to box the Outside of the transformer ?

And finally, can I have multiple type of arrows in the same drawing, it look like if I change the european / american arrows, it change for all of them.

thanks

1

Curved arrows: Use \draw[->] (node1) edge [bend X=Y] (node2); where X can be left or right and Y gives the degree of bending. With the tikz library arrows you get a variety of arrows. By adding the option >=stealth' you get a particular type of arrow, shorten >=3pt tells to stop in a distance of 3pt before the destination.

Label inside the generic component: I add \hspace{-3.5cm} to the normal label that would otherwise be outside. Just a hack, but I found no other solution.

Box around transformer: \draw[dashed] (T) +(-1,-4.2) rectangle +(1,0.2); draws a dashed rectangle relative to node (T). Note that the single + does not change the position, hence the opposing corners of the rectangle are (T)+(-1,-4.2) and (T)+(1,0.2).

Multiple types of arrows: I'm not completely sure what you mean. You now have already two types of arrows. Maybe ask another question with a more precise description.

\documentclass[border=1mm]{standalone}
\usepackage{circuitikz}
\usetikzlibrary{arrows}
\begin{document}
\begin{circuitikz}[american, cute inductors]
\draw
%%-----V in-----%% 
(0, 0) to [sV,l={V$_g$}] (0,4)
to [short,-o] ++(1,0) coordinate (a) %%% NEW
to [short] ++(2,0) coordinate (1)    %%% CHANGED
to [short, i_={I$_{m}$}] ++(0,-1) coordinate (2)
to [short] ++(-.5,0) 
to [short, i_={I$_{fe}$}] ++(0,-.5) 
to [R,l={R$_{fe}$}] ++(0,-2)
to [short] ++(+.5,0) coordinate (3)
to [short] ++(0,-.5) coordinate (4)
to [short,-o] (1,0) coordinate (b)   %%% NEW
to [short] (0,0)

%-----------
(2) to [short] ++(+.5,0) 
to [short, i={I$_{\psi}$}] ++(0,-.5) 
to [L,l={X$_{\psi}$}] ++(0,-2)
to [short] (3)

%-------------
(1) to [short, i={I$_{2}$}] ++(2,0) 
to [R,l={R$_{eq}$}] ++(2,0)
to [L,l={X$_{eq}$}] ++(2,0)
node[transformer, anchor=A1,yscale=1.9] (T) {}
(T.A2)  to [short] (4)

(T.B1)
to [short,-o] ++(1,0) coordinate (c) %%% NEW
to [short] ++(1,0)
to [generic,l={\hspace{-3.5ex}$\mathrm{Z}_c$}] ++(0,-4)) %%% CHANGED
to [short,-o] ++(-1,0) coordinate (d)%%% NEW
to [short] (T.B2)
;
%%% NEW NEW NEW
\path (a) -- node[xshift=3ex] (Eg) {$\mathrm{E}_g$} (b);
\draw[->,>=stealth',shorten >=3pt]
   (Eg) edge[bend right=10] (a)
        edge[bend left=10]  (b);
\path (c) -- node[xshift=-3ex] (Ec) {$\mathrm{E}_c$} (d);
\draw[->,>=stealth',shorten >=3pt]
   (Ec) edge[bend left=10]  (c)
        edge[bend right=10] (d);
\draw[dashed] (T) +(-1,-4.2) rectangle +(1,0.2);
\end{circuitikz}  
\end{document}

enter image description here

Addendum: To magnify components, use the /tikz/circuitikz/bipoles/length option, like that:

node[transformer, anchor=A1,yscale=1.9,/tikz/circuitikz/bipoles/length=2.5cm] (T) {}
[L,l={X$_{eq}$},/tikz/circuitikz/bipoles/length=2.5cm]

In the circuitikz components you can shorten the key to bipoles/length, in the tikz elements to circuitikz/bipoles/length, resulting in

node[transformer, anchor=A1,yscale=1.9,circuitikz/bipoles/length=2.5cm] (T) {}
[L,l={X$_{eq}$},bipoles/length=2.5cm]
3
  • Woaw, that's a lot of information. Thank you for answering all this. Oct 28 '16 at 16:28
  • Do you by any chance know a way to stretch the look of the inductor (&Transformer) ? Oct 28 '16 at 16:29
  • @SebastienComtois I've added a note on how to magnify components.
    – gernot
    Oct 28 '16 at 16:56

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.