This file concludes some codes related to some topics of DIGITAL SIGNAL PROCESSING as Butterworth filter, Chebyshev filter and many others.............
Salient Features:
The magnitude response is nearly constant(equal to 1) at lower frequencies
There are no ripples in passband and stop band
The maximum gain occurs at Ω=0 and it is H(Ω)=1
The magnitude response is monotonically decreasing
As the order of the filter ‘N’ increases, the response of the filter is more close to the ideal response
Salient Features:
The magnitude response is nearly constant(equal to 1) at lower frequencies
There are no ripples in passband and stop band
The maximum gain occurs at Ω=0 and it is H(Ω)=1
The magnitude response is monotonically decreasing
As the order of the filter ‘N’ increases, the response of the filter is more close to the ideal response
This presentation covers:
Some basic definitions & concepts of digital communication
What is Phase Shift Keying(PSK) ?
Binary Phase Shift Keying – BPSK
BPSK transmitter & receiver
Advantages & Disadvantages of BPSK
Pi/4 – QPSK
Pi/4 – QPSK transmitter & receiver
Advantages of Pi/4- QPSK
OFDM allows tightly packed carriers to convey information orthogonally and with high bandwidth efficiency
Objectives Description:
Concepts
Basic idea
Introduction to OFDM
Implementation
Advantages and Drawbacks.
FDMA
In digital modulation, minimum-shift keying(MSK) is a type of continuous-phase frequency-shift keying that was developed in the late 1950s and 1960s.
Similar to OQPSK(Offset quadrature phase-shift keying),
This presentation covers:
Some basic definitions & concepts of digital communication
What is Phase Shift Keying(PSK) ?
Binary Phase Shift Keying – BPSK
BPSK transmitter & receiver
Advantages & Disadvantages of BPSK
Pi/4 – QPSK
Pi/4 – QPSK transmitter & receiver
Advantages of Pi/4- QPSK
OFDM allows tightly packed carriers to convey information orthogonally and with high bandwidth efficiency
Objectives Description:
Concepts
Basic idea
Introduction to OFDM
Implementation
Advantages and Drawbacks.
FDMA
In digital modulation, minimum-shift keying(MSK) is a type of continuous-phase frequency-shift keying that was developed in the late 1950s and 1960s.
Similar to OQPSK(Offset quadrature phase-shift keying),
this is a presentation about some basic information about solar cells, types of solar cell, efficiency,advantages & disadvantages.
This pptx file must be helpful for all of you to get some knowledge about solar cell.
Water scarcity is the lack of fresh water resources to meet the standard water demand. There are two type of water scarcity. One is physical. The other is economic water scarcity.
Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdffxintegritypublishin
Advancements in technology unveil a myriad of electrical and electronic breakthroughs geared towards efficiently harnessing limited resources to meet human energy demands. The optimization of hybrid solar PV panels and pumped hydro energy supply systems plays a pivotal role in utilizing natural resources effectively. This initiative not only benefits humanity but also fosters environmental sustainability. The study investigated the design optimization of these hybrid systems, focusing on understanding solar radiation patterns, identifying geographical influences on solar radiation, formulating a mathematical model for system optimization, and determining the optimal configuration of PV panels and pumped hydro storage. Through a comparative analysis approach and eight weeks of data collection, the study addressed key research questions related to solar radiation patterns and optimal system design. The findings highlighted regions with heightened solar radiation levels, showcasing substantial potential for power generation and emphasizing the system's efficiency. Optimizing system design significantly boosted power generation, promoted renewable energy utilization, and enhanced energy storage capacity. The study underscored the benefits of optimizing hybrid solar PV panels and pumped hydro energy supply systems for sustainable energy usage. Optimizing the design of solar PV panels and pumped hydro energy supply systems as examined across diverse climatic conditions in a developing country, not only enhances power generation but also improves the integration of renewable energy sources and boosts energy storage capacities, particularly beneficial for less economically prosperous regions. Additionally, the study provides valuable insights for advancing energy research in economically viable areas. Recommendations included conducting site-specific assessments, utilizing advanced modeling tools, implementing regular maintenance protocols, and enhancing communication among system components.
Final project report on grocery store management system..pdfKamal Acharya
In today’s fast-changing business environment, it’s extremely important to be able to respond to client needs in the most effective and timely manner. If your customers wish to see your business online and have instant access to your products or services.
Online Grocery Store is an e-commerce website, which retails various grocery products. This project allows viewing various products available enables registered users to purchase desired products instantly using Paytm, UPI payment processor (Instant Pay) and also can place order by using Cash on Delivery (Pay Later) option. This project provides an easy access to Administrators and Managers to view orders placed using Pay Later and Instant Pay options.
In order to develop an e-commerce website, a number of Technologies must be studied and understood. These include multi-tiered architecture, server and client-side scripting techniques, implementation technologies, programming language (such as PHP, HTML, CSS, JavaScript) and MySQL relational databases. This is a project with the objective to develop a basic website where a consumer is provided with a shopping cart website and also to know about the technologies used to develop such a website.
This document will discuss each of the underlying technologies to create and implement an e- commerce website.
Quality defects in TMT Bars, Possible causes and Potential Solutions.PrashantGoswami42
Maintaining high-quality standards in the production of TMT bars is crucial for ensuring structural integrity in construction. Addressing common defects through careful monitoring, standardized processes, and advanced technology can significantly improve the quality of TMT bars. Continuous training and adherence to quality control measures will also play a pivotal role in minimizing these defects.
Welcome to WIPAC Monthly the magazine brought to you by the LinkedIn Group Water Industry Process Automation & Control.
In this month's edition, along with this month's industry news to celebrate the 13 years since the group was created we have articles including
A case study of the used of Advanced Process Control at the Wastewater Treatment works at Lleida in Spain
A look back on an article on smart wastewater networks in order to see how the industry has measured up in the interim around the adoption of Digital Transformation in the Water Industry.
COLLEGE BUS MANAGEMENT SYSTEM PROJECT REPORT.pdfKamal Acharya
The College Bus Management system is completely developed by Visual Basic .NET Version. The application is connect with most secured database language MS SQL Server. The application is develop by using best combination of front-end and back-end languages. The application is totally design like flat user interface. This flat user interface is more attractive user interface in 2017. The application is gives more important to the system functionality. The application is to manage the student’s details, driver’s details, bus details, bus route details, bus fees details and more. The application has only one unit for admin. The admin can manage the entire application. The admin can login into the application by using username and password of the admin. The application is develop for big and small colleges. It is more user friendly for non-computer person. Even they can easily learn how to manage the application within hours. The application is more secure by the admin. The system will give an effective output for the VB.Net and SQL Server given as input to the system. The compiled java program given as input to the system, after scanning the program will generate different reports. The application generates the report for users. The admin can view and download the report of the data. The application deliver the excel format reports. Because, excel formatted reports is very easy to understand the income and expense of the college bus. This application is mainly develop for windows operating system users. In 2017, 73% of people enterprises are using windows operating system. So the application will easily install for all the windows operating system users. The application-developed size is very low. The application consumes very low space in disk. Therefore, the user can allocate very minimum local disk space for this application.
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)MdTanvirMahtab2
This presentation is about the working procedure of Shahjalal Fertilizer Company Limited (SFCL). A Govt. owned Company of Bangladesh Chemical Industries Corporation under Ministry of Industries.
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...Amil Baba Dawood bangali
Contact with Dawood Bhai Just call on +92322-6382012 and we'll help you. We'll solve all your problems within 12 to 24 hours and with 101% guarantee and with astrology systematic. If you want to take any personal or professional advice then also you can call us on +92322-6382012 , ONLINE LOVE PROBLEM & Other all types of Daily Life Problem's.Then CALL or WHATSAPP us on +92322-6382012 and Get all these problems solutions here by Amil Baba DAWOOD BANGALI
#vashikaranspecialist #astrologer #palmistry #amliyaat #taweez #manpasandshadi #horoscope #spiritual #lovelife #lovespell #marriagespell#aamilbabainpakistan #amilbabainkarachi #powerfullblackmagicspell #kalajadumantarspecialist #realamilbaba #AmilbabainPakistan #astrologerincanada #astrologerindubai #lovespellsmaster #kalajaduspecialist #lovespellsthatwork #aamilbabainlahore#blackmagicformarriage #aamilbaba #kalajadu #kalailam #taweez #wazifaexpert #jadumantar #vashikaranspecialist #astrologer #palmistry #amliyaat #taweez #manpasandshadi #horoscope #spiritual #lovelife #lovespell #marriagespell#aamilbabainpakistan #amilbabainkarachi #powerfullblackmagicspell #kalajadumantarspecialist #realamilbaba #AmilbabainPakistan #astrologerincanada #astrologerindubai #lovespellsmaster #kalajaduspecialist #lovespellsthatwork #aamilbabainlahore #blackmagicforlove #blackmagicformarriage #aamilbaba #kalajadu #kalailam #taweez #wazifaexpert #jadumantar #vashikaranspecialist #astrologer #palmistry #amliyaat #taweez #manpasandshadi #horoscope #spiritual #lovelife #lovespell #marriagespell#aamilbabainpakistan #amilbabainkarachi #powerfullblackmagicspell #kalajadumantarspecialist #realamilbaba #AmilbabainPakistan #astrologerincanada #astrologerindubai #lovespellsmaster #kalajaduspecialist #lovespellsthatwork #aamilbabainlahore #Amilbabainuk #amilbabainspain #amilbabaindubai #Amilbabainnorway #amilbabainkrachi #amilbabainlahore #amilbabaingujranwalan #amilbabainislamabad
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...Dr.Costas Sachpazis
Terzaghi's soil bearing capacity theory, developed by Karl Terzaghi, is a fundamental principle in geotechnical engineering used to determine the bearing capacity of shallow foundations. This theory provides a method to calculate the ultimate bearing capacity of soil, which is the maximum load per unit area that the soil can support without undergoing shear failure. The Calculation HTML Code included.
Cosmetic shop management system project report.pdfKamal Acharya
Buying new cosmetic products is difficult. It can even be scary for those who have sensitive skin and are prone to skin trouble. The information needed to alleviate this problem is on the back of each product, but it's thought to interpret those ingredient lists unless you have a background in chemistry.
Instead of buying and hoping for the best, we can use data science to help us predict which products may be good fits for us. It includes various function programs to do the above mentioned tasks.
Data file handling has been effectively used in the program.
The automated cosmetic shop management system should deal with the automation of general workflow and administration process of the shop. The main processes of the system focus on customer's request where the system is able to search the most appropriate products and deliver it to the customers. It should help the employees to quickly identify the list of cosmetic product that have reached the minimum quantity and also keep a track of expired date for each cosmetic product. It should help the employees to find the rack number in which the product is placed.It is also Faster and more efficient way.
Event Management System Vb Net Project Report.pdfKamal Acharya
In present era, the scopes of information technology growing with a very fast .We do not see any are untouched from this industry. The scope of information technology has become wider includes: Business and industry. Household Business, Communication, Education, Entertainment, Science, Medicine, Engineering, Distance Learning, Weather Forecasting. Carrier Searching and so on.
My project named “Event Management System” is software that store and maintained all events coordinated in college. It also helpful to print related reports. My project will help to record the events coordinated by faculties with their Name, Event subject, date & details in an efficient & effective ways.
In my system we have to make a system by which a user can record all events coordinated by a particular faculty. In our proposed system some more featured are added which differs it from the existing system such as security.
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptxR&R Consult
CFD analysis is incredibly effective at solving mysteries and improving the performance of complex systems!
Here's a great example: At a large natural gas-fired power plant, where they use waste heat to generate steam and energy, they were puzzled that their boiler wasn't producing as much steam as expected.
R&R and Tetra Engineering Group Inc. were asked to solve the issue with reduced steam production.
An inspection had shown that a significant amount of hot flue gas was bypassing the boiler tubes, where the heat was supposed to be transferred.
R&R Consult conducted a CFD analysis, which revealed that 6.3% of the flue gas was bypassing the boiler tubes without transferring heat. The analysis also showed that the flue gas was instead being directed along the sides of the boiler and between the modules that were supposed to capture the heat. This was the cause of the reduced performance.
Based on our results, Tetra Engineering installed covering plates to reduce the bypass flow. This improved the boiler's performance and increased electricity production.
It is always satisfying when we can help solve complex challenges like this. Do your systems also need a check-up or optimization? Give us a call!
Work done in cooperation with James Malloy and David Moelling from Tetra Engineering.
More examples of our work https://www.r-r-consult.dk/en/cases-en/
Saudi Arabia stands as a titan in the global energy landscape, renowned for its abundant oil and gas resources. It's the largest exporter of petroleum and holds some of the world's most significant reserves. Let's delve into the top 10 oil and gas projects shaping Saudi Arabia's energy future in 2024.
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
DIGITAL SIGNAL PROCESSING BASED ON MATLAB
1. ROORKEE COLLEGE OF
ENGINEERING, ROORKEE
UNDER THE GUIDANCE OF:
Miss. RUCHITA SINGH
(Asst. Professor, EEE Dept.)
ROORKEE COLLEGE OF
ENGINEERING, ROOORKEE
BY – PRASHANT SRIVASTAV
ROLL NO. - 661020108001
B.Tech.- EEE (Vth
sem.)
2. INDEX
SR.NO. NAME OF PROGRAM DATE TEACHERS’REMARK
1 WAVE FORM
GENERATION
2 LINEAR CONVOLUTION
3 DESIGN OF
BUTTERWORTH FILTER:
(I) ANALOG LOW PASS FILTER
(II) DIGITAL BANDPASS
FILTER
4 AUTOCORRELATION
5 DESIGN OF CHEBYSHEV
DIGITAL FILTER
(I) TYPE – I BANDPASS
(II) TYPE – II BANDPASS
(III) TYPE –II BANDSTOP
6 FFT & IFFT WITHOUT
USING FUNCTION
7 DESIGN OF FIR FILTER BY
USING HANNING
WINDOW
8 DESIGN OF FIR FILTER BY
USING CHEBYSHEV
WINDOW
3. 1.WAVE FORM GENERATION
COSINE WAVE
t=0:.01:pi;
y=cos(2*pi*t);
subplot(2,1,1);plot (t,y);ylabel('amplitude -->');
xlabel('(b) n -->');
GENERATION OF EXPONENTIAL SIGNAL
1. n=input('enter the length of the exponential sequence');
2. t=0:n;
3. a=input('enter the a value');
4. y2=exp(a*t);
5. subplot(2,2,4);
6. stem(t,y2);
7. ylabel('Amplitude -->');
8. xlabel('(d) n -->');
Enter the length of the exponential sequence'
Enter the a value'
4. GENERATION OF UNIT IMPULSE
1. t=-2:1:2;
2. y=[zeros(1,2),ones(1,1),zeros(1,2)];
3. subplot(2,2,1);
4. stem(t,y);
5. ylabel('amplitude_ _>');
6. xlabel('(a)n_ _>');
GENERATION OF UNIT STEP SEQUENCE
1. n=input('enter the N value');
2. t=0:1:n-1;
3. y1=ones(1,n);
4. subplot(2,2,2);
5. stem(t,y1);
6. ylabel('amplitude_ _>');
7. xlabel('(b)n_ _>');
enter the “n” values.
5. GENERATION OF RAMP SEQUENCE
1. n=input('enter the length of the ramp sequence');
2. t=0:n;
3. subplot(2,2,3);
4. stem(t,t);
5. ylabel('amplitude -->');
6. xlabel('(c) n -->');
„Enter the length of the ramp sequence'
SINE WAVE
t=0:.01:pi;
y=sin(2*pi*t);figure(2);
subplot(2,1,1);plot (t,y);ylabel('amplitude -->');
xlabel('(a) n -->');
6. 2.LINEAR CONVOLUTION
clc;
clear all;
close all;
x=input('enter the 1st sequence');
h=input('enter the 2nd sequence');
y=conv(x,h);
figure;subplot(3,1,1);
stem(x);
ylabel('amplitude -->');
xlabel('(a) n -->');
subplot(3,1,2);
stem(h);ylabel('amplitude -->');
xlabel('(b) n -->');
subplot(3,1,3);
stem(y);ylabel('amplitude -->');
xlabel('(c) n -->');
disp('the resultant signal is ');y
example,
1st
sequence – [1, 2]
2nd
sequence – [1, 2, 4]
7. 3.DESIGN OF BUTTERWORTH FILTER
ANALOG LOW PASS FILTER
1. clc;
2. close all;
3. clear all;
4. format long
5. rp=input('enter the passband ripple');
6. rs=input('enter the stopband ripple');
7. wp=input('enter the passband freq');
8. ws=input('enter the stopband freq');
9. fs=input('enter the sampling freq');
10.w1=2*wp/fs;w2=2*ws/fs;
11.[n,wn]=buttord(w1,w2,rp,rs,'s');
12.[z,p,k]=butter(n,wn);
13.[b,a]=zp2tf(z,p,k);
14.[b,a]=butter(n,wn,'s');
15.w=0:.01:pi;
16.[h,om]=freqs(b,a,w);
17.m=20*log10(abs(h));
18.an=angle(h);
19.subplot(2,1,1);
20.plot(om/pi,m);
21.ylabel('Gain in dB --.');
22.xlabel('(a) Normalised frequency --.');
23.subplot(2,1,2);
24.plot(om/pi,an);
25.xlabel('(b) Normalised frequency --.');
26.ylabel('Phase in radians --.');
Example:
enter the passband ripple 0.15
enter the stopband ripple 60
enter the passband freq 1500
enter the stopband freq 3000
enter the stopband freq 7000
8. DIGITAL BANDPASS FILTER
clc;
clear all;
rp = input('Enter the passband ripple = ');
rs = input('Enter the stopband ripple = ');
wp = input('Enter the passband frequency = ');
ws = input('Enter the stopband frequency = ');
fs = input('Enter the sampling frequency = ');
w1 = 2*wp/fs;
w2 = 2*ws/fs;
[n] = buttord(w1,w2,rp,rs);
wn = [w1 w2];
[b,a] = butter(n,wn,'bandpass');
w = 0:0.01:pi;
[h,om] = freqz(b,a,w);
m = 20*log10(abs(h));
an = angle(h);
subplot(2,1,1);
plot(om/pi,m);
subplot(2,1,1);
plot(om/pi,m);
title('Magnitude Response');
ylabel('Gain in dB ---->');
xlabel('Normalised Frequency ---->');
grid on;
subplot(2,1,2);
plot(om/pi,an);
title('Phase Response');
xlabel('Normalised Frequency ---->');
ylabel('Phase in radians ---->');
grid on;
Enter the passband ripple = 0.2
Enter the stopband ripple = 40
Enter the passband frequency = 1500
Enter the stopband frequency = 2000
Enter the sampling frequency = 9000
9. 4.AUTO-CORRELATION
Algorithm:
1. Get the signal x(n)of length N in matrix form
2. The correlated signal is denoted as y(n)
3. y(n)is given by the formula
y(n) 5 [ ( ) ( )] x k x k n k − =−∞ ∞ ∑ where n52(N 2 1) to (N 2 1)
10. 5.DESIGN OF CHEBYSHEV
DIGITAL FILTER
TYPE-I BAND PASS FILTER
clc;
clear all;
rp = input('Enter the passband ripple = ');
rs = input('Enter the stopband ripple = ');
wp = input('Enter the passband frequency = ');
ws = input('Enter the stopband frequency = ');
fs = input('Enter the sampling frequency = ');
w1 = 2*wp/fs;
w2 = 2*ws/fs;
[n] = cheb1ord(w1,w2,rp,rs,'s');
wn = [w1 w2];
[b,a] = cheby1(n,rp,wn,'bandpass','s');
w = 0:0.01:pi;
[h,om] = freqs(b,a,w);
m = 20*log10(abs(h));
an = angle(h);
subplot(2,1,1);
plot(om/pi,m);
subplot(2,1,1);
plot(om/pi,m);
title('Magnitude Response');
ylabel('Gain in dB ---->');
xlabel('Normalised Frequency ---->');
grid on;
subplot(2,1,2);
plot(om/pi,an);
title('Phase Response');
xlabel('Normalised Frequency ---->');
ylabel('Phase in radians ---->');
grid on;
Enter the passband ripple = 0.3
Enter the stopband ripple = 40
Enter the passband frequency = 1400
Enter the stopband frequency = 2000
Enter the sampling frequency = 5000
11. CHEBYSHEV TYPE-2 BANDSTOP FILTER
clc;
clear all;
rp = input('Enter the passband ripple = ');
rs = input('Enter the stopband ripple = ');
wp = input('Enter the passband frequency = ');
ws = input('Enter the stopband frequency = ');
fs = input('Enter the sampling frequency = ');
w1 = 2*wp/fs;
w2 = 2*ws/fs;
[n] = cheb2ord(w1,w2,rp,rs);
wn = [w1 w2];
[b,a] = cheby2(n,rs,wn,'stop');
w = 0:0.1/pi:pi;
[h,om] = freqz(b,a,w);
m = 20*log10(abs(h));
an = angle(h);
subplot(2,1,1);
plot(om/pi,m);
subplot(2,1,1);
plot(om/pi,m);
title('Magnitude Response');
ylabel('Gain in dB ---->');
xlabel('Normalised Frequency ---->');
grid on;
subplot(2,1,2);
plot(om/pi,an);
title('Phase Response');
xlabel('Normalised Frequency ---->');
ylabel('Phase in radians ---->');
grid on;
Enter the passband ripple = 0.3
Enter the stopband ripple = 46
Enter the passband frequency = 1400
Enter the stopband frequency = 2000
Enter the sampling frequency = 8000
12. CHEBYSHEV TYPE-I BANDSTOP FILTER
clc;
clear all;
rp = input('Enter the passband ripple = ');
rs = input('Enter the stopband ripple = ');
wp = input('Enter the passband frequency = ');
ws = input('Enter the stopband frequency = ');
fs = input('Enter the sampling frequency = ');
w1 = 2*wp/fs;
w2 = 2*ws/fs;
[n] = cheb1ord(w1,w2,rp,rs);
wn = [w1 w2];
[b,a] = cheby1(n,rp,wn,'stop');
w = 0:0.1/pi:pi;
[h,om] = freqz(b,a,w);
m = 20*log10(abs(h));
an = angle(h);
subplot(2,1,1);
plot(om/pi,m);
subplot(2,1,1);
plot(om/pi,m);
title('Magnitude Response');
ylabel('Gain in dB ---->');
xlabel('Normalised Frequency ---->');
grid on;
subplot(2,1,2);
plot(om/pi,an);
title('Phase Response');
xlabel('Normalised Frequency ---->');
ylabel('Phase in radians ---->');
grid on;
Enter the passband ripple = 0.25
Enter the stopband ripple = 40
Enter the passband frequency = 2500
Enter the stopband frequency = 2750
Enter the sampling frequency = 7000
>>
13. 6.FFT & IFFT WITHOUT USING
FUNCTION
clc;
clear all;
x = input('Enter the input sequence = ');
N = length(x);
for k = 1:N
y(k) = 0;
for n = 1:N
y(k) = y(k)+x(n)*exp(-1i*2*pi*(k-1)*(n-1)/N);
end
end
%code block to plot the input sequence
t = 0:N-1;
subplot(2,2,1);
stem(t,x);
ylabel('Amplitude ---->');
xlabel('n ---->');
title('Input Sequence');
grid on;
magnitude = abs(y); % Find the magnitudes of individual FFT points
disp('FFT Sequence = ');
disp(magnitude);
%code block to plot the FFT sequence
t = 0:N-1;
subplot(2,2,2);
stem(t,magnitude);
ylabel('Amplitude ---->');
xlabel('K ---->');
title('FFT Sequence');
grid on;
R = length(y);
for n = 1:R
x1(n) = 0;
for k = 1:R
x1(n) = x1(n)+(1/R)*y(k)*exp(1i*2*pi*(k-1)*(n-1)/R);
end
end
%code block to plot the IFFT sequence
15. 7.FIR USING HANNING WINDOW
clc;
clear all;
rp = input('Enter the passband ripple = ');
rs = input('Enter the stopband ripple = ');
fp = input('Enter the passband frequency = ');
fs = input('Enter the stopband frequency = ');
f = input('Enter the sampling frequency = ');
wp = 2*fp/f;
ws = 2*fs/f;
num = -20*log10(sqrt(rp*rs))-13;
dem = 14.6*(fs-fp)/f;
n = ceil(num/dem);
n1 = n+1;
if (rem(n,2)~=0)
n1 = n;
n = n-1;
end
y = hanning(n1);
% low-pass filter
b = fir1(n,wp,y);
[h,o] = freqz(b,1,256);
m = 20*log10(abs(h));
subplot(2,2,1);
plot(o/pi,m);
title('Magnitude Response of LPF');
ylabel('Gain in dB ---->');
xlabel('Normalised Frequency ---->');
grid on;
% high-pass filter
b = fir1(n,wp,'high',y);
[h,o] = freqz(b,1,256);
m = 20*log10(abs(h));
subplot(2,2,2);
plot(o/pi,m);
title('Magnitude Response of HPF');
ylabel('Gain in dB ---->');
xlabel('Normalised Frequency ---->');
grid on;
% band pass filter
wn = [wp ws];
16. b = fir1(n,wn,y);
[h,o] = freqz(b,1,256);
m = 20*log10(abs(h));
subplot(2,2,3);
plot(o/pi,m);
title('Magnitude Response of BPF');
ylabel('Gain in dB ---->');
xlabel('Normalised Frequency ---->');
grid on;
% band stop filter
b = fir1(n,wn,'stop',y);
[h,o] = freqz(b,1,256);
m = 20*log10(abs(h));
subplot(2,2,4);
plot(o/pi,m);
title('Magnitude Response of BSF');
ylabel('Gain in dB ---->');
xlabel('Normalised Frequency ---->');
grid on;
OUTPUT:
Enter the passband ripple = 0.03
Enter the stopband ripple = 0.01
Enter the passband frequency = 1400
Enter the stopband frequency = 2000
Enter the sampling frequency = 8000
17. 8. FIR FILTER USING
CHEBYSHEV WINDOW
clc;
clear all;
rp = input('Enter the passband ripple = ');
rs = input('Enter the stopband ripple = ');
fp = input('Enter the passband frequency = ');
fs = input('Enter the stopband frequency = ');
f = input('Enter the sampling frequency = ');
r = input('Enter the ripple value(in dBs) = ');
wp = 2*fp/f;
ws = 2*fs/f;
num = -20*log10(sqrt(rp*rs))-13;
dem = 14.6*(fs-fp)/f;
n = ceil(num/dem);
if(rem(n,2)==0)
n = n+1;
end
y = chebwin(n,r);
% low-pass filter
b = fir1(n-1,wp,y);
[h,o] = freqz(b,1,256);
m = 20*log10(abs(h));
subplot(2,2,1);
plot(o/pi,m);
title('Magnitude Response of LPF');
ylabel('Gain in dB ---->');
xlabel('Normalised Frequency ---->');
grid on;
% high-pass filter
b = fir1(n-1,wp,'high',y);
[h,o] = freqz(b,1,256);
m = 20*log10(abs(h));
subplot(2,2,2);
plot(o/pi,m);
title('Magnitude Response of HPF');
ylabel('Gain in dB ---->');
xlabel('Normalised Frequency ---->');
grid on;
% band pass filter
wn = [wp ws];
18. b = fir1(n-1,wn,y);
[h,o] = freqz(b,1,256);
m = 20*log10(abs(h));
subplot(2,2,3);
plot(o/pi,m);
title('Magnitude Response of BPF');
ylabel('Gain in dB ---->');
xlabel('Normalised Frequency ---->');
grid on;
% band stop filter
b = fir1(n-1,wn,'stop',y);
[h,o] = freqz(b,1,256);
m = 20*log10(abs(h));
subplot(2,2,4);
plot(o/pi,m);
title('Magnitude Response of BSF');
ylabel('Gain in dB ---->');
xlabel('Normalised Frequency ---->');
grid on;
OUTPUT:
Enter the passband ripple = 0.03
Enter the stopband ripple = 0.02
Enter the passband frequency = 1800
Enter the stopband frequency = 2400
Enter the sampling frequency = 10000
Enter the ripple value(in dBs) = 40