Question: Write a program to obtain the theoretical magnitude versus frequency characteristic of this Low Pass filter, shown in the Figure 1, over the range

Write a program to obtain the theoretical magnitude versus frequency characteristic of this Low Pass filter, shown in the Figure 1, over the range of frequencies from 100HZ to S0KHZ. The program should increment the frequency by 100HZ for frequencies between 100 and 5000HZ. From 5000 to 8OKHZ, the frequency should increment by IKHZ. Assume that the amplitude of the function generator is 1.4 volt. The test frequencies used are set by two nested loops: freqi = 100; 100; %3D step freq_end = 50003B for (i { %3! 1;i 1. Vi+ (2mfRC) PART B: Repeat the procedure of part A, but this time use: 1. two files: a) ifstream readfile; readfile.open("C:temp\freq1.dat"); b) ofstream writefile; writefile.open("C:\temp\cap.dat"); The input file is called C:\freql.dat and should contain all frequency values used in Part A. Name the output file C:\temp\CAP2.dat, this is the file where the frequency and voltage values will be saved. 2. use only one loop: for(i- 1;i
Step by Step Solution
3.38 Rating (151 Votes )
There are 3 Steps involved in it
if LOWPASS float RC 10CUTOFF2314 float dt 10SAMPLE RATE float alpha dtRCdt float filtere... View full answer
Get step-by-step solutions from verified subject matter experts
