Exercise 1.20: Script file

Open via the menu "File$ \setminus$ New$ \setminus$ M-file" the "MATLAB Editor/Debugger".
Save the lines below under the name `plate.m' and describe the meaning of the lines in this file.
x = 0:0.1:2
y = abs(x.*sin(2*pi*x))
figure
plot(x,y)
title('f(x) = |x*sin(2*pi*x)| on the interval [0,2]')
axis([0 2 0 2])
shg



Previous      Next      Up      Answer


Esteur 2010-03-22