《公路桥梁荷载受力计算全套.docx》由会员分享,可在线阅读,更多相关《公路桥梁荷载受力计算全套.docx(8页珍藏版)》请在优知文库上搜索。
1、公路桥梁荷载受力计算code=1考虑抗扭因素=0不考虑抗扭因素It每根主梁的抗扭惯性矩II每根主梁的抗弯惯性矩RR人行道宽度BB行车道宽度AA主梁间距1.L主梁跨径N主梁个数CO车道数M荷载类型个数1=M=4MI存放各种类型荷载序号I-人群荷载2汽车荷载3-挂车荷载4一一履带车荷载单位采用国际单位*include,stdio.hninclude,stdlib.h#include,alloc.h,#includenprocess.hvoidcomputeMl(intcodezdoubleItzdouble!,doubleRRzdoubleBBzdoubleAA,doubleLLJntNJntCO
2、JntMJntMI4rdouble*MM);intmain()(double*MM,It,11,RR,BB,AA,LL;intiJcode,k,N,M,C0,MI4;FILE*fplz*fp2;charin20zout20zstr30;Primfe请输入初始数据文件名:);scanf(,%s,zin);printf(n请输入结果数据文件名:);scanf(%s,zout);if(fpl=fopen(inzr,)=NULL)printf(,nn打开文件s失败nn,in);exit(0);if(fp2=fopen(outr,w)=NLL)printf(仓U建文件s失败nzout);exit(0);
3、fscanf(fpl,%s%s%s%s%szstr,str,str,str,str);fscanf(fpLd%lf%lf%lf%lf”,&code,&It,&n,&RR,&BB);fscanf(fpl,%s%s%s%s%snzstr,strzstr,str,str);fscanf(fpl,”lf%lf%d%d%d”,&AA,&LL,&N,&CO,&M);for(i=0;i4&Ml)printf(”nM值有误!n)exit(0)if(N4&Ml)printf(”nN值有误!n)exit(0)for(i=0;iM;i+)fscanf(fpl%dMIi);k=(N+l)2;MM=malloc(k*M
4、*sizeof(double);if(MM=NULL)printf(nK值太大了n);retum;for(i=0;ik*M;i+)MMi=0;ComputeMl(CodezItzIIzRRzBBzAAzLLzNzCOzMzMIzMM);for(i=0;iM;i+)switch(MIi)case1:fprintf(fp2z人群荷载)break;case 2:fprintf(fp2/汽车荷载)break;case 3: fprintf(fp2,”挂车荷载)break;case 4: fprintf(fp2zn履带车荷载)break;)fprintf(fp2,nn);for(i=0;ik;i+)fp
5、ntf(fp2,%4d,J+l);for(j=0;jM;j+)fprintf(fp2,%15lf,MMi*M+j);fprintf(fp2znn);)fclose(fpl);fclose(fp2);voidcomputeMl(intcodezdoubleItzdoubleIIzdoubleRRdoubIeBBzdoubleAAzdoubleLLJntNJntCOJntMJntMI4zdouble*MM)(intkjj,z;doubleB,MO,MQMCtemP=O,E,ELTC,CC,TG,Tl,T2,tt;k=(int)(N+l)2;if(N=:LIlnC=OIlAA=O)printf(,输
6、入数据有误!n);return;if(code=l)temp=N;temp=temp*(temp*temp-1.0);temp=AA*AA*temp;temp=N*LL*LLtemp;B=l+0.425*temp*ItII;B=1B;elseB=1.0;tt=N;E=(N+l)/2.0;tt=tt*(tt*tt-1.0)12.0;tt=1.0tt;for(i=0;ik;i+)T1=1.0/N+tt*(E-i-1.0)*(E-1.0)*B;T2=1.0N+tt*(E-i-1.0)*(E-N)*B;TC=(T1+T2)2.O;TG=(T1-T2)(N-1)*AA);forQ=0;jTG*El)temp=2*TC;elsetemp=TC+TG*El;break;case2:CC=1.0;temp=0;for(z=l;ztemp)temp=MC;)break;temp=TC+TG*(BB-4.7)2.0;break;case4:temp=TC+TG*(BB-4.5)2.0;break;)MMi*M+j=temp;)