1、六杆机构铰链六杆机构的运动分析1 题目:铰链六杆机构的运动分析如图1所示,已知铰链六杆机构各构件的尺寸为: m, m, m, m, m, m, ,,n=1000r/min,逆时针转动,计算连杆2和摇杆4的角位移,角速度及角加速度和滑块5的位移,速度及加速度,并绘制出运动线图。图1 铰链六杆机构运动简图2 数学模型(1) 位置分析 如图可写出机构各杆矢所构成的矢量封闭方程 (1)其复数形式表示为 (2)将上式的实部和虚部分离,得 (3)联解上式即可求得二个未知方向角。(2)速度分析 将式(2)对时间t求一次导数, 得速度关系 (4)将上式的实部和虚部分开,有 (5)联解上式即可求得二个角速度。若
2、用矩阵形式来表示,则上式可写为 (6)(3)加速度分析 将式(2)对时间t求二次导数,可得加速度关系 (7)将上式的实部和虚部分开,有 (8)联解上式即可求得二个角加速度。上式用矩阵得形式可表示为 (9)3 程序设计主程序six_bar_main文件%1.输入已知数据clear;l1=0.22;l2=0.65;l4=0.70;l6=0.18;a=0.60;s3=1.00;omega1=(100*pi)/3;alpha1=0;hd=pi/180;du=180/pi;%2.调用子函数six_bar计算for n1=1:361; theta1(n1)=(n1-1)*hd; theta,omega,a
3、lpha=six_bar(theta1(n1),omega1,alpha1,l1,l2,l4,l6,a,s3); s2(n1)=theta(1); %s2表示杆BD的长度 theta2(n1)=theta(2); %theta2表示杆2转过角度 theta4(n1)=theta(3); %theta4表示杆4转过角度 s5(n1)=theta(4); %s5表示滑块5相对x轴的距离 v2(n1)=omega(1); %v2表示滑块3相对于BD杆的速度 omega2(n1)=omega(2); %omega2表示构件2的角速度 omega4(n1)=omega(3); %omega4表示构件4的
4、角速度 v5(n1)=omega(4); %v5表示滑块5的速度 a2(n1)=alpha(1); %a2表示滑块3相对于杆BD的加速度 alpha2(n1)=alpha(2); %alpha2表示杆2的角加速度 alpha4(n1)=alpha(3); %alpha4表示杆的角加速度 a5(n1)=alpha(4); %a5表示滑块5的加速度end%3.图形输出figure(1);n1=1:361;subplot(2,2,1); %绘角位移及位移线图plot(n1,theta2*du,r);grid on;hold on;axis auto;haxes,hline1,hline2=ploty
5、y(n1,theta4*du,n1,s5);grid on;hold on;title(角位移及位移线图);xlabel(曲柄转角theta_1/circ)axes(haxes(1);ylabel(角位移/circ)axes(haxes(2);ylabel(位移/m)hold on;grid on;text(300,0.83,theta_2)text(150,0.92,theta_4)text(180,0.84,s_5)subplot(2,2,2); %绘角速度及速度线图 plot(n1,omega2,r);grid on;hold on;axis auto;haxes,hline1,hlin
6、e2=plotyy(n1,omega4,n1,v5);grid on;hold on;title(角速度及速度线图);xlabel(曲柄转角theta_1/circ)axes(haxes(1);ylabel(角速度/radcdots-1)axes(haxes(2);ylabel(速度/mcdots-1)hold on;grid on;text(90,6,omega_2)text(230,-15,omega_4)text(130,0.1,v_5)subplot(2,2,3); %绘角加速度及加速度图plot(n1,alpha2,r);grid on;hold on;axis auto;haxes
7、,hline1,hline2=plotyy(n1,alpha4,n1,a5);grid on;hold on;title(角加速度及加速度图);xlabel(曲柄转角theta_1/circ)axes(haxes(1);ylabel(角加速度/radcdots-2)axes(haxes(2);ylabel(加速度/mcdots-1)hold on;grid on;text(125,500,alpha_2)text(150,-1200,alpha_4)text(160,1000,a_5)subplot(2,2,4); %机构图nx1=12.083 ;nx2=74.760 ;nx=300 ;x(1
8、)=0;y(1)=0;x(2)=l1*1000*cos(nx*hd);y(2)=l1*1000*sin(nx*hd);x(3)=s3*1000-50*cos(nx1*hd);y(3)=-50*sin(nx1*hd);x(4)=s3*1000;y(4)=0;x(5)=s3*1000+150*cos(nx1*hd);y(5)=150*sin(nx1*hd);x(6)=s3*1000+50*cos(nx1*hd)+25*sin(nx1*hd);y(6)=50*sin(nx1*hd)-25*cos(nx1*hd);x(7)=s3*1000-50*cos(nx1*hd)+25*sin(nx1*hd);y
9、(7)=-25*cos(nx1*hd)-50*sin(nx1*hd);x(8)=s3*1000-50*cos(nx1*hd)-25*sin(nx1*hd);y(8)=25*cos(nx1*hd)-50*sin(nx1*hd);x(9)=s3*1000+50*cos(nx1*hd)-25*sin(nx1*hd);y(9)=50*sin(nx1*hd)+25*cos(nx1*hd);x(10)=s3*1000+50*cos(nx1*hd)+25*sin(nx1*hd);y(10)=50*sin(nx1*hd)-25*cos(nx1*hd);x(11)=l1*1000*cos(nx*hd)+l2*1
10、000*cos(nx1*hd);y(11)=l1*1000*sin(nx*hd)+l2*1000*sin(nx1*hd);x(12)=l1*1000*cos(nx*hd)+l2*1000*cos(nx1*hd)+l6*1000*sin(nx1*hd);y(12)=l1*1000*sin(nx*hd)+l2*1000*sin(nx1*hd)-l6*1000*cos(nx1*hd);x(13)=a*1000;y(13)=l1*1000*sin(nx*hd)+l2*1000*sin(nx1*hd)-l6*1000*cos(nx1*hd)-l4*1000*sin(nx2*hd);x(14)=a*100
11、0-20;y(14)=l1*1000*sin(nx*hd)+l2*1000*sin(nx1*hd)-l6*1000*cos(nx1*hd)-l4*1000*sin(nx2*hd)+50;x(15)=a*1000;y(15)=l1*1000*sin(nx*hd)+l2*1000*sin(nx1*hd)-l6*1000*cos(nx1*hd)-l4*1000*sin(nx2*hd)+50;x(16)=a*1000+20;y(16)=l1*1000*sin(nx*hd)+l2*1000*sin(nx1*hd)-l6*1000*cos(nx1*hd)-l4*1000*sin(nx2*hd)+50;x(
12、17)=a*1000+20;y(17)=l1*1000*sin(nx*hd)+l2*1000*sin(nx1*hd)-l6*1000*cos(nx1*hd)-l4*1000*sin(nx2*hd)-50;x(18)=a*1000;y(18)=l1*1000*sin(nx*hd)+l2*1000*sin(nx1*hd)-l6*1000*cos(nx1*hd)-l4*1000*sin(nx2*hd)-50;x(19)=a*1000-20;y(19)=l1*1000*sin(nx*hd)+l2*1000*sin(nx1*hd)-l6*1000*cos(nx1*hd)-l4*1000*sin(nx2*
13、hd)-50;x(20)=a*1000-20;y(20)=l1*1000*sin(nx*hd)+l2*1000*sin(nx1*hd)-l6*1000*cos(nx1*hd)-l4*1000*sin(nx2*hd)+50;k=1:2;plot(x(k),y(k);hold on;k=2:5;plot(x(k),y(k);hold on;k=6:10;plot(x(k),y(k);hold on;k=11:12;plot(x(k),y(k);hold on;k=12:13;plot(x(k),y(k);hold on;k=14:20;plot(x(k),y(k);hold on;grid on;
14、plot(x(1),y(1),o);plot(x(2),y(2),o);plot(x(4),y(4),o);plot(x(12),y(12),o);plot(x(13),y(13),o);hold on;title(机构简图);xlabel(mm)ylabel(mm)axis(-100 1300 -1100 300);%4.运动仿真figure(2)m=moviein(20);j=0;for n1=1:361;j=j+1;clf;x(1)=0;y(1)=0;x(2)=l1*1000*cos(theta1(n1);y(2)=l1*1000*sin(theta1(n1);x(3)=s3*1000-
15、50*cos(theta2(n1);y(3)=-50*sin(theta2(n1);x(4)=s3*1000;y(4)=0;x(5)=s3*1000+150*cos(theta2(n1);y(5)=150*sin(theta2(n1);x(6)=s3*1000+50*cos(theta2(n1)+25*sin(theta2(n1);y(6)=50*sin(theta2(n1)-25*cos(theta2(n1);x(7)=s3*1000-50*cos(theta2(n1)+25*sin(theta2(n1);y(7)=-25*cos(theta2(n1)-50*sin(theta2(n1);x
16、(8)=s3*1000-50*cos(theta2(n1)-25*sin(theta2(n1);y(8)=25*cos(theta2(n1)-50*sin(theta2(n1);x(9)=s3*1000+50*cos(theta2(n1)-25*sin(theta2(n1);y(9)=50*sin(theta2(n1)+25*cos(theta2(n1);x(10)=s3*1000+50*cos(theta2(n1)+25*sin(theta2(n1);y(10)=50*sin(theta2(n1)-25*cos(theta2(n1);x(11)=l1*1000*cos(theta1(n1)+
17、l2*1000*cos(theta2(n1);y(11)=l1*1000*sin(theta1(n1)+l2*1000*sin(theta2(n1);x(12)=l1*1000*cos(theta1(n1)+l2*1000*cos(theta2(n1)+l6*1000*sin(theta2(n1);y(12)=l1*1000*sin(theta1(n1)+l2*1000*sin(theta2(n1)-l6*1000*cos(theta2(n1);x(13)=a*1000;y(13)=l1*1000*sin(theta1(n1)+l2*1000*sin(theta2(n1)-l6*1000*co
18、s(theta2(n1)-l4*1000*sin(theta4(n1);x(14)=a*1000-20;y(14)=l1*1000*sin(theta1(n1)+l2*1000*sin(theta2(n1)-l6*1000*cos(theta2(n1)-l4*1000*sin(theta4(n1)+50;x(15)=a*1000;y(15)=l1*1000*sin(theta1(n1)+l2*1000*sin(theta2(n1)-l6*1000*cos(theta2(n1)-l4*1000*sin(theta4(n1)+50;x(16)=a*1000+20;y(16)=l1*1000*sin
19、(theta1(n1)+l2*1000*sin(theta2(n1)-l6*1000*cos(theta2(n1)-l4*1000*sin(theta4(n1)+50;x(17)=a*1000+20;y(17)=l1*1000*sin(theta1(n1)+l2*1000*sin(theta2(n1)-l6*1000*cos(theta2(n1)-l4*1000*sin(theta4(n1)-50;x(18)=a*1000;y(18)=l1*1000*sin(theta1(n1)+l2*1000*sin(theta2(n1)-l6*1000*cos(theta2(n1)-l4*1000*sin
20、(theta4(n1)-50;x(19)=a*1000-20;y(19)=l1*1000*sin(theta1(n1)+l2*1000*sin(theta2(n1)-l6*1000*cos(theta2(n1)-l4*1000*sin(theta4(n1)-50;x(20)=a*1000-20;y(20)=l1*1000*sin(theta1(n1)+l2*1000*sin(theta2(n1)-l6*1000*cos(theta2(n1)-l4*1000*sin(theta4(n1)+50;k=1:2;plot(x(k),y(k);hold on;k=2:5;plot(x(k),y(k);h
21、old on;k=6:10;plot(x(k),y(k);hold on;k=11:12;plot(x(k),y(k);hold on;k=12:13;plot(x(k),y(k);hold on;k=14:20;plot(x(k),y(k);hold on;grid on;axis(-300 1300 -1100 300);title(运动仿真);xlabel(mm)ylabel(mm)plot(x(1),y(1),o);plot(x(2),y(2),o);plot(x(4),y(4),o);plot(x(12),y(12),o);plot(x(13),y(13),o); axis equa
22、l;m(j)=getframe;endmovie(m);子程序six_bar文件%1计算角位移和线位移s2=sqrt(s3-l1*cos(theta1)*(s3-l1*cos(theta1)+(l1*sin(theta1)*(l1*sin(theta1);theta2=asin(-l1*sin(theta1)/s2);theta4=acos(l1*cos(theta1)+l2*cos(theta2)+l6*sin(theta2)-a)/l4);s5=l4*sin(theta4)+l6*cos(theta2)-l1*sin(theta1)-l2*sin(theta2);theta(1)=s2;t
23、heta(2)=theta2;theta(3)=theta4;theta(4)=s5;%计算角速度和线速度A=sin(theta2),s2*cos(theta2),0,0; cos(theta2),-s2*sin(theta2),0,0; 0,l2*cos(theta2)+l6*sin(theta2),-l4*cos(theta4),1; 0,l2*sin(theta2)-l6*sin(theta2),-l4*sin(theta4),0;B=-l1*cos(theta1);l1*sin(theta1);-l1*cos(theta1);-l1*sin(theta1);omega=A(omega1
24、*B);V2=omega(1);omega2=omega(2);omega4=omega(3);V5=omega(4);%计算角加速度和加速度A=sin(theta2),s2*cos(theta2),0,0; cos(theta2),-s2*sin(theta2),0,0; 0,l2*cos(theta2)+sin(theta2),-l4*cos(theta4),1; 0,l2*sin(theta2)-l6*cos(theta2),l4*sin(theta4),0;At=-2*omega2*sin(theta2),s2*omega2*sin(theta2),0,0; 2*omega2*sin(
25、theta2),s2*omega2*cos(theta2),0,0; 0,l2*omega2*sin(theta2)-l6*omega2*cos(theta2),-l4*omega4*sin(theta4),0; 0,-l2*omega2*cos(theta2)-l6*omega2*sin(theta2),l4*omega4*cos(theta4),0;Bt=l1*omega1*sin(theta1);l1*omega1*cos(theta1);l1*omega1*sin(theta1);l1*omega1*cos(theta1);alpha=A(At*omega+omega1*Bt);a2=alpha(1);alpha2=alpha(2);alpha4=alpha(3);a5=alpha(4);4 计算结果图2为运算结果和六杆机构的运动线图图2
copyright@ 2008-2022 冰豆网网站版权所有
经营许可证编号:鄂ICP备2022015515号-1