1、汽车运用作业matlab程序精品文档1.31)绘制驱动力与行驶阻力平衡图利用Matlab画图,具体语句如下:n=600:1:4000;Ttq=-19.313+295.27*n/1000-165.44*(n/1000).2+40.874*(n/1000).3-3.8445*(n/1000).4;io=5.83;t=0.844;r=0.367;ig1=5.56;ua=0.377*r*n/(ig1*io);Ft1=Ttq*ig1*io*t/r;plot(ua,Ft1)hold on;n=600:1:4000;Ttq=-19.313+295.27*n/1000-165.44*(n/1000).2+40
2、.874*(n/1000).3-3.8445*(n/1000).4;io=5.83;t=0.844;r=0.367;ig2=2.769;ua=0.377*r*n/(ig2*io);Ft2=Ttq*ig2*io*t/r;plot(ua,Ft2)hold on;n=600:1:4000;Ttq=-19.313+295.27*n/1000-165.44*(n/1000).2+40.874*(n/1000).3-3.8445*(n/1000).4;io=5.83;t=0.844;r=0.367;ig3=1.644;ua=0.377*r*n/(ig3*io);Ft3=Ttq*ig3*io*t/r;plo
3、t(ua,Ft3)hold on;n=600:1:4000;Ttq=-19.313+295.27*n/1000-165.44*(n/1000).2+40.874*(n/1000).3-3.8445*(n/1000).4;io=5.83;t=0.844;r=0.367;ig4=1.00;ua=0.377*r*n/(ig4*io);Ft4=Ttq*ig4*io*t/r;plot(ua,Ft4)hold on;n=600:1:4000;Ttq=-19.313+295.27*n/1000-165.44*(n/1000).2+40.874*(n/1000).3-3.8445*(n/1000).4;io=
4、5.83;t=0.844;r=0.367;ig5=0.793;ua=0.377*r*n/(ig5*io);Ft5=Ttq*ig5*io*t/r;plot(ua,Ft5)hold on;m=3880;f=0.012;g=9.8;CdA=2.77;u=0:1:120;Ff=m*g*f;Fw=CdA*u.2/21.15;Fr=Ff+Fw;Ft5=Ttq*ig5*io*t/r;Ff=m*g*f;Fw=CdA*u.2/21.15;Fr=Ff+Fw;plot(u,Fr)运行生成图像如下:2)求汽车最高车速,最大爬坡度及克服该坡度时相应的附着率当Ft=Ff+Fw时,汽车处于稳定状态,并达到最高车速 由图可知
5、max=101km/h最大爬坡度及附着率:一档时有最大爬坡度,由驱动力与阻力图当ua=8.037km/h时: GsinFt-(Ff+Fw)最大。可知: Ft=13058N,Fr=316,F=Ft-Fr=12742N. 由: Gsin=F可得: =19.2. i=tan=0.348 货车为后轮驱动 C2=i/(a/L+hg*i/L) 其中 L=3.2m, a=1.947m, hg=0.9m. 解得 C2=0.49273)绘制加速度倒数曲线:利用Matlab画图,具体语句如下:n=600:1:4000;Ttq=-19.313+295.27*n/1000-165.44*(n/1000).2+40.8
6、74*(n/1000).3-3.8445*(n/1000).4;i0=5.83;t=0.844;r=0.367;ig1=5.56;Iw1=1.798;Iw2=3.598;If=0.218;m=3880;r=0.367;g=9.8;f=0.012;CdA=2.77;ua=0.377*r*n/(ig1*io);Ft1=Ttq*ig1*io*t/r;dert=1+(Iw1+Iw2)/(m*r.2)+If*ig1.2*i0.2*t/(m*r.2);Ff=m*g*f;Fw1=CdA*ua.2/21.15;Fr1=Ff+Fw1;a1=(dert*m)./(Ft1-Fr1);plot(ua,a1)hold
7、on;n=600:1:4000;Ttq=-19.313+295.27*n/1000-165.44*(n/1000).2+40.874*(n/1000).3-3.8445*(n/1000).4;io=5.83;t=0.844;r=0.367;ig2=2.769;Iw1=1.798;Iw2=3.598;If=0.218;m=3880;r=0.367;g=9.8;f=0.012;CdA=2.77;ua=0.377*r*n/(ig2*io);Ft2=Ttq*ig2*io*t/r;dert=1+(Iw1+Iw2)/(m*r.2)+If*ig2.2*io.2*t/(m*r.2);Ff=m*g*f;Fw2=
8、CdA*ua.2/21.15;Fr2=Ff+Fw2;a2=(dert*m)./(Ft2-Fr2);plot(ua,a2)hold on;n=600:1:4000;Ttq=-19.313+295.27*n/1000-165.44*(n/1000).2+40.874*(n/1000).3-3.8445*(n/1000).4;io=5.83;t=0.844;r=0.367;ig3=1.644;Iw1=1.798;Iw2=3.598;If=0.218;m=3880;r=0.367;g=9.8;f=0.012;CdA=2.77;ua=0.377*r*n/(ig3*io);Ft3=Ttq*ig3*io*t
9、/r;dert=1+(Iw1+Iw2)/(m*r.2)+If*ig3.2*i0.2*t/(m*r.2);Ff=m*g*f;Fw=CdA*ua.2/21.15;Fr=Ff+Fw;a3=(dert*m)./(Ft3-Fr);plot(ua,a3)hold on;n=600:1:4000;Ttq=-19.313+295.27*n/1000-165.44*(n/1000).2+40.874*(n/1000).3-3.8445*(n/1000).4;io=5.83;t=0.844;r=0.367;ig4=1.00;Iw1=1.798;Iw2=3.598;If=0.218;m=3880;r=0.367;g
10、=9.8;f=0.012;CdA=2.77;ua=0.377*r*n/(ig4*io);Ft4=Ttq*ig4*io*t/r;dert=1+(Iw1+Iw2)/(m*r.2)+If*ig4.2*io.2*t/(m*r.2);Ff=m*g*f;Fw=CdA*ua.2/21.15;Fr=Ff+Fw;a4=(dert*m)./(Ft4-Fr);plot(ua,a4)hold on;运行程序生成图形如下:求加速时间语句如下:n=600:1:4000;Ttq=-19.313+295.27*n/1000-165.44*(n/1000).2+40.87*(n/1000).3-3.8445*(n/1000).
11、4;io=5.83;t=0.844;r=0.367;ig2=2.769;ig3=1.644;ig4=1.00;ua2=0.377*r*n/(ig2*i0);ua3=0.377*r*n/(ig3*i0);ua4=0.377*r*n/(ig4*i0);Ft2=Ttq*ig2*i0*t/r;Ft3=Ttq*ig3*i0*t/r;Ft4=Ttq*ig4*i0*t/r;m=3880;f=0.012;g=9.8;CdA=2.77;Ff2=m*g*f;Fw2=CdA*ua2.2/21.15;Fr2=Ff2+Fw2;F2=Ft2-Fr2;a2=m./F2;Ff3=m*g*f;Fw3=CdA*ua3.2/21.
12、15;Fr3=Ff3+Fw3;F3=Ft3-Fr3;a3=m./F3;Ff4=m*g*f;Fw4=CdA*ua4.2/21.15;Fr4=Ff4+Fw4;F4=Ft4-Fr4;a4=m./F4;m2=5.142415:0.001:34.282777;m3=34.28277:0.001:57.74269;m4=57.7427:0.001:70;t2=interp1(ua2,a2,m2,spline);t3=interp1(ua3,a3,m3,spline);t4=interp1(ua4,a4,m4,spline);plot(m2,t2,m3,t3,m4,t4); hold on;%面积 A=0.
13、001*sum(t2-0)+0.001*sum(t3-0)+0.001*sum(t4-0)T=86.8332/3.6运行结果:A= 88.5961;T= 24.1203即加速时间为24.1203 S各档位加速时间段图像如下:2.71)汽车功率平衡图:Matlab语句如下:n=600:1:4000;Ttq=-19.313+295.27*n/1000-165.44*(n/1000).2+40.874*(n/1000).3-3.8445*(n/1000).4;io=5.83;r=0.367;ig1=5.56;ua=0.377*r*n/(ig1*io);Ttqn=-19.313*n+295.27*10
14、00*(n/1000).2-165.44*1000*(n/1000).3+40.874*1000*(n/1000). 4-3.8445*1000*(n/1000).5;P1=0.377*Ttqn/3600;plot(ua,P1)hold on;n=600:1:4000;Ttq=-19.313+295.27*n/1000-165.44*(n/1000).2+40.874*(n/1000).3-3.8445*(n/1000).4;io=5.83;r=0.367;ig2=2.769;ua=0.377*r*n/(ig2*io);Ttqn=-19.313*n+295.27*1000*(n/1000).2
15、-165.44*1000*(n/1000).3+40.874*1000*(n/1000).4-3.8445*1000*(n/1000).5;P2=0.377*Ttqn/3600;plot(ua,P2)hold on;n=600:1:4000;Ttq=-19.313+295.27*n/1000-165.44*(n/1000).2+40.874*(n/1000).3-3.8445*(n/1000).4;io=5.83;r=0.367;ig3=1.644;ua=0.377*r*n/(ig3*io);Ttqn=-19.313*n+295.27*1000*(n/1000).2-165.44*1000*(
16、n/1000).3+40.874*1000*(n/1000).4-3.8445*1000*(n/1000).5;P3=0.377*Ttqn/3600;plot(ua,P3)hold on;n=600:1:4000;Ttq=-19.313+295.27*n/1000-165.44*(n/1000).2+40.874*(n/1000).3-3.8445*(n/1000).4;io=5.83;r=0.367;ig4=1.00;ua=0.377*r*n/(ig4*io);Ttqn=-19.313*n+295.27*1000*(n/1000).2-165.44*1000*(n/1000).3+40.87
17、4*1000*(n/1000).4-3.8445*1000*(n/1000).5;P4=0.377*Ttqn/3600;plot(ua,P4)hold on;n=600:1:4000;Ttq=-19.313+295.27*n/1000-165.44*(n/1000).2+40.874*(n/1000).3-3.8445*(n/1000).4;io=5.83;r=0.367;ig5=0.793;ua=0.377*r*n/(ig5*io);Ttqn=-19.313*n+295.27*1000*(n/1000).2-165.44*1000*(n/1000).3+40.874*1000*(n/1000
18、).4-3.8445*1000*(n/1000).5;P5=0.377*Ttqn/3600;plot(ua,P5)hold on;ua=0:1:110;m=3880;f=0.012;g=9.8;CdA=2.77;t=0.844;Pr=(m*g*f*ua+CdA*ua.3/21.15)/(1000*3.6*t);plot(ua,Pr)生成图形如下:2)最高档与次高档百公里油耗次高档百公里油耗:利用Matlab计算出八组数据,Matlab语句如下:n=815;r=0.367;ig4=1.00;io=5.83;roug=7.00;m=3880;f=0.012;g=9.8;CdA=2.77;t=0.8
19、44;B0=1426.8;B1=-416.46;B2=72.379;B3=-5.8629;B4=0.17768;ua=0.377*n*r/(ig4*io)P=(m*g*f*ua+CdA*ua.3/21.15)/(3600*t);b=B0+B1*P+B2*P.2+B3*P.3+B4*P.4;Qs1=P*b/(1.02*ua*roug)n=1207;r=0.367;ig4=1.00;io=5.83;roug=7.00;m=3880;f=0.012;g=9.8;CdA=2.77;t=0.844;B0=1354.7;B1=-303.98;B2=36.657;B3=-2.0553;B4=0.043072
20、;ua=0.377*n*r/(ig4*io)P=(m*g*f*ua+CdA*ua.3/21.15)/(3600*t);b=B0+B1*P+B2*P.2+B3*P.3+B4*P.4;Qs2=P*b/(1.02*ua*roug)n=1614;r=0.367;ig4=1.00;io=5.83;roug=7.00;m=3880;f=0.012;g=9.8;CdA=2.77;t=0.844;B0=1284.4;B1=-189.75;B2=14.524;B3=-0.51184;B4=0.0068164;ua=0.377*n*r/(ig4*io)P=(m*g*f*ua+CdA*ua.3/21.15)/(36
21、00*t);b=B0+B1*P+B2*P.2+B3*P.3+B4*P.4;Qs3=P*b/(1.02*ua*roug)n=2012;r=0.367;ig4=1.00;io=5.83;roug=7.00;m=3880;f=0.012;g=9.8;CdA=2.77;t=0.844;B0=1122.9;B1=-121.59;B2=7.0035;B3=-0.18517;B4=0.0018555;ua=0.377*n*r/(ig4*io)P=(m*g*f*ua+CdA*ua.3/21.15)/(3600*t);b=B0+B1*P+B2*P.2+B3*P.3+B4*P.4;Qs4=P*b/(1.02*ua
22、*roug)n=2063;r=0.367;ig4=1.00;io=5.83;roug=7.00;m=3880;f=0.012;g=9.8;CdA=2.77;t=0.844;B0=1141.0;B1=-98.893;B2=4.4763;B3=-0.091077;B4=0.00068906;ua=0.377*n*r/(ig4*io)P=(m*g*f*ua+CdA*ua.3/21.15)/(3600*t);b=B0+B1*P+B2*P.2+B3*P.3+B4*P.4;Qs5=P*b/(1.02*ua*roug)n=3006;r=0.367;ig4=1.00;io=5.83;roug=7.00;m=3
23、880;f=0.012;g=9.8;CdA=2.77;t=0.844;B0=1051.2;B1=-73.714;B2=2.8593;B3=-0.05138;B4=0.00035032;ua=0.377*n*r/(ig4*io)P=(m*g*f*ua+CdA*ua.3/21.15)/(3600*t);b=B0+B1*P+B2*P.2+B3*P.3+B4*P.4;Qs6=P*b/(1.02*ua*roug)n=3403;r=0.367;ig4=1.00;io=5.83;roug=7.00;m=3880;f=0.012;g=9.8;CdA=2.77; t=0.844;B0=1233.9;B1=-84
24、.478;B2=2.9788;B3=-0.047449;B4=0.00028230;ua=0.377*n*r/(ig4*io)P=(m*g*f*ua+CdA*ua.3/21.15)/(3600*t);b=B0+B1*P+B2*P.2+B3*P.3+B4*P.4;Qs7=P*b/(1.02*ua*roug)n=3884;r=0.367;ig4=1.00;io=5.83;roug=7.00;m=3880;f=0.012;g=9.8;CdA=2.77;t=0.844;B0=1129.7;B1=-45.291;B2=0.71113;B3=-0.00075215;B4=-0.000038568;ua=0
25、.377*n*r/(ig4*io)P=(m*g*f*ua+CdA*ua.3/21.15)/(3600*t);b=B0+B1*P+B2*P.2+B3*P.3+B4*P.4;Qs8=P*b/(1.02*ua*roug)运行结果如下:ua/(km/h)19.341828.644838.303847.749348.959671.339180.760892.1760Qs/(L/100km)15.372113.002713.589913.699215.812316.713419.075322.1307舍去第一组数据利用EXCEL画出图像:最高档百公里油耗:利用Matlab计算出八组数据,Matlab语句如
26、下:n=815;r=0.367;ig4=0.793;io=5.83;roug=7.00;m=3880;f=0.012;g=9.8;CdA=2.77;t=0.844;B0=1426.8;B1=-416.46;B2=72.379;B3=-5.8629;B4=0.17768;ua=0.377*n*r/(ig4*io)P=(m*g*f*ua+CdA*ua.3/21.15)/(3600*t);b=B0+B1*P+B2*P.2+B3*P.3+B4*P.4;Qs1=P*b/(1.02*ua*roug)n=1207;r=0.367;ig4=0.793;io=5.83;roug=7.00;m=3880;f=0.
27、012;g=9.8;CdA=2.77;t=0.844;B0=1354.7;B1=-303.98;B2=36.657;B3=-2.0553;B4=0.043072;ua=0.377*n*r/(ig4*io)P=(m*g*f*ua+CdA*ua.3/21.15)/(3600*t);b=B0+B1*P+B2*P.2+B3*P.3+B4*P.4;Qs2=P*b/(1.02*ua*roug)n=1614;r=0.367;ig4=0.793;io=5.83;roug=7.00;m=3880;f=0.012;g=9.8;CdA=2.77;t=0.844;B0=1284.4;B1=-189.75;B2=14.
28、524;B3=-0.51184;B4=0.0068164;ua=0.377*n*r/(ig4*io)P=(m*g*f*ua+CdA*ua.3/21.15)/(3600*t);b=B0+B1*P+B2*P.2+B3*P.3+B4*P.4;Qs3=P*b/(1.02*ua*roug)n=2012;r=0.367;ig4=0.793;io=5.83;roug=7.00;m=3880;f=0.012;g=9.8;CdA=2.77;t=0.844;B0=1122.9;B1=-121.59;B2=7.0035;B3=-0.18517;B4=0.0018555;ua=0.377*n*r/(ig4*io)P=
29、(m*g*f*ua+CdA*ua.3/21.15)/(3600*t);b=B0+B1*P+B2*P.2+B3*P.3+B4*P.4;Qs4=P*b/(1.02*ua*roug)n=2603;r=0.367;ig4=0.793;io=5.83;roug=7.00;m=3880;f=0.012;g=9.8;CdA=2.77;t=0.844;B0=1141.0;B1=-98.893;B2=4.4763;B3=-0.091077;B4=0.00068906;ua=0.377*n*r/(ig4*io)P=(m*g*f*ua+CdA*ua.3/21.15)/(3600*t);b=B0+B1*P+B2*P.
30、2+B3*P.3+B4*P.4;Qs5=P*b/(1.02*ua*roug)n=3006;r=0.367;ig4=0.793;io=5.83;roug=7.00;m=3880;f=0.012;g=9.8;CdA=2.77;t=0.844;B0=1051.2;B1=-73.714;B2=2.8593;B3=-0.05138;B4=0.00035032;ua=0.377*n*r/(ig4*io)P=(m*g*f*ua+CdA*ua.3/21.15)/(3600*t);b=B0+B1*P+B2*P.2+B3*P.3+B4*P.4;Qs6=P*b/(1.02*ua*roug)n=3403;r=0.36
31、7;ig4=0.793;io=5.83;roug=7.00;m=3880;f=0.012;g=9.8;CdA=2.77;t=0.844;B0=1233.9;B1=-84.478;B2=2.9788;B3=-0.047449;B4=0.00028230;ua=0.377*n*r/(ig4*io)P=(m*g*f*ua+CdA*ua.3/21.15)/(3600*t);b=B0+B1*P+B2*P.2+B3*P.3+B4*P.4;Qs7=P*b/(1.02*ua*roug)n=3884;r=0.367;ig4=0.793;io=5.83;roug=7.00;m=3880;f=0.012;g=9.8
32、;CdA=2.77;t=0.844;B0=1129.7;B1=-45.291;B2=0.71113;B3=-0.00075215;B4=-0.000038568;ua=0.377*n*r/(ig4*io)P=(m*g*f*ua+CdA*ua.3/21.15)/(3600*t);b=B0+B1*P+B2*P.2+B3*P.3+B4*P.4;Qs8=P*b/(1.02*ua*roug)运行结果如下:ua/(km/h)24.390636.122148.302560.213577.900489.9611101.8422116.2371Qs/(L/100km)14.027211.773812.434413.546517.192919.483525.3086-6.4323舍去最后一组数值,利用EXCEL画图:收集于网络,如有侵权请联系管理员删除