dimanche 28 février 2016

Exemple de champ électrique et magnétique en un point P de l'espace et de son évolution dans le temps (par Carlo Alberini)

Esempio di campo elettrico e magnetico in un punto P dello spazio e sua evoluzione temporale. I campi sono prodotti da elettroni posti in oscillazione in un'antenna alimentata in corrente alternata.

Les fichiers (ondesHertziennes-3Dvector_2.pdf et /ondesHertziennes-3Dvector_2.tex) dans :


Le listing :

\documentclass[12pt]{article}
\usepackage[a4paper]{geometry}
\usepackage[garamond]{mathdesign}
\renewcommand{\ttdefault}{lmtt}
\usepackage[nomessages]{fp}
\usepackage[dvipsnames,svgnames]{pstricks}
\usepackage{pst-plot,pst-3d,pst-node,pst-circ}
\usepackage{animate}

\def\Vitesse{5}    % célérité en m/s
\def\Periode{1}    % période en seconde
\def\Amplitude{1}  % amplitude
\psset{dimen=middle}
\pagestyle{empty}
\def\nFrames{72}
\psset{plotpoints=1000,plotstyle=line}
\newdimen\temporaire

\title{Ondes hertziennes}
\begin{document}
\maketitle
\begin{center}
\begin{animateinline}[controls,
                     begin={\begin{pspicture}(-2,-7)(15,3)},
                     end={\end{pspicture}}]{5}% 5 images/s
\multiframe{72}{rt=0+0.04}{
\pstVerb{/Vitesse \Vitesse\space def
    /Periode \Periode\space def
    /Amplitude \Amplitude\space def
         /date \rt\space def
         /Vt Vitesse date mul def
           /t1 Periode 4 div def % Lambda/4
           /X1 t1 Vitesse mul def
           /t2 Periode 2 div def
           /X2 t2 Vitesse mul def % Lambda/2
           /t3 Periode 4 div 3 mul def
           /X3 t3 Vitesse mul def % 3*Lambda/4
           /t4 Periode  def
          % /X4 Lambda def %
           /x1 1 def
% y(x,t)=a*sin(2Pi/T(t-x/V)
     /Signal {xPos Vt le { /yPos Amplitude 360 Periode div date xPos Vitesse div sub mul sin mul def }
             {/yPos 0 def} ifelse
             } def
% amplitude du signal
      /Y1 Amplitude 360 Periode div
                      t1 1 Vitesse div sub
                      mul
                      sin
                      mul
                      def
        /Y2 Amplitude 360 Periode div
                      t2 1 Vitesse div sub
                      mul
                      sin
                      mul
                      def
        /Y3 Amplitude 360 Periode div
                      t3 1 Vitesse div sub
                      mul
                      sin
                      mul
                      def
        /Y4 Amplitude 360 Periode div
                      t4 1 Vitesse div sub
                      mul
                      sin
                      mul
                      def
            }%
% la corde
\psset{viewpoint=0.5 -1 0.75}
\ThreeDput[normal=0 0 -1](0,0,0){%
\psgrid[subgriddiv=0,gridcolor=red,griddots=10,gridlabels=0pt](0,0)(14,-2)
\psframe[fillstyle=solid,linecolor=red,fillcolor=red!10,opacity=0.6](0,0)(14,-2)
}
\ThreeDput[normal=0 -1 0](0,0,0){%
\psgrid[subgriddiv=0,gridcolor=PineGreen,griddots=10,gridlabels=0pt](0,-2)(14,2)
\psframe[fillstyle=solid,linecolor=PineGreen,fillcolor=PineGreen!05,opacity=0.6](0,-2)(14,2)
\uput[0](0.2,1.5){\textcolor{PineGreen}{$\overrightarrow{E\hspace{0.2em}}$}}
\FPeval{\Front}{\Vitesse*\rt}
        \parametricplot[linecolor=PineGreen,linewidth=0.05]{0}{Vt}{%
    /xPos t def % X=abscisse en m
    Signal t yPos}%
    \temporaire=\Front pt
        \ifdim\temporaire > 1pt
            \psline[linecolor=red,arrowsize=0.15]{->}(! 1 0)(! 1 dup  /xPos exch def Signal yPos)
            \uput[l](! 1.15 dup  /xPos exch def Signal yPos){$\scriptstyle{\vec{E}\left(P,t\right)}$}
\fi
        \ifdim\temporaire > 1.5pt
            \psline[linecolor={[rgb]{0.75 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 0.5 sub 0)(! Vt 0.5 sub  Y1 2 mul)
            \uput[l](! Vt -0.1 sub -0.25){$\scriptstyle{\vec{E}\left(P,t_{1}\right)}$}
\fi
        \ifdim\temporaire > 2.75pt
            \psline[linecolor={[rgb]{0 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 1.75 sub 0)(! Vt 1.75 sub  Y2 -0.1 add)
            \uput[l](! Vt 1.15 sub -0.25){$\scriptstyle{\vec{E}\left(P,t_{2}\right)}$}
\fi
        \ifdim\temporaire > 4pt
            \psline[linecolor={[rgb]{0.75 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 3 sub 0)(! Vt 3 sub  Y3 2 mul)
            \uput[l](! Vt 2.4 sub 0.25){$\scriptstyle{\vec{E}\left(P,t_{3}\right)}$}
\fi
        \ifdim\temporaire > 5pt
            \psline[linecolor={[rgb]{0 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 4 sub 0)(! Vt 4 sub  Y4)
            \uput[l](! Vt 3.5 sub 0.25){$\scriptstyle{\vec{E}\left(P,t_{4}\right)}$}
\fi
        \ifdim\temporaire > 6.75pt
            \psline[linecolor={[rgb]{0.75 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 5.75 sub 0)(! Vt 5.75 sub  Y2 -0.1 add)
            \uput[l](! Vt 5.15 sub -0.25){$\scriptstyle{\vec{E}\left(P,t_{5}\right)}$}
\fi
        \ifdim\temporaire > 8pt
            \psline[linecolor={[rgb]{0 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 7 sub 0)(! Vt 7 sub  Y1 2 mul)
            \uput[l](! Vt 6.4 sub -0.25){$\scriptstyle{\vec{E}\left(P,t_{6}\right)}$}
\fi
        \ifdim\temporaire > 9.5pt
            \psline[linecolor={[rgb]{0.75 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 8.5 sub 0)(! Vt 8.5 sub  Y4)
            \uput[l](! Vt 7.75 sub 0.25){$\scriptstyle{\vec{E}\left(P,t_{7}\right)}$}
\fi
        \ifdim\temporaire > 10.5pt
            \psline[linecolor={[rgb]{0 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 9.5 sub 0)(! Vt 9.5 sub  Y3 2 mul)
            \uput[l](! Vt 8.9 sub 0.25){$\scriptstyle{\vec{E}\left(P,t_{8}\right)}$}
\fi
        \ifdim\temporaire > 11.5pt
            \psline[linecolor={[rgb]{0.75 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 10.5 sub 0)(! Vt 10.5 sub  Y1 2 mul)
            \uput[l](! Vt 9.9 sub -0.25){$\scriptstyle{\vec{E}\left(P,t_{9}\right)}$}
\fi
        \ifdim\temporaire > 12.75pt
            \psline[linecolor={[rgb]{0 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 11.75 sub 0)(! Vt 11.75 sub  Y2 -0.1 add)
            \uput[l](! Vt 11.15 sub -0.25){$\scriptstyle{\vec{E}\left(P,t_{10}\right)}$}
\fi
        \psline[linecolor=blue,linewidth=2.5mm,linecap=1](0,-2.5)(0,1.75)
% la source
\psdot[linecolor=white,dotsize=2mm](! 0 dup  /xPos exch def Signal yPos)
        \psline[linecolor=red,arrowsize=0.25]{->}(! 0 0)(! 0 dup  /xPos exch def Signal yPos)
        \uput[l](! 0 dup  /xPos exch def Signal yPos){$e^{-}$}
        \vac[output=bottom](0.5,-3)(-0.5,-3){$V_{AC}$}}
 %le plan Oxy
\ThreeDput[normal=0 0 -1](0,0,0){%
\psgrid[subgriddiv=0,gridcolor=red,griddots=10,gridlabels=0pt](0,0)(14,2)
\psframe[fillstyle=solid,linecolor=red,fillcolor=red!10,opacity=0.6](0,0)(14,2)
\FPeval{\Front}{\Vitesse*\rt}
        \parametricplot[linecolor=red,linewidth=0.05]{0}{Vt}{%
    /xPos t def % X=abscisse en m
    Signal t yPos}%
% la source
    \temporaire=\Front pt
        \ifdim\temporaire > 1pt
            \psline[linecolor=red,arrowsize=0.15]{->}(! 1 0)(! 1 dup  /xPos exch def Signal yPos)
\fi
        \ifdim\temporaire > 1.5pt
            \psline[linecolor={[rgb]{0.75 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 0.5 sub 0)(! Vt 0.5 sub  Y1 2 mul)
\fi
        \ifdim\temporaire > 2.75pt
            \psline[linecolor={[rgb]{0 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 1.75 sub 0)(! Vt 1.75 sub  Y2 -0.1 add)
\fi
        \ifdim\temporaire > 4pt
            \psline[linecolor={[rgb]{0.75 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 3 sub 0)(! Vt 3 sub  Y3 2 mul)
\fi
        \ifdim\temporaire > 5pt
            \psline[linecolor={[rgb]{0 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 4 sub 0)(! Vt 4 sub  Y4)
\fi
        \ifdim\temporaire > 6.75pt
            \psline[linecolor={[rgb]{0.75 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 5.75 sub 0)(! Vt 5.75 sub  Y2 -0.1 add)
\fi
        \ifdim\temporaire > 8pt
            \psline[linecolor={[rgb]{0 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 7 sub 0)(! Vt 7 sub  Y1 2 mul)
\fi
        \ifdim\temporaire > 9.5pt
            \psline[linecolor={[rgb]{0.75 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 8.5 sub 0)(! Vt 8.5 sub  Y4)
\fi
        \ifdim\temporaire > 10.5pt
            \psline[linecolor={[rgb]{0 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 9.5 sub 0)(! Vt 9.5 sub  Y3 2 mul)
\fi
        \ifdim\temporaire > 11.5pt
            \psline[linecolor={[rgb]{0.75 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 10.5 sub 0)(! Vt 10.5 sub  Y1 2 mul)
\fi
        \ifdim\temporaire > 12.75pt
            \psline[linecolor={[rgb]{0 0 1}},arrowsize=0.1,arrowinset=0,linewidth=0.03]{->}(! Vt 11.75 sub 0)(! Vt 11.75 sub  Y2 -0.1 add)
\fi
}
\ThreeDput[normal=0 -1 0](0,0,0){
        \rput[bl](1,0.15){\textcolor{Mahogany}{$\scriptstyle{P}$}}
        \psaxes[labelFontSize=\scriptstyle,xAxis=true,yAxis=false,labels=y,Dx=1,Dy=1,ticksize=-2pt 0,subticks=2]{->}(0,0)(-0.5,-0.5)(14.75,0.5)[$x$,90][ ,90]
        \psdot[dotsize=2mm,linecolor=Mahogany](1,0)
    }
\ThreeDput[normal=0 0 1](0,0,0){
     \uput[0](0.1,-1.7){\red{\footnotesize{$\vec{B}$}\hspace{0.2em}}}
     }
}
\end{animateinline}
\end{center}
\end{document}

Aucun commentaire:

Enregistrer un commentaire