OB=131.0e-3;
AB=sqrt(2.0*131.0e-3^2);
AC=sqrt(72.0e-3^2+92.63e-3^2);
CAB=atan(72.0e-3/92.63e-3);
B1B=sqrt(OB1.^2+OB.^2-2.0.*OB1.*OB.*cos(XTA-pi/4.0));
BB1O=(pi-(XTA-pi/4.0))/2.0;
OBB1=(pi-(XTA-pi/4.0))/2.0;
BB1A=pi/2.0+BB1O;
B1AB=asin(B1B./AB.*sin(BB1A));
ABB1=pi-BB1A-B1AB;
OBA=OBB1-ABB1;
AO=sqrt(AB.^2+OB.^2-2.0.*AB.*OB.*cos(OBA));
AB1=sqrt(AO.^2-OB1.^2);
S16=AB-AB1;
BTA=XTA-pi/4.0;
ALF=OBA;
VB=OB.*OMGA;
VP16=VB.*sin(ALF)./sin(pi-ALF-BTA);
VZ=VB.*sin(BTA)./sin(pi-ALF-BTA);
OMGAZ=VZ./AB;
CAB1=CAB-B1AB;
GMA=pi-(pi/2.0-CAB1);
VC=sqrt(VP16.^2+(OMGAZ.*AC).^2-2.0.*VP16.*(AC.*OMGAZ).*cos(GMA));
ALFG=pi/2.0+asin(AC.*OMGAZ.*sin(GMA)./VC);
RJ16=RM16.*(VC./OMGA).^2+RJ16.*(OMGAZ./OMGA).^2;
F16=RM16.*9.8.*VC.*cos(ALFG)./OMGA;
FM16=-0.5.*RM16.*9.8.*U.*VP16./OMGA;
end
%弹筒17的运动规律,认为弹筒17在0——45°范围内作平面运动,在45——90°范围内作定轴转动:
RM17=68.8398;
RJ17=0.294227;
U=0.15;
%0——45°
HOB1=pi/4.0;
OB=131.0e-3;
AB=sqrt(2.0*131.0e-3^2);
OH=131.0e-3;
A1O=158.1565e-3;
CAB=atan(72.0e-3/92.63e-3);
AC=sqrt(72.0e-3^2+92.63e-3^2);
OC=72.0e-3+92.63e-3;
A1OC1=pi/4.0;
if XTA<=(pi/4.0);
BTA=XTA+HOB1;
EB=OB.*sin(BTA);
OE=OB.*cos(BTA);
BD=OH-OE;
AD=sqrt(AB.^2-BD.^2);
AH=AD-EB;
AO=sqrt(AH.^2+OH.^2);
OBA=acos((OB.^2+AB.^2-AO.^2)./(2.0.*OB.*AB));
ALF=OBA;
A1H=sqrt(A1O.^2-OH.^2);
S17=A1H-AH;
VB=OB.*OMGA;
VZ=VB.*sin(BTA)./sin(pi-ALF-BTA);
OMGAZ=VZ./AB;
VP=VB.*sin(ALF)./sin(pi-ALF-BTA);
CAD=CAB-asin(BD./AB);
GMA=pi-(pi/2.0-CAD);
VC=sqrt(VP.^2+(OMGAZ.*AC).^2-2.0.*VP.*(AC.*OMGAZ).*cos(GMA));
ALFG=pi./2.0+acos((VP.^2+VC.^2-(AC.*OMGAZ).^2)./(2.0.*VC.*VP));
RJ17=RM17.*(VC./OMGA).^2+RJ17.*(OMGAZ./OMGA).^2;
F17=RM17.*9.8.*VC.*cos(ALFG)./OMGA;
FM17=-RM17.*9.8/2.0.*U.*VP./OMGA;
else
%45——90°
OMGAZ2=OMGA;
ALF2=A1OC1+XTA-pi/4.0;
VC2=OC.*OMGA;
ALFG2=pi/2.0+ALF2;
RJ17=RM17.*(VC2./OMGA).^2+RJ17.*(OMGAZ2./OMGA).^2;
F17=RM17.*9.8.*VC2.*cos(ALFG2)./OMGA;
FM17=0.0;
end
%弹筒18的运动规律,认为弹筒18在0——45°内作定轴转动,在45——90°内作平面运动:
RM18=68.8398;
RJ18=0.294227;
U=0.15;
%0——45°
OC=72.0e-3+185.26e-3/2.0;
C1OH=0.0;
OA=131.0e-3;
B1O=131.0e-3;
BA=185.26e-3;
ABC=atan(72.0e-3/92.63e-3);
BC=sqrt(72.0e-3^2+92.63e-3^2);
ALF2=0.0;
if XTA<=(pi/4.0);