1、CASIO fx-5800p 交点法计算缓和曲线内任意点计算程序SpiraL curve(缓和曲线任意点坐标计算)程序说明:本程序是基于计算对称性缓和曲线而编写的程序,是以交点法为基础,故输入数据多了点。程序思路:根据曲线的交点数据,进而推算曲线要素,并进行曲线内任意点的坐标计算。LbL 0:Cls19DimZ 变量赋值“INT(s)=”?F 输入交点坐标方位角“JD PEG=”?K 输入交点桩号“INT X(JD)=”?X 输入交点 X 坐标“INT Y(JD)=”?Y 输入交点 Y 坐标“INT R(s)=”?R 输入缓和曲线半径“INT L(s)=”?L 输入缓和曲线长“TURNING
2、ANGLE=”?A 输入转角“TURNING DIRECTION L,+R=”?I 输入路线转向:左负右正 I 赋值为 1L2(24R)PL2-L3(240R2)Q90L(R)B(R+P)Tan ( A2)+QT 计算切线长R(A-2B)180O 计算圆曲线长R(A-2B)180+2LC 计算曲线长(R+P)cos(A2 )-RE 计算外距2T-CD 计算切曲差K-TZ3 ZH 点Z3+LZ4 HY 点Z4+OZ5 YH 点Z5+LZ6 HZ 点Z6-C2Z7 QZ 点X+Tcos(F+180)Z16 ZH 点 X 坐标Y+TsIn(F+180)Z17 ZH 点 Y 坐标L-L3(90R2 )
3、GZ16+Gcos(F+30IL(R) )Z8 HY 点 X 坐标Z17+Gsin(F+30IL(R) Z9 HY 点 Y 坐标Z8+2Rsin(45O(R)cos(F+I45O(R)+I90L(R) Z14 QZ 点 X 坐标Z9+2Rsin(45O(R)sin(F+I45O(R)+I90L(R) Z15 QZ 点 Y 坐标Z8+2Rsin(90O(R)cos(F+I90O(R)+I90L(R) Z10 YH 点 X 坐标Z9+2Rsin(90O(R)sin(F+I90O(R)+I90L(R) Z11 YH 点 Y 坐标X+Tcos(F+IA)Z12 HZ 点 X 坐标Y+TsIn(F+IA
4、)Z13 HZ 点 Y 坐标LbL 2“XIAN SHI QXYS 0YES,1NO” ?Z:CLs 显示曲线要素?输入:0YES,1NOIf Z=0:Then GoTo 3ELse If Z=1:Then GoTo 4:IfEnd:IfEndLbL 3 “QIE XIAN C=”:T“QU XIAN C=”:C“Y QU XIAN=”:O“WAI JU=”:E“QIE QU CHA=”:D“ZH PEG=”:Z3 “X(ZH)=”:Z16 “Y(ZH)=”:Z17 “HY PEG=”:Z4 “X(HY)=”:Z8 “Y(HY)=”:Z9 “QZ PEG=”:Z7 “X(QZ)=”:Z14 “
5、Y(QZ)=”:Z15 “YH PEG=”:Z5 “X(YH)=”:Z10 “Y(YH)=”:Z11 “HZ PEG=”:Z6 “X(HZ)=”:Z12 “Y(HZ)=”:Z13 GoTo 0LbL 4 “INT P PEG=”?H 输入待求点桩号If HZ6:Then GoTo 4:IfendLbL A 待求点位于 ZH 到 HY 段上时“PIAN JIAO -L ,+R = ” ? V 输入边桩与路线中心线夹角:左负右正“PIAN JU = ”? W 边桩与路中法线距离HZ3JJJ5 (90R2L2)SZ16+S cos(F+30IJ2(RL)MZ17+S sin(F+30IJ2(RL)N
6、M+Wcos(F+90IJ2(RL +V) Z18N+Wsin(F+90IJ2(RL +v) Z19“ X(p)= ”: Z18 “ Y(p)= ”: Z19 GoTo 4LbL B 待求点位于 HY 到 YH 段上时“PIAN JIAO -L ,+R = ” ? V“PIAN JU = ”? WHZ4JZ8+2Rsin(90J(R)cosF+90IJ(R)+90IL(R)MZ9+2Rsin(90J(R)sinF+90IJ(R)+90IL(R)NM+Wcos(F+90IL(R)+180IJ(R)+V) Z18N+Wsin(F+90IL(R)+180IJ(R)+V) Z19“X(P)= ”: Z18 “Y(P)= ”: Z19 GoTo 4LbL C 待求点位于 YH 到 HZ 段时“PIAN JIAO -L ,+R = ” ?V“PIAN JU = ”? WZ6 H JJJ5(90R2L2)SZ12+Scos(F+IA+180-30IJ2(RL)MZ13+Ssin(F+IA+180-30IJ2(RL)NM+Wcos(F+IA-90IJ2(RL)+V) Z18N+Wsin(F+IA-90IJ2(RL)+V) Z19“X(p)= ”: Z18 “Y(p)= ”: Z19 GoTo