Matlab. How to get the sine wave frequency and the sampling frequency of a sine wave.

Discussion in 'Homework Help' started by electrogirl, Aug 14, 2010.

  1. electrogirl

    Thread Starter Member

    May 2, 2010
    47
    0
    Define the variables given below and plot the graph using the stem command.
    T = 0:0.2:20;
    A = 5sin(T);

    get the amplitude, sine wave frequency and the sampling frequency of the graph.

    this is how I wrote the code in Matlab:
    T = 0:0.2:20;
    A = 5*sin(T);
    stem(T,A)
    so, this is our first experiment in our laboratory class in signal processing our lab is ahead compared to our lecture class thats why I still don't know how to deal with this stuffs.
    I know that the amplitude is 5. How to get the sine wave frequency and the sampling frequency?

    (see attachment for the graph)
     
    Last edited: Aug 15, 2010
  2. electrogirl

    Thread Starter Member

    May 2, 2010
    47
    0
    help me please
     
  3. mik3

    Senior Member

    Feb 4, 2008
    4,846
    63
    The sinewave frequency is the inverse of the time of a full cycle.

    The sampling frequency is the inverse of the time between two samples.
     
  4. Georacer

    Moderator

    Nov 25, 2009
    5,142
    1,266
    Was the above reply satisfactory or you want to calculate these quantities automaticaly through Matlab?
     
Loading...