版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
1、.option explicitdim l1 as single, l2 as single, t as single, d!, k!, kd!, thkd!, h!, d1!dim cd as single, cm as single, l as single, ko as singledim fhdmax as single, fhlmax as single, mhdmax as single, mhlmax!, fhmax!, mhmax! dim as singleconst pi = 3.141592653const g = 9.8const = 1025private sub c
2、ommand1_click()dim r as integerdo while truel1 = val(inputbox(请输入波长 l1:, 求解设计波长:, 100)t = val(inputbox(请输入设计波周期 t:, 请输入, 6)d = val(inputbox(请输入设计水深 d:, 请输入, 20)if l1 = 0 thenr = msgbox(请输入一个正数!, 5, 输入错误)if r = 2 thenendend ifelseexit doend ifloopk = 2 * pi / l1kd = k * dthkd = (exp(kd) - exp(-kd) /
3、(exp(kd) + exp(-kd)l2 = g * (t 2) * thkd / (2 * pi)do until abs(l2 - l1) 0.001l1 = l2k = 2 * pi / l1kd = k * dthkd = (exp(kd) - exp(-kd) / (exp(kd) + exp(-kd)l2 = g * (t 2) * thkd / (2 * pi)loopprint 设计波长是:; l2print 波数:; format$(k, 0.0000)end subprivate sub command2_click()endend subprivate sub comm
4、and3_click()h = val(inputbox(请输入设计波高 h:, 请输入, 3)d1 = val(inputbox(请输入桩柱直径 d1:, 请输入, 2)l = val(inputbox(请输入桩柱间距 l:, 请输入, 15).if d / l2 0.5 thenprintprint 相对水深 d/l2:; d / l2print 采用线性波理论计算:elsemsgbox 重新选择计算理论end ifprint 波陡:; h / l2print 相对柱径:; d1 / l2if d1 / l2 4 thenko = 1print koelseif ld 3 thenko =
5、 1.25print koelseif ld = 2 * fhdmax thenfhmax = fhlmaxo = 90e lseif fhlmax = 2 * mhdmax thenmhmax = mhlmaxelseif mhlmax 2 * mhdmax thenmhmax = mhdmax * (1 + (mhlmax / mhdmax) 2) / 4)end ifprintprint 单桩柱最大水平波力矩 mhmax:; mhmaxprint 最大水平波力和最大水平波力矩的相位o:; oe = mhmax / fhmaxprintprint 最大水平波力作用点离海底的距离 e:; e
6、end subpublic function sh(n) as singlesh = (exp(n) - exp(-n) / 2end functionpublic function ch(n) as singlech = (exp(n) + exp(-n) / 2end functionpublic function th(n) as singleth = (exp(n) - exp(-n) / (exp(n) + exp(-n).end functionpublic function arcsin(n) as singlearcsin = atn(n / sqr(-n * n + 1)en
7、d functionpublic function fh() as singlefh = fhdmax * cos() * abs(cos() + fhlmax * sin()end functionpublic function mh() as singlemh = mhdmax * cos() * abs(cos() + mhlmax * sin()end functionprivate sub command5_click()dim i as integeropen c:documents and settingsall users桌面不同相位水平波力.txt for output as
8、 #1 print #1, tab(8); 相位角; spc(3); cos; spc(3); cos|cos|; spc(3); sin;spc(3); fhdmaxcos|cos|; spc(3); fhlmaxsin; spc(6); fhfor i = 0 to 180 step 15 = i * pi / 180print #1, tab(10); i; tab(20); format$(cos(), 0.0000);print #1, tab(30); format$(cos() * abs(cos(), 0.0000);print #1, tab(40); format$(sin
9、(), 0.0000);print #1, tab(55); format(fhdmax * cos() * abs(cos(), 0.00);print #1, tab(70); format(fhlmax * sin(), 0.00);print #1, tab(85); format(fh(), 0.00)next iclose #1end subprivate sub command6_click()dim i as integero pen c:documents and settingsall users 桌面不同相位水平波力矩.txt for output as #2p rint
10、 #2, tab(8); 相位角; spc(3); cos; spc(3); cos|cos|; spc(3); sin; spc(3); fhdmaxcos|cos|; spc(3); mhlmaxsin; spc(6); mhfor i = 0 to 180 step 15 = i * pi / 180print #2, tab(10); i; tab(20); format$(cos(), 0.0000);print #2, tab(30); format$(cos() * abs(cos(), 0.0000);print #2, tab(40); format$(sin(), 0.00
11、00);print #2, tab(55); format(mhdmax * cos() * abs(cos(), 0.00);print #2, tab(70); format(mhlmax * sin(), 0.00);print #2, tab(85); format(mh(), 0.00)next iclose #2end subprivate sub command7_click().dim as singledim h as singledim i as integerdim t as single, m as integer = l * 360 / l2printprint 前后两桩柱的波浪位相差:; t = 0for i = 0 to 180 - h = fh(i) + fh(i + )if t h thent = hm = iend ifnext iprint 发生最大水平合波力的相位 :; m print 前后两桩柱的最大水平合波力为:; tend subprivate sub command8_click()clsend subprivate sub command9_click()dim as singledim m as singledim i as integerdim t as
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 26年ROS1用药适配规范指引
- 2026 减脂期全脂奶课件
- 褥疮预防与护理的未来展望
- 骨科患者的伤口护理
- 2026 女性增肌期饮食调整课件
- 胸腔闭式引流术的操作与护理要点
- 2026 塑型进阶鸡腿课件
- 2026 增肌期控油策略课件
- 骨科护理与疼痛管理
- 鞋子清洁与保养技巧
- 2025年南华大学辐射防护与核安全(防护技术)核安全教育与培训试题(附答案)
- TB-T 2973.1-2024 列车尾部安全防护系统 第1部分:货车列尾
- 中国企业年金研究报告
- 扣件式钢管脚手架培训课件
- 组工信息写作培训课件
- DB63-T 1382-2015 住宅工程质量分户验收规程
- 2026年演出经纪人考试题库500道新版
- 2025年广东深圳江铜融资租赁有限公司招聘笔试
- 2025年四川省凉山州小升初语文试卷
- 特高压技术课件
- 花鸟市场常见鸟类1118
评论
0/150
提交评论