Matlab Activity
Matlab Activity
Matlab Activity
Using matlab or octave. Do the following exercises. Provide screenshots of your codes and
resulting figures. Submit your assignment in class.
Objectives:
1. Plot signals in time and frequency domains.
2. Analyze signals using fast Fourier transform (fft).
Procedure:
1. Load the audio file mixSinusoid.wav which is composed of three pure-tone signals with some
noise. (note: the wav file must be in same folder directory for matlab to locate the file)
Fs = sampling frequency
clc; clear;
%========Loading audio file
[x,Fs]=wavread('mixSinusoid.wav'); %Loading the wav file
Question
1: For what is variable ‘x’? What is the sampling frequency Fs?
Hint: in the command window just type ‘x’
Question 3: What is fft? What are the three tones in the audio file?
Hint: Use ‘data cursor button’ in the matlab
figure windown to know the data points.