绘图及模型建构.PPT

  1. 1、本文档共138页,可阅读全部内容。
  2. 2、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
  3. 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载
  4. 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
圖比表好 表比文字好 xy plotting functions y=f(x) abscissa ~ x (independent variable) ordinate ~ y (dependent variable) Scale刻度 tick mark刻度標示 axis label 軸稱 or axial title data symbol or point marker Legend ~ 說明 line ~ for theoretical calculation data data symbol ~ for experimental data Requirements of correct plot P.243-244 Read it NOW! Plot, Label Title commands x=[0:.1:52]; y=.4*sqrt(1.8*x); plot(x,y),xlabel(距離(英里)),ylabel(距離(英里)),... title(火箭高度相對於飛行方向的距離函數) grid on, axis([0 52 0 5]) Copy figure Paste it in the word file Plot of complex numbers plot(y)=plot(real(y),imag(y)) %if y is complex z=.1+.9i; n=[0:0.01:10]; plot(z.^n),xlabel(real part),ylabel(imaginary part) The function plot command fplot fplot(‘string’,[xmin xmax]) fplot(‘string’,[xmin xmax ymin ymax]) f=cos(tan(x))-tan(sin(x)); fplot(f,[1 2]) x=[1:.01:2]; y=cos(tan(x))-tan(sin(x)); plot(x,y) Plotting polynomials x=[-6:0.01:6]; p=[3,2,-100,2,-7,90]; plot(x,polyval(p,x)),xlabel(x),ylabel(p) Self testing pp.250-251 Write down the program now! Subplot 子圖 subplot(m,n,p) %將視窗分成m列n行的陣列平面 第p平面 x=[0:.01:5]; y=exp(-1.2*x).*sin(10*x+5); subplot(1,2,1) plot(x,y),xlabel(x1),ylabel(y1),axis([0 5 -1 1]) x=[-6:.01:6]; y=abs(x.^3-100); subplot(1,2,2) plot(x,y),xlabel(x2),ylabel(y2),axis([-6 6 0 350]) overlay plot 層疊圖 P.253 A ~ m列*n行 plot(A) % n條曲線(A的行向量對其索引的圖) plot(x,A) % A矩陣對x向量作圖 plot(A,x) % x向量對A矩陣作圖(m條曲線) plot(A,B) % B矩陣的行對A矩陣的行作圖 Data markers and line types Data markers and line types plot(x,y,’o’) plot(x,y,x,y,’o’) Labeling curves and data x=[0:.01:2]; y=sinh(x); z=tanh(x); plot(x,y,x,z,--),xlabel(x), ... ylabel(Hyperbolic Sine and Tangent), ... legend(sinh(x),tanh(x)) Legend 的移動 plot圖出來後 利用滑鼠左鍵移動之 格線(grid line)造成legend不明顯 在圖畫好 列印前 加入 axes(legend(‘string1’,‘string2’)) %框與軸線設定一致 refresh %強迫圖形重新繪出 x=[0:.01:1]; y=tan(x); z=sec(x); plot(x,y,x,z),xlabel(x), ... ylabel(Tangent and Secant),gtext(tan(x)), ... text(.3,1.2,sec(x)) Graphical solution of equations 圖解法求解方程式 Example 5.2-1 load line

文档评论(0)

fengruiling + 关注
实名认证
内容提供者

该用户很懒,什么也没介绍

1亿VIP精品文档

相关文档