Mat Lab Program to Generate ‘FIR Filter-Low Pass’ Coefficients
#1

Code:
% FIR Low  pass filters using rectangular, triangular and kaiser windows
% sampling rate – 8000
order = 50;
cf=[500/4000,1000/4000,1500/4000];     cf--> contains set of cut-off  frequencies[Wc ]

% cutoff frequency – 500
b_rect1=fir1(order,cf(1),boxcar(51));    %Rectangular
b_tri1=fir1(order,cf(1),bartlett(51));    %Triangular
b_kai1=fir1(order,cf(1),kaiser(51,8));    %Kaisar [Where 8-->Beta Co-efficient]

% cutoff frequency - 1000
b_rect2=fir1(order,cf(2),boxcar(51));
b_tri2=fir1(order,cf(2),bartlett(51));
b_kai2=fir1(order,cf(2),kaiser(51,8));

% cutoff frequency - 1500
b_rect3=fir1(order,cf(3),boxcar(51));
b_tri3=fir1(order,cf(3),bartlett(51));
b_kai3=fir1(order,cf(3),kaiser(51,8));

fid=fopen('FIR_lowpass_rectangular.txt','wt');
fprintf(fid,'\t\t\t\t\t\t%s\n','Cutoff -400Hz');
fprintf(fid,'\nfloat b_rect1[31]={');
fprintf(fid,'%f,%f,%f,%f,%f,%f,%f,%f,%f,%f,\n',b_rect1);
fseek(fid,-1,0);
fprintf(fid,'};');
fprintf(fid,'\n\n\n\n');
fprintf(fid,'\t\t\t\t\t\t%s\n','Cutoff -800Hz');


fprintf(fid,'\nfloat b_rect2[31]={');
fprintf(fid,'%f,%f,%f,%f,%f,%f,%f,%f,%f,%f,\n',b_rect2);
fseek(fid,-1,0);
fprintf(fid,'};');
fprintf(fid,'\n\n\n\n');
fprintf(fid,'\t\t\t\t\t\t%s\n','Cutoff -1200Hz');
fprintf(fid,'\nfloat b_rect3[31]={');
fprintf(fid,'%f,%f,%f,%f,%f,%f,%f,%f,%f,%f,\n',b_rect3);
fseek(fid,-1,0);
fprintf(fid,'};');

fclose(fid);
winopen('FIR_highpass_rectangular.txt');
Reply

Important Note..!

If you are not satisfied with above reply ,..Please

ASK HERE

So that we will collect data for you and will made reply to the request....OR try below "QUICK REPLY" box to add a reply to this page
Popular Searches: the evaporation and condensation heat transfer coefficients in 3d induced finned, pass whatcd interview, filter coefficients matlab, ppt on algorithm used to generate captcha, generate 50 khz using 8051 microcontroller, track putting mat, download pdf for srs fir icecream parlour management system,

[-]
Quick Reply
Message
Type your reply to this message here.

Image Verification
Please enter the text contained within the image into the text box below it. This process is used to prevent automated spam bots.
Image Verification
(case insensitive)

Messages In This Thread
Mat Lab Program to Generate ‘FIR Filter-Low Pass’ Coefficients - by seminar class - 06-05-2011, 03:59 PM

Possibly Related Threads...
Thread Author Replies Views Last Post
  VHDL program for Booth’s Multiplier smart paper boy 2 5,668 20-04-2013, 11:59 AM
Last Post: T
  Program in “LEX” to count number of vowels and consonants seminar class 2 9,641 22-03-2013, 10:20 AM
Last Post: computer topic
  Program in “LEX” to count number of Identifiers and Keywords seminar class 1 4,858 28-01-2013, 03:21 PM
Last Post: Guest
  PROGRAM TO RECOGNIZE A STRING WITH THREE COSECUTIVE 0’s smart paper boy 0 1,671 10-08-2011, 11:44 AM
Last Post: smart paper boy
  : PROGRAM TO IDENTIFY VOWELS AND CONSONANTS GIVEN AS INPUT smart paper boy 0 2,411 10-08-2011, 11:44 AM
Last Post: smart paper boy
  Program to Encrypt and decrypt a text data using RSA algorithm smart paper boy 0 2,534 10-08-2011, 11:43 AM
Last Post: smart paper boy
  Program the CRC 12 on a data set of characters smart paper boy 0 1,774 10-08-2011, 11:42 AM
Last Post: smart paper boy
  Program to implement the data link layer framing method character stuffing smart paper boy 0 7,961 10-08-2011, 11:41 AM
Last Post: smart paper boy
  Program to implement the data link layer framing method bit stuffing smart paper boy 0 2,898 10-08-2011, 11:41 AM
Last Post: smart paper boy
  To write a program to print “Hello World” in CORBA. smart paper boy 0 1,989 21-07-2011, 09:52 AM
Last Post: smart paper boy

Forum Jump: