(New page: <pre> clc; close all; clear all; [y,Fs,bits] = auread('bird_chirping2.au'); x = y(:,1); clear y; N = length(x); time = [1:N].*(1/Fs); han = plot(time,x); xlab = xlabel('Seconds'); yla...)
 
Line 1: Line 1:
 +
==Copyright Dhruv Lamba==
 
<pre>
 
<pre>
 
clc;
 
clc;

Revision as of 20:51, 13 October 2009

Copyright Dhruv Lamba

clc;
close all;
clear all;

[y,Fs,bits] = auread('bird_chirping2.au');

x = y(:,1);

clear y;
N = length(x);

time = [1:N].*(1/Fs);

han = plot(time,x);
xlab = xlabel('Seconds');
ylab = ylabel('Amplitude');
grid on;
set(han,'LineWidth', 2);
set([xlab, ylab],'FontSize', 24, 'FontName', 'Times');
set(gca,'FontSize',20,'FontName','Times','Fontweight','Bold')

wavwrite(x,Fs,bits,'test.wav');


[X,f] = centeredFFT(x,Fs);


figure;
han1 = plot(f,abs(X));
axis([-8000,8000,0,max(abs(X))]);
grid on;
xlab1=xlabel('Frequency(Hz)');
ylab1=ylabel('|X[k]|');
set(han1,'LineWidth', 2);
set([xlab1, ylab1],'FontSize', 24, 'FontName', 'Times');
set(gca,'FontSize',20,'FontName','Times','Fontweight','Bold')

sound(x,Fs,bits);

Alumni Liaison

Ph.D. 2007, working on developing cool imaging technologies for digital cameras, camera phones, and video surveillance cameras.

Buyue Zhang