06.08.2013 Views

内容简介作者简介 - 科学与工程计算系

内容简介作者简介 - 科学与工程计算系

内容简介作者简介 - 科学与工程计算系

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

(2)<br />

G=6.672e-11;ME=5.97e24;vy0=4000; x0=-4.2e7;t0=0;tf=60*60*24*9;<br />

tspan=[t0,tf];Y0=[x0;0;0;vy0];<br />

[t,YY,Te,Ye,Ie]=ode45('DYDt3',[],[],[],G,ME,tspan,Y0); % <br />

X=YY(:,1);Y=YY(:,2);<br />

plot(X,Y,'b','Linewidth',2);hold on<br />

text(0,6e7,'轨道','Color','b')<br />

axis('image');<br />

%<br />

plot(Ye(1,1),0.4e7+Ye(1,2),'r^','MarkerSize',10)<br />

plot(Ye(2,1),0.4e7+Ye(2,2),'bv','MarkerSize',10)<br />

plot(Ye(3,1),-0.4e7+Ye(3,2),'b^','MarkerSize',10)<br />

%<br />

text(0.8*Ye(3,1),-2e7+Ye(3,2),['t3=' sprintf('%6.0f',Te(3))])<br />

text(0.8*Ye(2,1),1.5e7+Ye(2,2),['t2=' sprintf('%6.0f',Te(2))])<br />

%<br />

[XE,YE,ZE] = sphere(10);RE=0.64e7;XE=RE*XE;YE=RE*YE;ZE=0*ZE;<br />

mesh(XE,YE,ZE)<br />

text(1e7,1e7,'地球','Color','r'), hold off<br />

4.14.3 关于 ODE 文件的说明<br />

图 4.14-3<br />

4.14.4 关于解算指令选项 options 的属性设置<br />

4.14.4.1 options 的属性域名<br />

4.14.4.2 options 属性处理和输出函数使用演示<br />

【例 4.14.4.2-1】仍以卫星轨道问题为例(原题见例 4.14.2.1-1, 4.14.2.1-2 , 4.14.2.2-1)。本<br />

例演示如何通过对 options 域的直接设置,借助微分方程解算输出指令,表现解算的中间结<br />

果。具体目标是:画出解向量 [ ] [ ] T<br />

T<br />

Y =<br />

的相平面。相平面的绘制是在微分方程解算中间逐步完成的。<br />

= y1<br />

y2<br />

y3<br />

y4<br />

x y vx<br />

v y 中由 vx<br />

37<br />

x, 构成

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!