Circuitikz: 電磁リレーの描き方

Circuitikz: 電磁リレーの描き方

circuitikz図のような電磁リレーを描くにはどうすればよいでしょうか?

ここに画像の説明を入力してください

答え1

ここに画像の説明を入力してください

\documentclass[a4paper,12pt]{article}
\usepackage{tikz}


\begin{document}
\tikzset{every picture/.style={line width=0.75pt}} %set default line width to 0.75pt        

\begin{tikzpicture}[x=0.75pt,y=0.75pt,yscale=-1,xscale=1]
%uncomment if require: \path (0,300); %set diagram left start at 0, and has height of 300

%Shape: Rectangle [id:dp22513190107195968] 
\draw   (188,66) -- (301,66) -- (301,222) -- (188,222) -- cycle ;
%Shape: Inductor [id:dp24736203754521235] 
\draw   (206,243) -- (206,214.76) .. controls (206,208.27) and (210.48,203) .. (216,203) .. controls (221.52,203) and (226,208.27) .. (226,214.76) .. controls (226,208.27) and (230.48,203) .. (236,203) .. controls (241.52,203) and (246,208.27) .. (246,214.76) .. controls (246,208.27) and (250.48,203) .. (256,203) .. controls (261.52,203) and (266,208.27) .. (266,214.76) .. controls (266,208.27) and (270.48,203) .. (276,203) .. controls (281.52,203) and (286,208.27) .. (286,214.76) -- (286,243) ;
%Straight Lines [id:da051095141436859226] 
\draw    (156,109) -- (201,109) ;
%Shape: Circle [id:dp6778515719894689] 
\draw  [fill={rgb, 255:red, 0; green, 0; blue, 0 }  ,fill opacity=1 ] (192,109) .. controls (192,106.51) and (194.01,104.5) .. (196.5,104.5) .. controls (198.99,104.5) and (201,106.51) .. (201,109) .. controls (201,111.49) and (198.99,113.5) .. (196.5,113.5) .. controls (194.01,113.5) and (192,111.49) .. (192,109) -- cycle ;
%Straight Lines [id:da9500019856156845] 
\draw    (196.5,109) -- (288,92) ;
%Shape: Circle [id:dp44500646469446004] 
\draw  [fill={rgb, 255:red, 0; green, 0; blue, 0 }  ,fill opacity=1 ] (288,137) .. controls (288,134.51) and (290.01,132.5) .. (292.5,132.5) .. controls (294.99,132.5) and (297,134.51) .. (297,137) .. controls (297,139.49) and (294.99,141.5) .. (292.5,141.5) .. controls (290.01,141.5) and (288,139.49) .. (288,137) -- cycle ;
%Shape: Circle [id:dp7250475164712205] 
\draw  [fill={rgb, 255:red, 0; green, 0; blue, 0 }  ,fill opacity=1 ] (288,91) .. controls (288,88.51) and (290.01,86.5) .. (292.5,86.5) .. controls (294.99,86.5) and (297,88.51) .. (297,91) .. controls (297,93.49) and (294.99,95.5) .. (292.5,95.5) .. controls (290.01,95.5) and (288,93.49) .. (288,91) -- cycle ;
%Shape: Circle [id:dp8692741666377941] 
\draw  [fill={rgb, 255:red, 0; green, 0; blue, 0 }  ,fill opacity=1 ] (288,77) .. controls (288,74.51) and (290.01,72.5) .. (292.5,72.5) .. controls (294.99,72.5) and (297,74.51) .. (297,77) .. controls (297,79.49) and (294.99,81.5) .. (292.5,81.5) .. controls (290.01,81.5) and (288,79.49) .. (288,77) -- cycle ;
%Straight Lines [id:da07997281760069219] 
\draw    (292.5,77) -- (337.5,77) ;
%Straight Lines [id:da847301105775671] 
\draw    (292.5,137) -- (337.5,137) ;
%Straight Lines [id:da5564415966210661] 
\draw  [dash pattern={on 4.5pt off 4.5pt}]  (246,105) -- (246,214.76) ;

% Text Node
\draw (148,88) node [anchor=north west][inner sep=0.75pt]   [align=left] {C};
% Text Node
\draw (225,44) node [anchor=north west][inner sep=0.75pt]   [align=left] {Relay};
% Text Node
\draw (234,230.76) node [anchor=north west][inner sep=0.75pt]   [align=left] {Coil};
% Text Node
\draw (329,58) node [anchor=north west][inner sep=0.75pt]   [align=left] {NC};
% Text Node
\draw (329,116) node [anchor=north west][inner sep=0.75pt]   [align=left] {NO};


\end{tikzpicture}

\end{document}

関連情報