Write MATLAB code to plot the following waveforms.
For ? and ?, choose any values that make sense.
For ? and ?, choose any values that make sense.
1)
clc;close all;clear all;
%rect(t)
x=@(t) (t>=-0.5 & t<=0.5);
T=1;tow=2;
t=-2:0.001:2;
figure;
subplot(221);plot(t,x(t));xlabel('t');ylabel('rect(t)');title('rect(t)');grid;
subplot(222);plot(t,x(t-T));xlabel('t');ylabel('rect(t-1)');title('rect(t-1)');grid;
subplot(223);plot(t,x(t/tow));xlabel('t');ylabel('rect(t/tow)');title('rect(t/2)');grid;
2)
clc;close all;clear all;
%triangular pulses
x=@(t) (1-(abs(t))).* (t>=-1 & t<=1);
T=1;tow=2;
t=-2:0.001:2;
figure;
subplot(221);plot(t,x(t));xlabel('t');ylabel('tri(t)');title('tri(t)');grid;
subplot(222);plot(t,x(t-T));xlabel('t');ylabel('tri(t-1)');title('tri(t-1)');grid;
subplot(223);plot(t,x(t/tow));xlabel('t');ylabel('tri(t/tow)');title('tri(t/2)');grid;
Write MATLAB code to plot the following waveforms. Rectangular pulses: ????(?) ????(? − ?) ????(?/?) ...
Write MATLAB code to plot the following waveforms. Impulse approximation: δ(?) δ(? − ?) For ?, choose any value that makes sense. Unit steps: ?(?) ?(? − ?) ? ⋅ ?(? − ?) For ? and ?, choose any values that make sense
Hello
Only need the answer of question 5 and 6 also with the
graph.
Write MATLAB code to plot the following waveforms. Submit your code and plots in a single PDF file. 1. (8 pts) Rectangular pulses: a. rect(t) b. rect(t-T) c. rect(t/t) For T and T, choose any values that make sense. 2. (12 pts) Triangular pulses: a. A(C) b. At-T) C. Aſt/t) For T and T, choose any values that make sense. 3. (8 pts) Impulse approximation: a....
Use Matlab to plot two cycles of the following ) waveforms: a. yi(t) = sin(200m) volts b· pd) =-1.0+ cos(2000m) volts c. y)--1.0 to 3.0 volt square wave at 1,000 Hz Then use Matlab to compute the max, min, average, and rms values for each of the signals listed above.
Problem 4 For Poisson's ratio of 0.3, write a MATLAB code to plot the principal stress and maximus shear for two spherical bodies in contact
Problem 4 For Poisson's ratio of 0.3, write a MATLAB code to plot the principal stress and maximus shear for two spherical bodies in contact
MATLAB question I need the code
exactly as you would write it in MATLAB. thank you
1. Consider a Gaussian solution of the traveling-wave form ψ(z,t)-exp(-a(z-vt)2). The parameter values are a 1, 2. (a) Explain the physical meaning of these parameters (eg. what would happen if we took a = 10 instead?) Determine the direction of propagation of this solution: Is it traweling to the left or to the right? (2pts) (b) Write a Matlab code to plot the Gaussian...
write a code please
Problem 1 Write MATLAB programs to find the following sums with for loops. (a) 12 + 22 + 32 + ... ... ... + 10002. (b) 1 –}+*+*+.........-1003 Problem 2 Make two separate plots of the function f(x) = 0.6x5 – 5x3 + 9x + 2; one plot for -4 < x < 4, and -2.7 < x < 2.7. Plot by creating vectors.
Please I need help with MATLAB .. PLease help me . Thankyou Write Matlab code to plot a 2D sinc function over a 2D cartesian grid where x ranges from 100 to 355 and y ranges from 0 to 255 and the sinc is centered at somewhere not midway in the grid. First plot the grid, and then plot the function on the grid (both as grayscale and as a surface plot). Comment the code well, generate the figures and...
Write a Matlab code that is able to plot the frequency response
for the given circuit.
Tvoo Ro Vinot - Vout . Vout 9m Vin Ro = CL Vin EMEL hu (b)
Matlab code using heaviside
1. Create an m-file that will generate a rectangular pulse mathematically defined as The user of the m-file can select the parameter # which must be positive and the rectangular pulse must equal 1 all the way to include the end points # and Provide the code of the m- file and provide the code showing that you tested this m-file by generating a CT pulse of width running from -5 to 5 and a DT...
I need matlab code of the following problem. 1. Plot the values of electric field around a positive charge in free space in two dimensions..... I need the code asap. please.