0

oscillogramme

I need to replicate this oscillogram using LaTeX. I know a bit of TiKZ but I would like to have some tips or packages to get started building this and at the end come up my own to draw others like this.

$u(t) = 8\cos(400\pi t)$ and $i(t) = 0,2\cos(400\pi t - \dfrac{2\pi}{5})$ are examples.
6

1 Answer 1

1

Maybe you could alter this, with the equations you need?

\documentclass{article}
\usepackage{pgfplots}
\usepackage[graphics,tightpage,active]{preview}

\PreviewEnvironment{tikzpicture}
\pgfplotsset{compat=1.9}
\usetikzlibrary{backgrounds}

\begin{document}

    \begin{tikzpicture}
    \begin{axis}[
        ymin=-4,%
        ymax=4,%
        grid=both,%
        %axis on top
        ]
     \begin{scope}[on background layer]
    \fill[blue,opacity=0.5] ({rel axis cs:0,0}) rectangle ({rel axis cs:1,1});

    \end{scope}
     \addplot[domain=-360:360, white , very thick, smooth]{sin(x)}; %add equation here
    \addplot[domain=-360:360, green , very thick, smooth]{2*cos(x)};% and here
    \end{axis}
 \end{tikzpicture}

 \end{document}

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.