⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 input-biaxial

📁 有限元程序
💻
📖 第 1 页 / 共 2 页
字号:
print " *************************************************\n";print " * A 2-story lumped mass pier example, subjected *\n";print " * to bi-directional earthquake.                 *\n";print " * No axial settlement and torsional rotation.   *\n";print " * Rotational mass inertials are included.       *\n";print " *************************************************\n";/* floor dimensions, story height and mass. */Bx = 4 m;  Ly = 6 m;  t = 0.12 m;  Jx = Ly*Ly/12;  Jy = Bx*Bx/12;H1   = 4 m;       H2   = 3 m;M1   = 1500 kg;   M2   = 1000 kg;Mjx1 = M1*Jx;     Mjx2 = M2*Jx;Mjy1 = M1*Jy;     Mjy2 = M2*Jy;/* pier dimensions and material properties. */bx = 30 cm;  hy = 40 cm;E  = 2000 MPa;  Et = 0.1*E;  fy = 1.2 MPa;nu = 0.25;  G = 800 MPa;/* Define environment variables */NDimension         = 3;NDofPerNode        = 6;MaxNodesPerElement = 2;GaussIntegPts      = 10;/* Generate mesh */StartMesh();x = 0 m ; y = 0 m; z = 0 m;    AddNode( 1, [x,y,z] );                   z = H1;     AddNode( 2, [x,y,z] );                   z = H1+H2;  AddNode( 3, [x,y,z] );AddElmt( 1, [1,2], "pier_attr" );AddElmt( 2, [2,3], "pier_attr" );total_node = 3;/* Define element attributions */ElementAttr("pier_attr"){ type = "FIBER_3D";                          section = "sec_name";                          material = "mat_name";                          fiber = "fib_name";  }SectionAttr("sec_name") { area = bx*hy;                          width = bx; depth = hy;                          unit_weight = 1 N/m;  }MaterialAttr("mat_name") { poisson = nu;  G = G;  shear_yield = fy; }fiber_attr  = Matrix([ 3, 1 ]);fiber_attr[1][1] = E;fiber_attr[2][1] = Et;fiber_attr[3][1] = fy;bx_no_fiber = 30;  hy_no_fiber = 40;no_fiber = bx_no_fiber*hy_no_fiber;fiber_coord = Matrix([ 2, no_fiber ]);fiber_area  = Matrix([ 1, no_fiber ]);fiber_map   = Matrix([ 1, no_fiber ]);dbx = bx/bx_no_fiber;  dhy = hy/hy_no_fiber;for( i=1 ; i <= hy_no_fiber ; i=i+1 ) {   for( j=1; j <= bx_no_fiber ; j=j+1 ) {      k = (i-1)*bx_no_fiber + j;      fiber_coord[1][k] = hy/2 - dhy/2 - (i-1)*dhy;      fiber_coord[2][k] = bx/2 - dbx/2 - (j-1)*dbx;      fiber_area[1][k]  = bx*hy/no_fiber;      fiber_map[1][k]   = 1;   }}FiberAttr( no_fiber, "fib_name" ) { FiberMaterialAttr = fiber_attr;                                    FiberCoordinate   = fiber_coord;                                    FiberArea         = fiber_area;                                    FiberMaterialMap  = fiber_map;  }/* Setup boundary condition and end finite element mesh. */FixNode( 1, [1,1,1,1,1,1] );FixNode( 2, [0,0,1,0,0,1] );FixNode( 3, [0,0,1,0,0,1] );EndMesh();PrintMesh();/* Compute initial stiffness and mass matrices. */   stiff = Stiff();   mass  = Mass([1]);   PrintMatrix(stiff,mass);/* Manually add lumped mass and rotational inertial to mass matrix. */   dof = GetDof([2]);   mass[dof[1][1]][dof[1][1]] = M1;   mass[dof[1][2]][dof[1][2]] = M1;   mass[dof[1][4]][dof[1][4]] = Mjx1;   mass[dof[1][5]][dof[1][5]] = Mjy1;   dof = GetDof([3]);   mass[dof[1][1]][dof[1][1]] = M2;   mass[dof[1][2]][dof[1][2]] = M2;   mass[dof[1][4]][dof[1][4]] = Mjx2;   mass[dof[1][5]][dof[1][5]] = Mjy2;/* Solve for eigenvalues and eigenvectors. */   no_eigen = 4;   eigen = Eigen(stiff, mass, [no_eigen]);   eigenvalue  = Eigenvalue(eigen);   eigenvector = Eigenvector(eigen);   for(i=1 ; i<=no_eigen ; i=i+1) {      w = sqrt( eigenvalue[i][1] );      print "Mode",i,",\tw=",w,",\tperiod=",2*PI/w,"\n";   }   PrintMatrix(eigenvector);   w1 = sqrt( eigenvalue[1][1] );   w2 = sqrt( eigenvalue[2][1] );/* Setup Rayleigh damping and damping matrix */   rdamping = 0.05;   A0 = 2*rdamping*w1*w2/(w1+w2);   A1 = 2*rdamping/(w1+w2);   damp = A0*mass + A1*stiff;print "\n";print " *************************************************\n";print " * Ground acceleration records in two directions *\n";print " * 1940 EL CENTRO RECORD, dir-X=S00E, dir-Y=S90W *\n";print " *************************************************\n";ground_accel_x = ColumnUnits( [    -31.60;   -17.70;    -1.48;    13.36;    30.10;    45.02;    62.10;    76.36;     94.15;   106.63;   118.72;   125.17;   133.72;   110.25;    90.69;   -47.98;    -94.24;   -65.38;   -74.24;   -43.92;   -30.46;    -7.62;     3.64;    20.17;     34.43;    45.88;    68.36;    21.87;  -104.39;   -61.72;   -68.88;   -40.65;    -23.61;     8.52;   -27.19;   -78.76;   -65.42;   -67.15;   -59.12;   -49.27;    -40.22;   -30.38;   -21.40;   -11.48;    -2.54;     6.59;    -4.55;   -17.86;    -33.80;   -38.25;   -29.00;   -24.39;   -13.96;    -5.06;     6.47;    15.73;     25.69;    -4.63;   -15.46;    -2.38;    -0.38;    12.73;    21.43;    33.95;     43.68;    52.85;     7.81;     8.68;    26.08;    26.32;    51.08;    52.46;     79.50;   -37.46;   -52.31;   -28.05;   -22.31;     2.02;    25.76;   -42.82;    -59.39;   -42.98;   -46.56;   -30.81;   -22.82;    -9.27;    -5.77;   -27.35;    -13.57;   -14.08;    -5.10;    -0.14;    10.96;    18.40;    23.13;     7.93;     -2.07;   -10.46;     2.22;     7.50;    21.55;    31.71;    46.67;    57.38;     67.58;    15.76;     0.33;     9.39;    10.73;    -2.98;    -6.60;     4.82;      7.30;    18.84;    24.58;    36.87;    43.60;    56.16;    63.32;    75.76;     72.26;    77.30;    68.84;    48.40;   -48.33;   -22.15;   -15.93;   -13.05;    -44.83;   -66.20;   -97.82;   -80.53;   -73.05;   -52.66;   -38.61;   -13.61;      5.25;    31.32;    51.12;    70.76;    -3.09;    -7.46;    10.41;    16.79;     37.89;    55.25;    72.14;    95.88;    65.53;   -55.14;   -40.14;   -43.68;    -36.52;   -19.27;   -50.02;   -83.92;   -64.47;   -67.42;   -52.23;   -44.55;    -31.24;   -20.89;   -22.23;   -48.05;   -48.41;   -46.40;   -45.89;   -29.04;    -22.31;     1.71;   -32.46;   -65.14;   -34.63;   -38.64;   -16.40;    -6.60;     11.75;    24.70;    33.68;    17.77;     6.99;    -1.87;    10.69;    16.71;     30.10;    39.86;    52.42;    62.42;    72.46;    49.62;    24.39;     7.22;     11.55;    13.88;    18.72;     8.44;    -4.12;    -7.42;    -5.26;    -9.83;    -10.57;    -6.99;    -3.53;     4.98;    14.11;    21.99;     9.23;    -2.42;    -17.66;    -6.05;     2.93;     8.25;    -5.89;    -2.78;     2.34;     7.46;     14.15;    19.27;     5.37;    -2.07;    -5.18;    -0.61;     2.18;     0.57;     -4.55;    -2.23;    -1.44;     0.69;     2.54;    -3.01;   -12.78;   -17.38;    -10.42;   -10.10;    -7.78;    -5.89;    -1.52;     7.18;    -5.06;    -4.39;     -2.15;    -4.98;    -5.18;    -4.71;    -0.89;     2.06;     8.44;    13.17;     26.95;    29.86;     6.43;   -11.16;    -5.69;    -2.46;     5.45;     1.08;     -9.43;   -19.20;   -17.66;    -9.31;    -2.50;     5.45;    11.79;    15.69;      4.03;    -7.11;    -8.84;    -4.04;    -8.92;    -6.20;    -2.98;     1.28;      4.47;     9.66;     8.32;     2.30;    -1.12;     7.06;    16.32;    18.56;      6.71;     2.81;    -1.68;    -1.64;     1.24;     2.85;     9.23;    13.68;     19.86;    20.49;    15.92;    14.86;    21.20;    28.95;    13.56;    15.37;      3.05;    -8.84;   -10.61;   -16.75;   -17.07;   -19.35;   -17.86;   -18.84;     -3.05;     6.20;    -9.00;   -20.18;   -21.68;   -15.06;   -16.75;   -12.94;    -13.25;   -11.24;   -11.24;   -11.40;   -14.39;   -12.98;    -9.35;    -3.88;      2.62;    10.25;    11.39;    13.28;    12.62;    13.28;    10.49;    11.20;      3.60;     7.62;     4.54;    14.31;   -34.71;   -53.92;   -53.64;   -54.12;    -47.78;   -41.83;   -33.45;   -26.44;   -18.29;   -10.97;    -3.17;    -4.39;     -7.98;    -6.60;     2.54;     5.61;     1.16;     9.58;    22.10;    33.32;     46.43;    65.92;    42.93;   -44.12;   -15.22;   -18.33;   -10.10;   -38.61;    -26.64;   -24.31;   -27.19;   -22.54;    -1.87;    14.07;    41.39;    64.90;     36.47;    15.25;    25.45;     4.39;    -4.55;   -21.28;   -33.37;   -46.16;    -46.09;   -32.42;   -15.34;     0.33;    20.65;    45.57;    62.58;   -11.44;      0.53;    -3.01;    -0.02;     4.94;    20.33;    30.61;    -8.88;   -24.04;     -7.46;    -7.70;    -1.91;     2.10;    14.23;    21.51;    28.84;    30.73;     22.50;    11.16;     0.10;     1.71;   -16.79;   -18.57;    -3.92;     5.80;     21.51;     2.85;    -2.98;     0.92;    -5.65;   -11.91;   -18.01;   -14.67;    -10.85;    -5.18;     7.26;    19.62;    32.81;    44.23;    28.05;     8.52;    -15.30;   -11.48;    -9.35;   -35.18;   -39.12;   -24.00;   -14.04;     2.22;      9.39;    19.19;    13.40;     2.38;    -3.01;    -9.04;   -13.29;   -10.18;    -15.61;   -22.46;   -29.24;   -32.42;   -21.40;   -14.20;    -1.24;     1.75;     -2.27;    -1.01;    -7.42;   -16.95;    -3.96;     2.30;    13.91;    23.40;     25.37;     9.19;    -3.05;   -19.47;   -14.83;   -10.38;    -2.70;     4.15;     14.11;     8.68;    -9.75;   -17.66;   -27.54;   -26.83;   -24.04;   -21.01;    -16.87;   -12.98;   -11.28;   -22.11;   -25.53;   -36.56;   -44.39;   -35.49;    -31.12;   -23.72;   -19.43;   -13.92;    -8.64;    -0.02;     7.50;    16.20;     23.32;    29.39;    35.92;    41.16;    43.68;    45.92;    48.28;    51.71;     61.95;    69.94;    79.39;     0.    ], [in/sec/sec] );ground_accel_y = ColumnUnits( [     42.26;    38.25;    41.24;    31.20;    13.29;   -10.10;   -59.55;   -71.55;    -63.80;   -67.89;   -61.12;   -58.17;   -54.31;   -51.04;   -47.66;   -44.07;    -40.49;   -31.32;   -24.67;    -4.98;    20.10;    40.45;    29.07;    21.79;      8.48;    -6.28;   -27.81;   -33.76;   -21.75;   -13.05;     1.67;    16.36;     32.30;    42.78;    35.06;    29.27;    20.18;     4.90;    -8.44;   -25.33;    -28.80;   -13.76;    -2.74;     9.94;    22.15;    34.94;    42.42;    24.39;      9.39;    -7.18;     4.43;    11.75;    29.15;    45.26;    61.44;    68.84;     57.30;    45.33;    29.78;    11.59;    12.58;    19.59;    25.93;    26.75;     24.86;    23.21;    20.10;    19.27;    23.72;    26.24;    30.65;    15.73;     -3.41;   -19.31;    -9.35;    -1.52;     9.00;    17.89;    28.84;    33.37;     22.82;    12.58;     6.56;    15.65;    21.56;    32.78;    36.00;    15.06;     -3.56;   -21.36;   -37.70;   -38.76;   -38.01;   -36.20;   -35.14;   -30.37;    -25.81;   -20.96;   -16.04;   -10.69;    -6.16;    -0.65;    -7.97;   -17.81;    -29.23;   -26.55;   -12.15;    -3.80;     5.41;   -10.30;   -24.47;   -23.68;     -3.80;     4.55;     6.83;     6.99;    16.04;    18.80;    17.74;   -62.78;

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -