MATLAB Write a script that graphs the required things for each exercise in order
ID: 3142563 • Letter: M
Question
MATLAB
Write a script that graphs the required things for each exercise in order. Use a PAUSE command to stop after each exercise. When a key is pressed (after the pause) have all graphs close and then graph the next exercise.
If you are asked questions, use the DISP command to have your answer printed to the console screen.
5.6 and 5.7
Make surface plots of the following functions over the given ranges: s6, Make surface plots of the following fu 2-3y/(x2+y2 + 1)(xl 2, lyl 4. 57. Make contour plots of the functions in the previous ex ercise.Explanation / Answer
Z= (x^2 + 3*y^2) * (e^ (-x^2 -y^2)) , x is [ -3, 3] & y is [ -3, 3]
Z= (X.^2 + 3*Y.^2) * (exp(-X.^2 -Y.^2))
figure
surface(X,Y,Z)
Z= (-3*y) / (x^2 + y^2 + 1) , x is [ -2, 2] & y is [ -4, 4]
Z= (-3*Y.) / (X.^2 + Y.^2 + 1)
figure
surface(X,Y,Z)
3)
Z= |x| + |y| , x is [ -1, 1] & y is [ -1, 1]
Z= abs(X.) + abs(Y.)
figure
surface(X,Y,Z)
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.