資源描述:
《平面梁單元有限元fortran程序.doc》由會員上傳分享,免費(fèi)在線閱讀,更多相關(guān)內(nèi)容在教育資源-天天文庫。
1、programbeam2d!character*64fname1,fname2dimensionmea(100,4),jz(50,2),aai(10,2),aeu(10,2),qq(100)dimensionr(6,6),rt(6,6),ra(6,6),pop(6),po(6)dimensionakep(6,6),ake(6,6),p(300),x(100),y(100)dimensionld(300),is(6),a(50000),upe(6),ppe(6),ue(6)open(1,file='fname1_b.txt')open(2,file='fn
2、ame2_b.txt')read(1,*)nn,ne,nm,na,ncwrite(*,*)NN,NE,NM,NA,NCnf=3nd=2nfd=nf*ndn=nn*nfdo50i=1,nn50read(1,*)k,x(i),y(i),(p(nf*(i-1)+j),j=1,nf)read(1,*)((jz(i,j),j=1,2),i=1,nc)do100i=1,ne100read(1,*)ie,(mea(i,j),j=1,4),qq(i)read(1,*)((aai(i,j),j=1,2),i=1,na)read(1,*)((aeu(i,j),j=1,2),
3、i=1,nm)close(1)write(2,460)nn,ne,nm,na,ncwrite(2,465)(i,x(i),y(i),p(3*i-2),p(3*i-1),p(3*i),i=1,nn)write(2,470)((jz(i,j),j=1,2),i=1,nc)write(2,475)(i,(mea(i,j),j=1,4),i=1,ne)write(2,480)((aai(i,j),j=1,2),i=1,na)write(2,485)((aeu(i,j),j=1,2),i=1,nm)460format(/5x,'theinputofnn,ne,nm
4、,na,nc'//(5x,5i5))465format(/5x,'theinputofx,y,p'//(5x,i5,5f10.2))470format(/5x,'theinputofjz'//(5x,i5,5x,i5))475format(/5x,'theinputofmea,qq'//(5x,i5,5x,4i5,f10.2))480format(/5x,'theinputofaai'//(5x,i5,5x,2e15.6))485format(/5x,'theinputofaeu'//(5x,i5,5x,2e15.6))!cstructurestiffn
5、essstatementcallfld(nn,ne,mea,nf,nd,n,nt,ld)do500i=1,nt500a(i)=0do600ie=1,necallkep(nn,ie,mea,aeu,aai,x,y,akep)callcr(nn,ie,mea,x,y,r)calltran(6,6,r,rt)calldot(6,6,6,rt,akep,ra)calldot(6,6,6,ra,r,ake)callfis(ie,mea,nf,nd,nfd,is)do560i=1,nfddo560j=1,nfdif(is(i)-is(j))560,520,52052
6、0ni=is(i)ij=ld(ni)-ni+is(j)a(ij)=a(ij)+ake(i,j)560continue600continue!cequivalentnodeforcedo700ie=1,necallfixf(nn,ne,ie,mea,x,y,qq,pop)callcr(nn,ie,mea,x,y,r)calltran(6,6,r,rt)calldot(6,6,1,rt,pop,po)callfis(ie,mea,nf,nd,nfd,is)do650i=1,nfdni=is(i)p(ni)=p(ni)-po(i)650continue700c
7、ontinuecallfcc(nc,n,nt,nf,jz,ld,a)calldecom(n,nt,a,p,ld)write(2,850)(i,p(3*i-2),p(3*i-1),p(3*i),i=1,nn)write(2,860)do800ie=1,necallkep(nn,ie,mea,aeu,aai,x,y,akep)callcr(nn,ie,mea,x,y,r)callfis(ie,mea,nf,nd,nfd,is)do750i=1,nfdni=is(i)ue(i)=p(ni)750continuecalldot(6,nfd,1,r,ue,upe)
8、calldot(6,6,1,akep,upe,ppe)callfixf(nn,n