当前位置:网站首页>Matlab finite element calculation
Matlab finite element calculation
2022-07-20 11:48:00 【studyer_ domi】
1、 Content abstract
A little
394- Can communicate 、 consulting 、 Answering question
2、 Content description
3、 Simulation analysis
% =====================================================================
clear;
clc;
close all
%% part1
E = 100e9; % elastic modulus
NU = 0.3; % possion ratio
th = 2e-3; % thickness
w = BilinearQuadElementStiffness(E,NU,th,0,0,0.03,0,0.03,0.01,0,0.01,2)
% This w Is the stiffness matrix of the first question
%% part2
w1 = BilinearQuadElementStiffness(E,NU,th,0,0,0.01,0,0.01,0.03,0,0.03,2);
w2 = BilinearQuadElementStiffness(E,NU,th,0,0.03,0,0.04,0.03,0.04,0.03,0.03,2);
K = zeros(14,14,'double');
K = BilinearQuadAssemble(K,w1,1,2,3,4);
K = BilinearQuadAssemble(K,w2,4,5,6,7);
delta = pi/2;
amp = 200e6*2e-3*10e-3/2;
Fx1 = amp*sin(delta+pi);
Fy1 = amp*cos(delta+pi);
Fx2 = amp*sin(delta+pi);
Fy2 = amp*cos(delta+pi);
% ===================== 2 elements =================
k = [K(3:8,3:8) K(3:8,10:14);K(10:14,3:8) K(10:14,10:14)];
F = zeros(11,1);
F(8) = Fx1;F(9) = Fy1;
F(10) = Fx2;F(11) = Fy2;
U = k\F
U_2 = [0;0;U(1:6);0;U(7:end)]
F_2 = K*U_2;
u1 = U_2(1:8);
sigma1 = BilinearQuadElementStresses(E,NU,0,0,0.01,0,0.01,0.03,0,0.03,2,u1);
y2_1 = BilinearQuadElementPStresses(sigma1)/E % strain
u2 = U_2(7:14);
sigma2 = BilinearQuadElementStresses(E,NU,0,0.03,0,0.04,0.03,0.04,0.03,0.03,2,u2);
y2_2 = BilinearQuadElementPStresses(sigma2)/E % strain
%% 4 individual elements
w1 = BilinearQuadElementStiffness(E,NU,th,0,0,0.01,0,0.01,0.015,0,0.015,2);
w2 = BilinearQuadElementStiffness(E,NU,th,0.01,0.015,0,0.015,0,0.03,0.01,0.03,2);
w3 = BilinearQuadElementStiffness(E,NU,th,0,0.03,0.01,0.03,0.01,0.04,0,0.04,2);
w4 = BilinearQuadElementStiffness(E,NU,th,0.01,0.03,0.01,0.04,0.03,0.04,0.03,0.03,2);
K_4 = zeros(20,20,'double');
K_4 = BilinearQuadAssemble(K_4,w1,1,2,3,4);
K_4 = BilinearQuadAssemble(K_4,w2,3,4,5,6);
K_4 = BilinearQuadAssemble(K_4,w2,5,6,7,8);
K_4 = BilinearQuadAssemble(K_4,w2,6,7,10,9);
k = [K_4(3:14,3:14) K_4(3:14,16:20);K_4(16:20,3:14) K_4(16:20,16:20)];
F = zeros(17,1);
F(14) = Fx1;F(15) = Fy1;
F(16) = Fx2;F(17) = Fy2;
U = k\F
U_4 = [0;0;U(1:12);0;U(13:end)]
F_4 = K_4*U_4
u1 = U_4(1:8);
sigma1 = BilinearQuadElementStresses(E,NU,0,0,0.01,0,0.01,0.015,0,0.015,2,u1);
y4_1 = BilinearQuadElementPStresses(sigma1)/E % strain
u2 = U_4(5:12);
sigma2 = BilinearQuadElementStresses(E,NU,0.01,0.015,0,0.015,0,0.03,0.01,0.03,2,u2);
y4_2 = BilinearQuadElementPStresses(sigma2)/E % strain
u3 = U_4(9:16);
sigma3 = BilinearQuadElementStresses(E,NU,0,0.03,0.01,0.03,0.01,0.04,0,0.04,2,u3);
y4_3 = BilinearQuadElementPStresses(sigma3)/E % strain
u4 = [U_4(11:14);U_4(13:14);U_4(17:18)];
sigma4 = BilinearQuadElementStresses(E,NU,0.01,0.03,0.01,0.04,0.03,0.04,0.03,0.03,2,u4);
y4_4 = BilinearQuadElementPStresses(sigma4)/E % strain
%%
figure
x1 = [0 0.01 0.01 0 0];
y1 = [0 0 0.015 0.015 0];
line(x1,y1)
hold on
x2 = [0.01 0.01 0 0];
y2 = [0.015 0.03 0.03 0.015];
line(x2,y2)
hold on
x3 = [0.01 0.01 0 0];
y3 = [0.03 0.04 0.04 0.03];
line(x3,y3)
hold on
x4 = [0.01 0.03 0.03 0.01];
y4 = [0.03 0.03 0.04 0.04];
line(x4,y4)
hold on
xlim([-0.01 0.04])
ylim([-0.004 0.045])
figure
x1 = [0 0.01+U_4(3) 0.01+U_4(5) 0+U_4(7) 0];
y1 = [0 0+U_4(4) 0.015+U_4(6) 0.015+U_4(8) 0];
line(x1,y1)
hold on
x2 = [0.01+U_4(5) 0.01+U_4(11) 0+U_4(9) 0+U_4(7)];
y2 = [0.015+U_4(6) 0.03+U_4(12) 0.03+U_4(10) 0.015+U_4(8)];
line(x2,y2)
hold on
x3 = [0.01+U_4(11) 0.01+U_4(13) 0+U_4(15) 0+U_4(9)];
y3 = [0.03+U_4(12) 0.04+U_4(14) 0.04+U_4(16) 0.03+U_4(10)];
line(x3,y3)
hold on
x4 = [0.01+U_4(11) 0.03+U_4(17) 0.03+U_4(19) 0.01+U_4(13)];
y4 = [0.03+U_4(12) 0.03+U_4(18) 0.04+U_4(20) 0.04+U_4(14)];
line(x4,y4)
hold on
xlim([-0.01 0.04])
ylim([-0.004 0.045])
figure
x1 = [0 0.01 0.01 0 0];
y1 = [0 0 0.015 0.015 0];
line(x1,y1)
hold on
x2 = [0.01 0.01 0 0];
y2 = [0.015 0.03 0.03 0.015];
line(x2,y2)
hold on
x3 = [0.01 0.01 0 0];
y3 = [0.03 0.04 0.04 0.03];
line(x3,y3)
hold on
x4 = [0.01 0.03 0.03 0.01];
y4 = [0.03 0.03 0.04 0.04];
line(x4,y4)
hold on
x1 = [0 0.01+U_4(3) 0.01+U_4(5) 0+U_4(7) 0];
y1 = [0 0+U_4(4) 0.015+U_4(6) 0.015+U_4(8) 0];
line(x1,y1,'LineWidth',2,'color','red')
hold on
x2 = [0.01+U_4(5) 0.01+U_4(11) 0+U_4(9) 0+U_4(7)];
y2 = [0.015+U_4(6) 0.03+U_4(12) 0.03+U_4(10) 0.015+U_4(8)];
line(x2,y2,'LineWidth',2,'color','red')
hold on
x3 = [0.01+U_4(11) 0.01+U_4(13) 0+U_4(15) 0+U_4(9)];
y3 = [0.03+U_4(12) 0.04+U_4(14) 0.04+U_4(16) 0.03+U_4(10)];
line(x3,y3,'LineWidth',2,'color','red')
hold on
x4 = [0.01+U_4(11) 0.03+U_4(17) 0.03+U_4(19) 0.01+U_4(13)];
y4 = [0.03+U_4(12) 0.03+U_4(18) 0.04+U_4(20) 0.04+U_4(14)];
line(x4,y4,'LineWidth',2,'color','red')
hold on
xlim([-0.01 0.04])
ylim([-0.004 0.045])
4、 Reference paper
A little
边栏推荐
猜你喜欢
【手撕STL】bitset(位图)、布隆过滤器
软件测试—学习笔记4
Processing of paging data
关系抽取—OneRel
风格迁移篇---SAnet:风格注意网络下的任意风格转换
20220710 leetcode周赛:移动片段得到字符串
中文同义句在线转换器 - 中文同义句转换器软件
MySQL学习笔记——存储过程与函数
神经网络模型应用实例SPSS - 典型的神经网络模型 - 神经网络模型的应用
TortoiseSVN Error : Previous operation has not finished; run ‘cleanup‘ if it was interrupted异常解决办法
随机推荐
快解析结合微信小程序开发
小白学习MySQL - Generated Columns功能
Appium自动化测试基础 — 操作微信小程序
shell函数数组作业
无线定位技术实验一 TDOA-FDOA联合定位
文件、异常、模块
内网穿透的几种方式
Filesystem compilation bug record
IPv6-基础
Resolved (selenium reports an error) attributeerror: 'webdriver' object has no attribute 'execute_ cdp_ cmd‘
redis电商秒杀设计
JSON. Parse error when parse occurs \n
星耀云、Expfile、库云、飞猫云、Rardisk网盘解析演示
Those configuration parameters of skywalking
旋转数组 189, 153, 154, 33, 81, 10.03
Rotate array 189, 153, 154, 33, 81, 10.03
LeetCode 第 302 场周赛
风格迁移篇--- stargan代码详解以及论文解读翻译
215 "double first-class" candidates took the postgraduate entrance examination and were admitted by this "double non University"!
Win7安装系统,无猫腻