Question

Please answer this question using Matlab: Write a matlab function to generate and plot a sine...

Please answer this question using Matlab:

Write a matlab function to generate and plot a sine wave at a specified frequency having at least 10 cycles, for this case the amplitude will represent voltage. Your sine wave should have a positive going zero crossing at T=0. Make sure your plot has at least 25 samples per cycle. Make sure the plot is with respect to time. Your function needs to return your generated samples and time vector. The frequency will be given in Hz.


0 0
Add a comment Improve this question Transcribed image text
Answer #1

I made a MATLAB code and it should work

el clearal F- 1 igureイ a be mp

Thumbs me up if ite helped

Add a comment
Know the answer?
Add Answer to:
Please answer this question using Matlab: Write a matlab function to generate and plot a sine...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Using Matlab. I need the matlab code for: a. Plot a 1 Hz sine wave b....

    Using Matlab. I need the matlab code for: a. Plot a 1 Hz sine wave b. Plot the unit rectangle function. c. Plot the unit triangle function Show each over a plotting interval -5 sec to 5 sec.

  • I'm not sure how to use plot to display the mag of the amplitude .Generate Bode...

    I'm not sure how to use plot to display the mag of the amplitude .Generate Bode Plot for following frequency response system using MATLAB Can you guess MATLAB function which generate Bode Plot? Repeat (No 8), but this time use this function to plot amplitude and phase response of system . Use help in MATLAB to find the syntax for function. Include screen shot of your code and results in report. H(s) = s

  • (A.) Use MATLAB to generate a pulsed sine wave signal having a frequency F-10KHZ and a...

    (A.) Use MATLAB to generate a pulsed sine wave signal having a frequency F-10KHZ and a pulse width of T-.5ms. The pulse repetition time is 1ms (pulse repetition rate is 1000 pulses/sec), i.e., the signal is zero between pulses. Model the signal to start at time t-0 and to end at a time t=Tstop. Use a sample time of .001ms to approximate an analog environment. Display the signal in MATLAB appropriate for an analog signal, first for Tstop 1ms and...

  • Sine wave measurement: Images 6.9 – 6.12 show a sine wave. Note that Image 6.9 is...

    Sine wave measurement: Images 6.9 – 6.12 show a sine wave. Note that Image 6.9 is a close up of the function generator’s frequency display. Using images 6.10 – 6.12, determine the amplitude of the sine wave. Be sure to include proper units: # of vertical divisions VOLT/DIV Amplitude Determine the period and calculate the frequency: # of horizontal divisions TIME/DIV Period Frequency Assuming that the frequency displayed in Image 6.9 is more accurate than the oscilloscope, what is the...

  • 1. Write an equation that describes voltage supplied by a wall outlet. (f = 60 Hz,...

    1. Write an equation that describes voltage supplied by a wall outlet. (f = 60 Hz, Vrms = 120 V) 2. What is the instantaneous voltage of a sine wave at half of a period? Describe Alternating Current (AC). Explain how resistors, capacitors, and inductors behave in an AC circuit. WRITEUP REQUIREMENTS Informal: Questions - 6 pts, Data Tables - 3 pts, Survey Questions from Syllabus - 1 pt INTRODUCTION V Up to this point, we have been using supply...

  • PROBLEM 2 150 pts.] A signal is consist of three sine functions: the first one, ,...

    PROBLEM 2 150 pts.] A signal is consist of three sine functions: the first one, , has a wave frequency of 50 Hz, the second one, 2, has 100 Hz, and the last one, r3, has 200 Hz. However, each function has different amplitude: the amplitude of the first signal component x! is 10 cm, the amplitude of the second signal component xi s 5 cm; and the amplitude of the last signal component t3 is 1 cm. As a...

  • I wrote a Matlab program for the figure below. When I plot the waves, they look...

    I wrote a Matlab program for the figure below. When I plot the waves, they look the same. Why do the two waves frequencies look same and How do I avoid it? (I really do need this part of the question answered.) N = 200; % Total number of time domain samples in simulation. Fs = 100 ;% sampling frequency. F1 = 10; % frequency of wave - 1. F2 = 90; % frequency of wave - 2. phi =...

  • The oscilloscope display below is connected to a sine wave of 100 Hz frequency and 4...

    The oscilloscope display below is connected to a sine wave of 100 Hz frequency and 4 volt amplitude, 100 us seconds/div, and 2 volts/div. What control(s) on the oscilloscope need to be adjusted to bring this signal into focus so that it displays a sine wave? The oscilloscope display below is connected to a sine wave of 150 Hz frequency , 2 ms seconds/div, and 1 volts/div. What control(s) on the oscilloscope need to be adjusted to bring this signal...

  • Program from problem 1: (Using MATLAB) % Sampling frequency and sampling period fs = 10000; ts...

    Program from problem 1: (Using MATLAB) % Sampling frequency and sampling period fs = 10000; ts = 1/fs; % Number of samples, assume 1000 samples l = 1000; t = 0:1:l-1; t = t.*ts; % Convert the sample index into time for generation and plotting of signal % Frequency and amplitude of the sensor f1 = 110; a1 = 1.0; % Frequency and amplitude of the power grid noise f2 = 60; a2 = 0.7; % Generating the sinusoidal waves...

  • Please include your matlab code and plot, as well as the derivation of the expressions for...

    Please include your matlab code and plot, as well as the derivation of the expressions for voltages across both the resistor and inductor themselves. Really need help understanding this! 5. Consider the RL Circuit shown below. Assume the excitation is a 10 kHz sine wave with amplitude of 1 volt. Derive expressions for the voltages across the resistor and the inductor as time functions. Plot the voltages across the resistor and the inductor over two periods using MATLAB and a...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT