⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 s型曲线设计.frm

📁 饮羽公路测设(glcs) 由20多个公路测量、设计、试验和施工组织设计等小软件组成。如《中桩大地坐标》可以计算不等长缓和曲线的中桩和边桩的大地坐标;《缓和曲线反算》可以根据切线长、外距长或缓和曲线长求
💻 FRM
字号:
VERSION 5.00
Begin VB.Form frmsxqxsj 
   BorderStyle     =   3  'Fixed Dialog
   Caption         =   "S型曲线设计"
   ClientHeight    =   3555
   ClientLeft      =   45
   ClientTop       =   345
   ClientWidth     =   7230
   Icon            =   "s型曲线设计.frx":0000
   KeyPreview      =   -1  'True
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   MinButton       =   0   'False
   ScaleHeight     =   3555
   ScaleMode       =   0  'User
   ScaleWidth      =   6863.681
   ShowInTaskbar   =   0   'False
   StartUpPosition =   2  '屏幕中心
   Begin VB.Frame Frame2 
      Caption         =   "计算结果"
      Height          =   3495
      Left            =   2880
      TabIndex        =   16
      Top             =   40
      Width           =   4335
      Begin VB.ListBox List1 
         Height          =   3120
         Left            =   120
         TabIndex        =   17
         Top             =   240
         Width           =   4095
      End
   End
   Begin VB.Frame Frame1 
      Caption         =   "原始数据"
      Height          =   2895
      Left            =   0
      TabIndex        =   8
      Top             =   40
      Width           =   2775
      Begin VB.TextBox Text6 
         Height          =   270
         Left            =   1440
         TabIndex        =   5
         Text            =   "Text6"
         Top             =   2160
         Width           =   1215
      End
      Begin VB.TextBox Text5 
         Height          =   270
         Left            =   1440
         TabIndex        =   4
         Text            =   "Text5"
         Top             =   1800
         Width           =   1215
      End
      Begin VB.TextBox Text1 
         Height          =   270
         Left            =   1440
         TabIndex        =   0
         Text            =   "Text1"
         ToolTipText     =   "如36°15′45″按36.1545输入"
         Top             =   360
         Width           =   1215
      End
      Begin VB.TextBox Text2 
         Height          =   270
         Left            =   1440
         TabIndex        =   1
         Text            =   "Text2"
         ToolTipText     =   "如36°15′45″按36.1545输入"
         Top             =   720
         Width           =   1215
      End
      Begin VB.TextBox Text3 
         Height          =   270
         Left            =   1440
         TabIndex        =   2
         Text            =   "Text3"
         ToolTipText     =   "单位:m"
         Top             =   1080
         Width           =   1215
      End
      Begin VB.CheckBox Check1 
         Caption         =   "前曲线半径可调整吗?"
         Height          =   255
         Left            =   480
         TabIndex        =   6
         Top             =   2520
         Width           =   2175
      End
      Begin VB.TextBox Text4 
         Height          =   270
         Left            =   1440
         TabIndex        =   3
         Text            =   "Text4"
         ToolTipText     =   "单位:m"
         Top             =   1440
         Width           =   1215
      End
      Begin VB.Label Label6 
         Caption         =   "前曲线半径RA="
         Height          =   255
         Left            =   120
         TabIndex        =   15
         Top             =   2160
         Width           =   1335
      End
      Begin VB.Label Label4 
         Caption         =   "后缓和曲线LS2="
         Height          =   255
         Left            =   120
         TabIndex        =   14
         Top             =   1800
         Width           =   1455
      End
      Begin VB.Label Label1 
         Caption         =   "前交点偏角PJa="
         Height          =   255
         Left            =   120
         TabIndex        =   13
         Top             =   360
         Width           =   1455
      End
      Begin VB.Label Label2 
         Caption         =   "后交点偏角PJb="
         Height          =   255
         Left            =   120
         TabIndex        =   12
         Top             =   720
         Width           =   1455
      End
      Begin VB.Label Label3 
         Caption         =   "前缓和曲线LS1="
         Height          =   255
         Left            =   120
         TabIndex        =   11
         Top             =   1440
         Width           =   1695
      End
      Begin VB.Label Label5 
         Caption         =   "两交点间距AB ="
         Height          =   255
         Left            =   120
         TabIndex        =   10
         Top             =   1080
         Width           =   1455
      End
   End
   Begin VB.CommandButton Command2 
      Caption         =   "关闭"
      Height          =   375
      Left            =   1920
      TabIndex        =   9
      Top             =   3120
      Width           =   855
   End
   Begin VB.CommandButton Command1 
      Caption         =   "计算"
      Height          =   375
      Left            =   840
      TabIndex        =   7
      Top             =   3120
      Width           =   855
   End
End
Attribute VB_Name = "frmsxqxsj"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
'计算
    
    On Error GoTo handlerror
    
    List1.Clear
    
    ab = Val(Text4.Text)
    ja = Val(Text1.Text)
    sjwjs = ja
    Call dfmhhd
    pja = hudu
    
    jb = Val(Text2.Text)
    sjwjs = jb
    Call dfmhhd
    pjb = hudu
    
    pj = pja + pjb

    ab = Val(Text3.Text)
    ls1 = Val(Text4.Text)
    ls2 = Val(Text5.Text)
    RA = Val(Text6.Text)
    
