Question
MATLAB Help!!! ECE 2001 Homework The Fourier series for a sawtooth wave with amplitude A and period T0 is where N=? and 1. Write a
MATLAB Help!!!
ECE 2001 Homework
The Fourier series for a sawtooth wave with amplitude A and period T0 is
where N=? and
1. Write a MATLAB script to compute and plot this function. Instead of infinity, use a finite value of N which is input by the user. The plot time axis should contain two periods. You may make A and T0 constants in the script, rather than having the user input those values.
2. Your script probably uses one loop. Write a new version which does not use any loops. Hint: observe that the sum of bn times the sine (which is a function of n and t) can be rewritten as a vector times a matrix where one dimension of the matrix corresponds to n and the other to t. Procedure: (a) create vectors n and t, (b) create vector bn , (c) via appropriate vector multiplication of n and t create matrix where one dimension corresponds to n and the other to t and use that to compute sine, (d) perform matrix multiplication.
Label the plot axes and title the plots. Test each version using N=5 and N=50.
(0) - 2 Masin Alat 11=1Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started