Matlab学习笔记[4](Two-Dimensional Plots)
4.1 THE plot COMMAND
?
x=[10:0.1:22];y=95000./x.^2;xd=[10:2:22];yd=[950 640 460 340 250 180 140];plot(x,y,'-','LineWidth',1.0)xlabel('DISTANCE (cm)')ylabel('INTENSITY (lux)')title('\fontname{Arial}Light Intensity as a Function of Distance','FontSize',14)axis([8 24 0 1200])text(14,700,'Comparison between theory and experiment.','EdgeColor','r','LineWidth',2)hold onplot(xd,yd,'ro--','linewidth',1.0,'markersize',10)legend('Theory','Experiment',0)hold off?