水泵性能曲线的自动绘制

整理文档很辛苦,赏杯茶钱您下走!

免费阅读已结束,点击下载阅读编辑剩下 ...

阅读已结束,您可以下载文档离线阅读编辑

资源描述

[]2005-08-121[](1981-),,,,.VB张荣(,210098)[]在水泵的选型过程中,通常采用多项式的最小二乘法来拟合水泵性能曲线介绍了根据水泵厂家提供的典型数据,利用VisualBasic语言编制程序来实现水泵性能曲线的自动绘制[]水泵性能曲线;VB;自动绘制[]TP39,TV675[]A[]1006-7175(2006)01-0062-03AutomaticDrawingofPumpCharacteristicCurvebyVBZHANGRong(HohaiUniversity,Nanjing210098,China)Abstract:Inthecourseoftypeselectingofthewaterpump,themathematicmodelofleastsquaresurfacefittingisutilizedforthedrawingofthepump.scharacteristiccurve.AccordingtothetypicaldataofferedbytheproducerandwiththeutilizeoftheVisualBasiclanguage,thepump.scharacteristiccurvewillbeautomaticallydrawn.Keywords:pumpcharacteristiccurve;VB;automaticdrawing1计算水泵性能曲线,[1]3,()[2],3,,:H=A1h+A2h+A3hQ2:E=A1e+A2e+A3eQ2:N=A1n+A2n+A3nQ22绘制所选水泵性能曲线:¹;º;»,,,;¼;½500ZLB-85(+4):(1)500ZLB-85(+4)(2)11500ZLB-85(+4)QPm3Ps-1HPmEP%NPkW0.5778.737466.70.8145.818554.50.9263.67444.1(3):0.55~0.94m3Ps;:3.27~9.60m;:67.27~100;:40.09~74.04kW(4),:A1h=5.862659,A2h=17.2250,A3h=-21.24035,A1e=-147.3987,A2e=622.799,A3e=-414.3705,)62)12120061水利科技与经济WaterConservancyScienceandTechnologyandEconomyVol112No11Jan12006A1n=40.7001,A2n=113.4883,A3n=-118.5928:H=5.862659+17.22504Q-21.24035Q2:E=-147.3987+622.799Q-414.3705Q2:N=40.7001+113.4883Q-118.5928Q2(5)1~31233水泵性能曲线绘制程序的编制VB,,(1)(2),311,1,,2:Publich1,h11,h2,h21,h3,h31,q1,q11,q2,q21,q3,q31,e1,e11,e2,e21,e3,e31,n1,n11,n2,n21,n3,n31AsSinglePublicxhAsStringPrivateSubCommand1Click()Dimx,y,z,h,kAsSingleh11=Val(t2.Text):h21=Val(t3.Text):h31=Val(t4.Text)q11=Val(t5.Text):q21=Val(t6.Text):q31=Val(t7.Text)e11=Val(t8.Text):e21=Val(t9.Text):e31=Val(t10.Text)n11=Val(t11.Text):n21=Val(t12.Text):n31=Val(t13.Text)-()h11Callmax(h11,h21,h31,k):h3=k@1.1Callmax(q11,q21,q31,k):q3=k@1.02e3=100Callmax(n11,n21,n31,k):n3=k@1.1Callmin(h11,h21,h31,k):h1=kP1.1Callmin(q11,q21,q31,k):q1=kP1.05Callmin(e11,e21,e31,k):e1=kP1.1Callmin(n11,n21,n31,k):n1=kP1.1-k;min(x,y,z,k),k,Forx=1000To13000Step1000P3form1.Line(x,1000)-(x,7000)NextFory=1000To7000Step500form1.Line(1000,y)-(13000,y)Nextform1.ForeColor=vbBlackxh=t1form1.CurrentX=7000:form1.CurrentY=500:form1.PrintxhFory=1000To7000Step500h=h1+(y-1000)P500@(h3-h1)P12z=Format(h,d00.00d)form1.CurrentX=200:form1.CurrentY=7900-y:form1.PrintzNext-form112000,6000Forx=1000To13000Step2000P3h=q1+(x-1000)P(2000P3)@(q3-q1)P18z=Format(h,d0.00d)form1.CurrentX=x-200:form1.CurrentY=7300:form1.PrintzNextform1.CurrentX=12800form1.CurrentY=7300:z=Format(q3,d0.00d):form1.PrintzFory=1000To4000Step500h=e1+(y-1000)P500@(e3-e1)P6z=Format(h,d00.00d)form1.CurrentX=13300:form1.CurrentY=4900-y:form1.PrintzNext)63)张荣:VB1Fory=5000To7000Step500h=n1+(y-5000)P500@(n3-n1)P4z=Format(h,d00.00d)form1.CurrentX=13300:form1.CurrentY=7000-y+5000:form1.PrintzNextform1.Line(0,0)-(0,8000):form1.Line(0,0)-(14000,0)form1.Line(800,1000)-(800,7000):form1.Line(1000,7200)-(13000,7200)form1.Line(13200,1000)-(13200,4000):form1.Line(13200,5000)-(13200,7000)Forx=1000To13000Step1000P3form1.Line(x,7200)-(x,7250)NextFory=1000To7000Step500form1.Line(750,y)-(800,y)NextFory=1000To4000Step500form1.Line(13200,y)-(13250,y)NextFory=5000To7000Step500form1.Line(13200,y)-(13250,y)Nextform1.CurrentX=300:form1.CurrentY=700:form1.PrintdH(m)dform1.CurrentX=12500:form1.CurrentY=7500:form1.PrintdQ(m3Ps)dform1.CurrentX=13500:form1.CurrentY=4700:form1.PrintdN(KW)dform1.CurrentX=13500:form1.CurrentY=700:form1.Printdn(%)d-Form2.Hide:form1.ShowEndSubPrivateSubCommand2Click()EndEndSub312(2)VBFor,100,0003;(1),;():PrivateSubClick()Dima1h,a2h,a3hAsSingleDima1e,a2e,a3eAsSingleDima1n,a2n,a3nAsSingleDimx,y,z,m,n,v,wAsSinglev=Form2.q1@1.05w=Form2.q3P1.02ForeColor=vbBlackForx=vTowStep(w-v)P100000y=a1h+a2h@x+a3h@x^2m=1000+12000P(Form2.q3-Form2.q1)@(x-Form2.q1)n=1000+6000P(Form2.h3-Form2.h1)@(Form2.h3-y)PSet(m,n)NextForx=vTowStep(w-v)P100000y=a1e+a2e@x+a3e@x^2m=1000+12000P(Form2.q3-Form2.q1)@(x-Form2.q1)n=1000+3000P(Form2.e3-Form2.e1)@(Form2.e3-y)PSet(m,n)NextForx=vTowStep(w-v)P100000y=a1n+a2n@x+a3n@x^2m=1000+12000P(Form2.q3-Form2.q1)@(x-Form2.q1)n=7000-2000P(Form2.n3-Form2.n1)@(y-Form2.n1)PSet(m,n)NextEndSubPrivateSubClick()EndEndSubPrivateSubClick()UnloadMeForm2.ShowEndSub4结语VisualBasic6.0,,,,[3],[][1],,.[M].:,,20011[2].[M].:,19931[3],,.[J].,2001,(4):211)64)12120061水利科技与经济WaterConservancyScienceandTechnologyandEconomyVol112No11Jan12006

1 / 3
下载文档,编辑使用

©2015-2020 m.777doc.com 三七文档.

备案号:鲁ICP备2024069028号-1 客服联系 QQ:2149211541

×
保存成功