资源描述:
《有限元分析课程设计》由会员上传分享,免费在线阅读,更多相关内容在学术论文-天天文库。
1、有限元分析课程设计学院:土木建筑工程学院专业:工程力学班级:力学131学号:3121631023姓名:崔晨露一、单元划分与节点编号二、C语言程序#include#include#defineNE32//单元数#defineNJ45//节点数#defineNZ10//支承数#defineNPJ7//节点荷载数#defineNJ290//节点位移数#defineDD14//半带宽intLXM=0;//类型判别码doubleEO=170e9;//杨氏模量doubleMU=0.3;//泊松比doubleLOU
2、=0;//容重doubleTE=0.1;//厚度doubleAJZ[NJ+1][3]={{0,0,0},{0,0,0},{0,0,0.75},{0,0,1.5},{0,0,2.25},{0,0,3},{0,1.875,0},{0,1.875,0.75},{0,1.875,1.5},{0,1.875,2.25},{0,1.875,3},{0,3.75,0},{0,3.75,0.75},{0,3.75,1.5},{0,3.75,2.25},{0,3.75,3},{0,5.625,0},{0,5.625,0.75},{0,5.625,1.5
3、},{0,5.625,2.25},{0,5.625,3},{0,7.5,0},{0,7.5,0.75},{0,7.5,1.5},{0,7.5,2.25},{0,7.5,3},{0,9.375,0},{0,9.375,0.75},{0,9.375,1.5},{0,9.375,2.25},{0,9.375,3},{0,11.25,0},{0,11.25,0.75},{0,11.25,1.5},{0,11.25,2.25},{0,11.25,3},{0,13.125,0},{0,13.125,0.75},{0,13.125,1.5},{0,
4、13.125,2.25},{0,13.125,3},{0,15,0},{0,15,0.75},{0,15,1.5},{0,15,2.25},{0,15,3}};//共36个节点intJM[NE+1][5]={{0,0,0,0},{0,1,6,7,2},{0,2,7,8,3},{0,3,8,9,4},{0,4,9,10,5},{0,6,11,12,7},{0,7,12,13,8},{0,8,13,14,9},{0,9,14,15,10},{0,11,16,17,12},{0,12,17,18,13},{0,13,18,19,14},{0
5、,14,19,20,15},{0,16,21,22,17},{0,17,22,23,18},{0,18,23,24,19},{0,19,24,25,20},{0,21,26,27,22},{0,22,27,28,23},{0,23,28,29,24},{0,24,29,30,25},{0,26,31,32,27},{0,27,32,33,28},{0,28,33,34,29},{0,29,34,35,30},{0,31,36,37,32},{0,32,37,38,33},{0,33,38,39,34},{0,34,39,40,35},
6、{0,36,41,42,37},{0,37,42,43,38},{0,38,43,44,39},{0,39,44,45,40}};//共32个单元intNZC[NZ+1]={0,1,2,3,4,5,6,7,8,9,10};//1-5号节点的x,y被约束doublePJ[NPJ+1][2+1]={{0,0,0},{0,-3.75e4,50},{0,-7.5e4,60},{0,-7.5e4,70},{0,-7.5e4,80},{0,8e4,83},{0,8e4,87},{0,-3.75e4,90}};doubleAE,JS[NJ*4][4
7、],js[NJ+1][4],KZ[NJ2+1][DD+1],P[NJ2+1],S[3+1][8+1],KE[8+1][8+1],SZ[3+1][32+1];intIE,JE,ME,LE;voidDUGD(int,int);//生成S矩阵,KE矩阵voidmain(){intNJ1,k,IN,IM,jn,m,i,j,z,JO,ii,jj,h,dh,E,l,zl,dl,n;doublePE,c,SIG1,SIG2,SIG3,PYL,RYL,MAYL,MIYL,CETA;doubleWY[8+1],YL[3+1];if(LXM!=0)//平
8、面应力问题与平面应变问题的判别{EO=EO/(1.0-MU*MU);MU=MU/(1.0-MU);}for(i=0;i<=NJ2;i++){for(j=0;j<=DD;j++)KZ[i][j]=0.0;}for(E=1;