2

I want to draw the following figure, however, I can not put the name for the bold vertical line, and then I can not show the circles. I have tried to find the symbol for the transformer also, but I could not.

Could you help me with that? Thanks a lot.

Here is the code which I have tried (it is very basic)

\documentclass{article}
\usepackage{tikz}
\usepackage{verbatim}
\usetikzlibrary{shapes,arrows.meta,decorations, positioning, arrows.meta, calc, shapes.geometric}
\usetikzlibrary{shapes, arrows,positioning}
\usetikzlibrary{shapes,arrows.meta,decorations}
\begin{document}
\tikzset{
line/.style = {line width=1pt, draw=black},
shin/.style = {line, line width=3pt},
net node/.style = {circle, draw=black,line width=1.2pt,minimum width=0.8cm, inner sep=0pt, outer 
sep=0pt},
}

 \begin{tikzpicture}
   \path [shin] (0.8,-2) -- (0.8,2);
\path [shin] (4.8,-2) -- (4.8,2);
\path [shin] (8,-4) -- (8,4);
\path [line] (8,3) --  (9, 3);
\path [line] (8,2) --  (9, 2);
\path [line] (8,1) --  (9, 1);
\path [line] (8,0) --  (9, 0);
\path [line] (8,-1) --  (9, -1);
\path [line] (8,-2) --  (9, -2);
\path [line] (8,-3) --  (9, -3);
\path [line] (8,-3.5) --  (7, -3.5);
\coordinate(net node) at (9,3);
\end{tikzpicture}
\end{document}

enter image description here

3

1 Answer 1

4

So, the following builds up on my previous answer https://tex.stackexchange.com/a/595368/38080 --- I added a parameter to the \bushere macro, and then I show how to use circuitikz elements to mimic your diagram. You have still to complete it, but I think now it should be straightforward:

\documentclass[border=10pt]{standalone}
\usepackage[RPvoltages]{circuitikz}

\newcommand{\bushere}[3]{% length, text above, text below
    % optional arguments do not work in paths
    %
    % starting point; draw an edge and then two nodes
    % save the position
    coordinate(tmp)
    % go up and do an edge down
    ++(0,#1) node[anchor=base]{#2} edge[ultra thick] ++(0,{-2*#1})
    % edges do not move the current point, go down to position the node
    ++(0,{-2*#1}) node[below]{#3}
    % go back to where we started
    (tmp)
}
\begin{document}
\ctikzset{sources/fill=gray!20, resistors/fill=gray!20}
\begin{tikzpicture}[semithick]% default line width
    \draw (0,0)
        \bushere{1}{System Bus}{}
        to[oosourcetrans, name=trafo] ++(3,0)
        \bushere{1}{Low-side Bus}{} coordinate(low side)
        -- ++(1,0) coordinate(c1)
        to[generic, l={\small Feeder equivalent}, resistors/width=3] ++(5,0)
        coordinate(c2) -- ++(1,0)
        \bushere{3}{Load bus}{} coordinate(load)
        ;
    % capacitors
    \draw (c1) to[C] ++(0,-1) node[ground]{};
    \draw (c2) to[C] ++(0,-1) node[ground]{};
    \draw (low side) ++(0,-0.7) -- ++(-0.7,0) to[C] ++(0,-1) node[ground]{};
    % variable arrow
    \draw[-Stealth] (trafo.center) ++(-0.5,-0.5) -- ++(1,1);
    % one load
    % position: start form the coord load, go up
    \ctikzset{bipoles/border margin=1.0}% see manual section 3.1.2
    \draw (load) ++(0,1) -- ++(1,0) node[rmetershape, fill=cyan, t=M]{}
        ++(1,0) node[right]{Motor 1};
    \draw (load) ++(0,-2) -- ++(0.5,0) node[draw, fill=orange!30, anchor=west]{Static Load};
\end{tikzpicture}
\end{document}

enter image description here

4
  • Thank you so much @Rmano. It is great
    – Sadcow
    May 21, 2021 at 4:04
  • For the rectangular shape which connected to the Load bus, I have searched but I did not find anything like "rmetershape". Do you know what is the name of the symbol of that?
    – Sadcow
    May 21, 2021 at 4:53
  • ...you can use a standard Tikz node, they are rectangular. node[draw, fill=red]{whatever text here}. I really advise reading the first tutorial in the TikZ manual....
    – Rmano
    May 21, 2021 at 5:53
  • Thank you su much.
    – Sadcow
    May 21, 2021 at 6:37

You must log in to answer this question.

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