麻省理工化工数值分析第二课
- 格式:pdf
- 大小:159.93 KB
- 文档页数:4
⿇省理⼯化⼯数值分析第六课10.34, Numerical Methods Applied to Chemical EngineeringProfessor William H. Green Lecture #6: Modern Methods for Solving Nonlinear Equations.1D-Problemunknown: T of reactor f(x) = 0Q rxn exp(-Ea /RT ) + h(T – T a ) + c(T 4 – T a 4) = 0heat of reaction convection radiation (+) (-) (-)steady state temperatures Make a plot with MATLAB *nethe a t.m* function qdot = netheat(T) % computes the net heating rate of a reactor % qdot = 0 at the steady state qdot = Q.*exp(-Ea/(R.*T)) + h.*(T-Ta) + c.*(T.^4-Ta.^4);Figure 2. Professor Green modified variables Q and c until the plot looked likethe one above. Increased Q and decreased c.T o solve for steady state zerosf(T Figure 1. 1D problem Q = -2e-5; Ea = 5000; R = 1.987; h = 3; Ta = 300; c = 1e-8; Tvec = linspace(300,3000)qdot = netheat(Tvec) plot(Tvec,qdot) Figure 3. Have computer bracket in and find smallrange where plot goes from negative to positive.Bisection10.34 Numerical Methods Applied to Chemical EngineeringLecture 6 Prof. William GreenPage 2 of 4start a,b such that f(a)<0 and f(b) < 0 2b a x +=Figure 4. Funif f(x) · f(a) > 0 a = xelse b = xThis is a problem of TOLERANCEif((b-a) < tol) stopTypes of tolerance Absolute tolerance Relative tolerance atol: has unitsif |f(x)| < atol·f rtol: if(b-a) < rtol*|a| has to be BIG numberIn MATLAB while abs(b-a) > atolx x = (a+b)/2 if f(x)·f(a) > 0 a = x else b = x end *bisect.m* function x = bisect(f,a,b,atolx,rtolx, atolf) %solves f(x) = 0 while abs(b-a) > atolx x = 0.5*(b+a); if((feval(f,x)*feval(f,a))>0) a =x; else b=x; end endCommand Window x = bisect(@netheat,300,2000,0.1,0,0) x = 1.2373e+003CHECK: netheat(1237) = -1.0474 í closeKeep in mind: never get actual solution, but can come closeWe can change tolerances to improve results. ? while(abs(b-a)>atolx)&&(abs(b-a)>(rtolx*abs(a)))x = 0.5*(b+a); AND: must satisfy both conditions if(a bs(fev a l(f,x))x = 1.2363e+003 looser tolerance gives less accurate answerBisection cuts interval by 2 each timeEvery time we cut 3 times, we lose a sig figIn bisection, time grows linearly with the number of significant figures.a < x true < bx true = x soln ± b-a/2Newton’s Method (1-D)evaluates slope of f(x)next guess is the x new that satisfies f(x new)=0for a line from f(x guess) with the slope at f(x guess)Figure 5. Newton’s Method.For a good guess Newton’s method doublesthe number of significant figures after everyiteration; however, we lose robustness ifguess is poorf(x) = f(x0)+f’(x0)*(x-x0)+O(Δx2)0 = f(x guess)+f’(x guess)*(x-x guess)If f’(x guess) ≈ 0 -- doesn’t workx new = x guess – f(x guess)/f’(x guess)Figure 6.NO intersectionAnother drawback is one needs a derivative of the function. Secant Methodsame as Newton’s, but uses f’(x) approximate]1[][]1[][)()()('=kkkkapproxxxxfxfxfBisection method works only for 1D problems, but Newton/Secant can be used for problems with greater dimension 10.34 Numerical Methods Applied to Chemical Engineering Lecture 6 Prof. William Green Page 3 of 4 Broyden’s Method (Multi-dimensional) F(x) = F(x 010.34 Numerical Methods Applied to Chemical EngineeringLecture 6 Prof. William GreenPage 4 of 4f(x) = 0 approx J = B 2][1||||x B BΔ+=+k ][k Outer Product:ΔΔΔΔΔΔ (32221)2312111x F x F x F x F x F x FNewton’s Method (Multi-dimensional)O = F(x 0)+J(x 0)·(x-x 0)J*Δx = -F(x 0) B [k]Δx = -FLU LU [k+1] without redoing factorization Done in detail in homework problem.。
本文由Jericho1989贡献pdf文档可能在WAP端浏览体验不佳。
建议您优先选择TXT,或下载源文件到本机查看。
哈尔滨工程大学硕士学位论文焊接温度场与应力场的数值分析姓名:夏培秀申请学位级别:硕士专业:固体力学指导教师:何蕴增 20050201摘要本文用有限元方法研究了温度场和热应力的分布规律。
模拟对象一是开有圆孔的无限大薄板,另一个是两张对接焊的钢板。
文中对开有圆孔的无限大薄板的研究,一是假设材料的机械性能不随温度变化的情况下,计算出了开有圆孔的无限大薄板的稳恒温度场和弹性热应力的解析解。
二是用有限元法对该薄板进行了两种情况下的计算,一种情况是假设材料的机械性能不随温度变化,另一种情况是材料的机械性能随温度变化。
最后将计算结果进行了对比,证明了有限元解的正确性,同时说明了材料的机械性能随温度变化对板中的径向热应力的影响很大。
本文在对两张钢板对接焊的焊接应力的研究中,首先建立了一种计算简化模型;其次用有限元法对钢板的焊接应力进行了计算,计算结果与文献相吻合,钢板在靠近焊缝的区域内出现了拉应力。
并从理论上分析了该结果的合理性。
焊接应力的存在,会直接影响到结构的承载能力,为了保证焊接结构的安全可靠,准确的推断焊接过程中的力学行为和焊接应力是十分重要的课题。
因此本文的研究成果对科学研究和工程设计都具有重要意义。
关键词:热传导;热应力;热应变;有限元法;对接焊钢板ABSTRACTInpresentpaper,thetemperaturefieldandthedistributionofthermalstresswerestudied,SOthattwotypesofmodelswouldbesimulated.Firstmodel,aninfinitesheetwithacircularopening;secondone,twobutt—weldedsteelboards.Inthestudyofformermodel,theanalyticalsolutionsofsteadytemperaturefieldandelasticthermalstressweregivenwiththeassumptionthatthemechanicalpropertiesofthematerialdonltchangewiththetemperature.AlsoFEMwasintroducedtocalculatetwocases.Firstly,themechanicaipropertiescasedon。
2-1 试求出图2-34所示各杆1-1,2-2,及3-3截面上的轴力,并作轴力图。
(a)解:使用截面法,沿截面1-1将杆分成两段,用F N1表示左段对右段的作用,由平衡方程∑Fx=0,得F N1 = 0同理,可以计算横截面2-2上的轴力F N2,由平衡方程∑Fx=0,得F N2=F(压)。
同理,可以计算横截面3-3上的轴力F N3,由平衡方程∑Fx=0,得F N3=0(b)解: 使用截面法,沿截面1-1将杆分成两段,取出右段并画出受力图,用F N1表示左段对右段的作用,由平衡方程∑Fx=0,得F N1 =F(拉)同理,横截面2-2上的轴力F N2,由截面2-2右段的平衡方程∑F x=0,得F N2= F(压)同理,横截面3-3上的轴力F N3,由截面3-3左段的平衡方程∑F x=0,得F N3=F(拉)2-2 试求图2-35所示钢杆各段内横截面上的应力和杆的总变形。
钢的弹性模量E=200GPa。
解:(1)、内力计算用截面法分别计算左段和右段的内力并作杆的轴力图(b)得 F 左 =4kN (拉) F 右 =4kN (拉)左段:32594F L 4108010L 5.095510m EA 200104104π---⨯⨯⨯∆===⨯⨯⨯⨯⨯左左左左() 右段:32594F L 4104010L 0.63710m EA 2001016104π---⨯⨯⨯∆===⨯⨯⨯⨯⨯右右右右()324F 41012.73MPa A 2104δπ-⨯===⨯⨯左左左324F 410 3.18MPa A 4104δπ-⨯===⨯⨯右右右(2)、各段变形的计算左、右两段的轴力为F 左 、F 右 ,横截面面积A 左、A 右,长度L 左,L 右均不相同,变力计算应力分别进行。
(3)、总变形计算555L L L 5.0955100.63710 5.7310m ---∆=∆+∆=⨯+⨯=⨯左右()计算结果表明,左段伸长5.0955x 10-5m ,右段伸长0.637x 10-5m ,全杆伸长5.73 x10-5m 。
mit化学反应原理MIT化学反应原理引言:MIT化学反应原理是指麻省理工学院(Massachusetts Institute of Technology)在化学反应领域的一系列研究成果和理论原理。
这些原理旨在解释化学反应的机制和动力学过程,为化学工程师和科学家提供理论指导,推动化学反应的发展和应用。
本文将介绍MIT 化学反应原理的几个重要方面,包括速率常数、反应机理和催化剂。
一、速率常数速率常数是描述化学反应速率的物理量,它反映了单位时间内反应物的浓度变化。
MIT化学反应原理研究了速率常数与温度、压力、浓度等因素的关系。
根据Arrhenius方程,速率常数与温度呈指数关系,即随着温度的升高,化学反应速率也会增加。
此外,压力和浓度的增加也会导致速率常数的增加,因为更多的反应物分子之间会发生碰撞,从而增加了反应的可能性。
二、反应机理反应机理是指化学反应过程中各个步骤和中间体的转化关系。
MIT 化学反应原理研究了不同反应机理对反应速率和产物选择性的影响。
一种常见的反应机理是分步反应机理,即反应分为多个连续的步骤。
每个步骤都有自己的速率常数和反应物,通过中间体的转化最终形成产物。
另一种常见的反应机理是并行反应机理,即反应可以同时发生在多个路径上,最终形成不同的产物。
MIT的研究揭示了不同反应机理对反应速率和产物选择性的影响,为化学工程师提供了选择最优反应机理的依据。
三、催化剂催化剂是一种物质,可以在化学反应中降低活化能,加速反应速率,而不参与反应本身。
MIT化学反应原理研究了不同催化剂对反应速率和选择性的影响。
催化剂可以提供新的反应路径,降低反应物之间的反应能垒,从而加速反应速率。
此外,催化剂也可以选择性地促进某些反应路径,从而得到特定的产物。
MIT的研究不仅揭示了催化剂的工作原理,还开发了一系列高效催化剂,为化学工程领域的研究和应用提供了重要支持。
四、应用领域MIT化学反应原理的研究成果在许多领域得到了广泛应用。
10.34, Numerical Methods Applied to Chemical Engineering
Prof. William Green
Lecture 2: Solving Systems of Linear Equations Sample Function and Computing Tips
function k = rate(T, params)
% computes rate constant given temperature and Arrhenius parameters % Bill Green 9/8/06
% inputs:
% T [=] Kelvin
% params = [A; n; Ea]
% A [=] 1/second
% n unitless exponent
% Ea [=] kj/mole
%
% output:
% k [=] 1/second
%
% unpack params
A=params(1);
N params(2);
Ea=params(3);
R = 8.314; % gas constant J/mole-Kelvin
Ea=1000.*Ea;
K=A.*(T.^n).*exp(-Ea./(R.*T));
One additional feature is to include input/output example at bottom of code:
%Tvec = linspace(300,1200);
%params = [1e9;0.5;82];
%kvec=rate(Tvec,params);
%kvec(3)
%ans = 6.1551e-004
Use a lot of ‘%’ comments for
1)The graders to give you partial credit
2)To help you understand your programs when you review
3)For your classmates if they need to operate your program
TEST your program in pieces!!
Otherwise you write a long program and you have no idea where the problem is. “If you’re going to build a laboratory apparatus, you check the power supply, you check if the tubes leak, if the safety features are in place, etc, before you run experiments. It’s the same thing with software.”
In MATLAB you don’t have to describe the dimension of each array.
This can be used to your advantage by setting up the function as follows: function k = rate(T, params) or using a semi-colon: f(x; p) or f(x; θ)
Matrix Algebra
P-norm of a vector:
p N k p k p v v 11||||||⎥⎥⎦
⎤⎢⎢⎣⎡=∑
= p = 1 city-block norm
p = 2 length, Euclidean norm p = ∞ largest element, useful for error tolerances
Triangle Inequality:
p p p w v w v ||||||||||||+≤+for any p; good for proving bounds
Matrix times a vector:
M * v 1) Weighted sum of cols of M
∑
=col i i M v v M r *
2) Column of dot products
⎟⎟⎟⎟⎟⎠
⎞⎜⎜⎜⎜⎜⎝⎛•••⇒⎟⎟⎟⎟⎟⎠⎞⎜⎜⎜⎜⎜⎝⎛=⎟⎟⎟⎟⎟⎠⎞⎜⎜⎜⎜⎜⎝⎛⎟⎟⎟⎟⎟⎠⎞⎜⎜⎜⎜⎜⎝⎛v M v M v M x x x row n row row n r r M r r r r M M M M M L L L L L L L L L L L L L L L L 2121
3) Rotate and Grow/Shrink 4) Linear Mapping 10.34, Numerical Methods Applied to Chemical Engineering Lecture 1 Prof. William Green Page 2 of 5 Figure 1. A linear map.
All four of these are going on and you can use whichever you want in the current
application.
“I teach little tidbits of information. You have to read the textbook if you want details.”
Reactor System Example
Alcohol + Acid Æ Ester + H2O
R-OH + RCOOH <-> RCOOR + H 2O
4
Figure 2. A reactor for alcohol and acid.
6 streams and four compounds = 24 stream variables (not counting energy balance) Assumptions: Stream 3 has same composition Alcohol/Acid as Stream 4
Set BASIS for stream 1 Unknowns: Compositions for streams 2, 4
m 1,ACID + m 4,ACID = m 2,ACID m 1,ROH + m 4,ROH = m 2,ROH m 1,H2O + m 4,H2O = m 2,H2O IR Analysis of Streams 4 and 2: m ROH / m H2O = 0.43
m 2,ROH /m 2,Acid = 1.4 m 2,tot = 2.1m 1,tot
Set up linear matrix of equations as: -1 1 0 0 0 0 -m 1,Acid 0 0 -1 1 0 0 -m 1,ROH 0 0 0 0 -1 1 (x) = -m 1,H2O 0 0 0 1 0 -.43 0 -1.4 0 1 0 0 0 0
10.34, Numerical Methods Applied to Chemical Engineering Lecture 1 Prof. William Green Page 3 of 5 1 0 1 0 1 0 2.1m 1,tot
10.34, Numerical Methods Applied to Chemical Engineering Lecture 1 earrange equations and use elimination to produce upper triangle matrix U
unknowns
••••••••••x 000000
U v
R x N = v N / U NN gives you value of last element Use backward substitution to solve for other
()⎟⎟⎟⎟⎟⎠
⎞⎜⎜⎜⎜⎜⎝⎛••••=⎟⎟⎟⎟⎟⎠⎞⎜⎜⎜⎜⎜⎝⎛
33
3344444
44321*)(000000*U v x U x v v U v x v x x x x x U new col new
=−===⎟⎟⎟⎟⎟⎠⎞⎜⎜⎜⎜⎜⎝⎛••••+⎟⎟⎟⎟⎟⎠⎞⎜⎜⎜⎜⎜⎝⎛•••+⎟⎟⎟⎟⎟⎠⎞⎜⎜⎜⎜⎜⎝⎛••+⎟⎟⎟⎟⎟⎠
⎞⎜⎜⎜⎜⎜⎝⎛•=r r an permute the rows. Can permute the columns, if you permute the variables in the C x vector.
MATLAB examples
) i; m,m); se of the colon ‘:’
=[1 2 3 4; 5 6 7 8]; ,1:2) silly.m
lly sum + i;
function x = backsub(U,v N = 1: (N-1) for i= m = N+1 – x(m) = v(m)/U( v=v-x(m)*U(: ,m) U
M v1=M(:,1) 1 5 m = M(:m = 1 2 5 6 r loop
fo Save as:function sum = si sum = 0 :4 for i = 2 sum = end。