m2:
    t1 = (RA + ls1 * ls1 / 24 / RA) * Tan(pja / 2) + ls1 / 2 - ls1 * ls1 * ls1 / 240 / RA / RA
    t = ab - t1
    A1 = Tan(pjb / 2)
    b1 = ls2 / 2 - t
    c1 = Tan(pjb / 2) * ls2 * ls2 / 24
    
    Call yuecfc
    r = x1
    If r = 0 Then
        xianshi = MsgBox("缓和曲线过长或交点间距过短,请重新拟定其值", vbInformation, "问题提示")
        Exit Sub
    End If
    
    Do Until Abs(r - r0) <= 0.01
        r0 = r
        r = (t - ls2 / 2 + ls2 * ls2 * ls2 / 240 / r0 / r0) / Tan(pjb / 2) - ls2 * ls2 / 24 / r0
    Loop

    RB = r
    If Check1.Value = 1 Then
        aa = Sqr(RA * ls1)
        ba = Sqr(RB * ls2)
        If aa / ba > 1.5 Then RA = 2.25 * ba * ba / ls1: GoTo m2
        If ba / aa > 1.5 Then RA = ba * ba / ls1 / 2.25: GoTo m2
    End If

    ta = (RA + ls1 * ls1 / 24 / RA) * Tan(pja / 2) + ls1 / 2
    ea = (RA + ls1 * ls1 / 24 / RA) / Cos(pja / 2) - RA
    lya = pja * RA - ls1
    la = lya + 2 * ls1
    tb = (RB + ls2 * ls2 / 24 / RB) * Tan(pjb / 2) + ls2 / 2
    eb = (RB + ls2 * ls2 / 24 / RB) / Cos(pjb / 2) - RB
    lyb = pjb * RB - ls2
    lb = lyb + 2 * ls2
    
    List1.AddItem ""
    List1.AddItem "    前曲线偏角(°′″)PJa=  " + Str(ja)
    List1.AddItem "    后曲线偏角(°′″)PJb=  " + Str(jb)
    List1.AddItem "    交点间距        (m)AB=  " + Str(ab)
    List1.AddItem "    前圆曲线半径    (m)RA=  " + Str(Int(RA * 1000 + 0.5) / 1000)
    List1.AddItem "    后圆曲线半径    (m)RB=  " + Str(Int(RB * 1000 + 0.5) / 1000)
    List1.AddItem "    前缓和曲线长度 (m)Ls1=  " + Str(Int(ls1 * 1000 + 0.5) / 1000)
    List1.AddItem "    后缓和曲线长度 (m)Ls2=  " + Str(Int(ls2 * 1000 + 0.5) / 1000)
    List1.AddItem "    前切线长度      (m)TA=  " + Str(Int(ta * 1000 + 0.5) / 1000)
    List1.AddItem "    后切线长度      (m)TB=  " + Str(Int(tb * 1000 + 0.5) / 1000)
    List1.AddItem "    前曲线外距长度  (m)EA=  " + Str(Int(ea * 1000 + 0.5) / 1000)
    List1.AddItem "    后曲线外距长度  (m)EB=  " + Str(Int(eb * 1000 + 0.5) / 1000)
    List1.AddItem "    前中间圆曲线长 (m)Lya=  " + Str(Int(lya * 1000 + 0.5) / 1000)
    List1.AddItem "    后中间圆曲线长 (m)Lyb=  " + Str(Int(lyb * 1000 + 0.5) / 1000)
    List1.AddItem "    前平曲线全长   (m)Lha=  " + Str(Int(la * 1000 + 0.5) / 1000)
    List1.AddItem "    后平曲线全长   (m)Lhb=  " + Str(Int(lb * 1000 + 0.5) / 1000)
    
    
    Exit Sub
handlerror:
    xianshi = MsgBox("请检查输入的数据后再计算。", vbInformation, "问题提示")

End Sub

Private Sub Command2_Click()
'关闭

    On Error GoTo handlerror
    
    If List1.ListCount > 1 And rjsfzc = 88 Then
        frmMain.Text1 = frmMain.Text1 & vbCrLf & ""
        frmMain.Text1 = frmMain.Text1 & vbCrLf & "    九、S型曲线设计计算结果:"
        
        For i = 0 To List1.ListCount - 1
            frmMain.Text1 = frmMain.Text1 & vbCrLf & List1.List(i)
        Next i
        frmMain.Text1 = frmMain.Text1 & vbCrLf & "    --------------------------------------"
    End If
    
    Unload Me
    
    Exit Sub
handlerror:
    
End Sub

Private Sub Form_KeyPress(KeyAscii As Integer)
'Esc键退出,VbEscape可以用27代替
    On Error GoTo handlerror

    If KeyAscii = 27 Then
        Unload Me
    End If
    
    Exit Sub
handlerror:

End Sub

Private Sub Form_Load()
'启动

    Text1.Text = ""
    Text2.Text = ""
    Text3.Text = ""
    Text4.Text = ""
    Text5.Text = ""
    Text6.Text = ""
    List1.Clear
    List1.AddItem "长度:米,角度:如36°15′45″按36.1545输入"
    
End Sub

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -