Question: Python please! Assignment 2: Amplitude Operations on Signals Again, following the guidelines in the Lab 1 template, start a new cell and write a script

Python please! Assignment 2: Amplitude Operations on Signals Again, following the guidelinesPython please!

Assignment 2: Amplitude Operations on Signals Again, following the guidelines in the Lab 1 template, start a new cell and write a script to meet the following specifications. This assignment will have four parts, A-C, each of which should be indicated with comments. A. Create a discrete time signal sl that is the same length as xl and has value 1 for t=[0,0.5] and value 0.2 for t>0.5. You can use the command below where lenl is the length of xl and n0 is the index corresponding to t=0.5 sl = np.concatenate((np.ones(n0),0.2*np.ones(len(xl)-n0)) Multiply xl with sl to create v1. Save this signal to a wav file. B. Create a discrete-time decaying ramp signal r1, that is the same length as xl. The signal should have value 1 at time 0 and linearly decay to value 0. (Hint: use numpy.arange.) Multiply xl with rl to create v2. Save this signal to a wav file. C. Read in vl and v2 using simpleaudio and play the two different modifications together with the original, to verify that the volume of the second whistle is reduced

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!