% ************************ STANDING WAVE *************************** % ************************ By Mahesha MG *************************** figure('color','white') x=0:0.01:10; for t=0:0.1:5 y1=sin(2*x-1*t); y2=sin(2*x+1*t); y=y1+y2; plot(x,y,'b'); hold all; ylim([-2 2]); title('Standing Wave') xlabel('By: Mahesha MG maheshamg@gmail.com'); getframe; end
hi,thank you for this info,really appreciate..but why i get this error when i launched it.
ReplyDelete??? MATLAB - Standing Wave
|
Error: Unexpected MATLAB expression.
please help :)
It is working properly in my system. copy the following to your .m file
Delete% ************************ STANDING WAVE ***************************
% ************************ By Mahesha MG ***************************
figure('color','white')
x=0:0.01:10;
for t=0:0.1:5
y1=sin(2*x-1*t);
y2=sin(2*x+1*t);
y=y1+y2;
plot(x,y,'b');
hold all;
ylim([-2 2]);
title('Standing Wave')
xlabel('By: Mahesha MG maheshamg@gmail.com');
getframe;
end
i got it..sir please check your e-mail :)
Delete