Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Part-II 4. Make a m-file and write MATLAB commands in it to accomplish the following: Evaluation of sin(x) for the following values of x: 0,

image text in transcribed
Part-II 4. Make a m-file and write MATLAB commands in it to accomplish the following: Evaluation of sin(x) for the following values of x: 0, 1/4, 1/2, 3/4, 7, 5x/4, 3/2, 7/4, 21, 91/4, 5x2, 112/4,6x/2, 13./4. 71/2, 152/4, 410 Evaluation of cos(x) for the same values of x as shown above 5. Plot a MATLAB figure that shows both sin(x) and cos(x) evaluated in part 1 as a function of x, within the same figure. In your figure, are you able to observe a phase-shift between the sine and cosine signals? Are the sine and cosine waves of your plot as smooth as they should be? Why or why not? Can you possibly improve the shapes further? If yes, how? Write the answers to these into the MS-Word document that you created for part I (In the Word document, clearly separate the contents for part I and part II) (Potentially useful info: One you have written your m-file and saved it, you need to ensure that the 'Current Directory in the MATLAB main window points to the folder/directory where you saved your m-file. Also, instead of using the play button in the m-file, you can also run a m-file by typing its name, without them extension, in the MATLAB command window) 6. Save the m-file contents and copy the contents into the MS-Word document that you created for part I. Also, save a screenshot of the figure into the MS-Word document. 7. Now, modify the m-file by adding commands to it to scale the amplitude of the cosine function factor of 2. Then, without overwriting the other existing cosine waves, generate new cosine waves with amplitude scaling factors 3 and 4. respectively. Make a single figure that contains the plots of all the four cosine wave versions (with amplitude scaling factors 1, 2, 3 and 4 respectively)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Structured Search For Big Data From Keywords To Key-objects

Authors: Mikhail Gilula

1st Edition

012804652X, 9780128046524

More Books

Students also viewed these Databases questions

Question

Provide a model of performance management

Answered: 1 week ago