Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Solve using gauss Seidel rule in matlab the reference is in the second photo be sure done by the rule and show the exact code

Solve using gauss Seidel rule in matlab the reference is in the second photo be sure done by the rule and show the exact code in matlab

8e110575-57c6-4b9c-a5dc-0126792af56a.jpeg 

 

(5%) Solve the below Heat conduction and convection problem using Gauss-Seidel. Cross-reference slides 19 to 23 from 006 Comp CW2.pptx. Make the program able to handle n number of divisions (diagram shows 7). n must be an odd number so there are an even number of nodes in the insulated and uninsulated sections. Order the equations from 2 to n for each row in matrix A (2 in step of 1 to 7 in the diagram below.) As = 0.01 * Ax Ac = 0.01 Function > T = 100 c T 16 17 xint = 4 As = %m^2 5 Ac = %m^2 6%% expandable A and b definition 7 %crete empty A and b matrices 8 9% fill first row 10 11 % fill second to second to last rows 12 13 % fill last row. 14 15% set solution parameters 25 % Iindices = 1:1:n; 26 27 28 29 30 31 32 33 Insulated Insulated T3 L = 25mm 1 function [A, b,x] = heatFlow (h, k, T1, Ta, Tn, L, lambda, tol, max_it, num_divisions) 2 % calc geometry 3 delx = %mm 18 19 % run solution 20 [x, check, j] = GaussSeidel (A, b, lambda, tol, xint, max_it) 21 end 34 35 36 check= 37 end 38 22 23 function [x, check,j] = Gauss Seidel (A, b, lambda, tol,xint,max_it) % calculate new guess for x % apply relaxation. % convergance criterion % reset old and new guesses Code to call your function > 1% set problem parameters h = 2500;w/m^2/K 3 k = 45; %W/m/K 4 T1 100+273; %K 5 Ta = 20+273; %k 6 Tn 40+273; %k 7 L = 50*10^-3; %mm Ax Ta = 20c T4 T5 L = 25mm T6 Save T 8% set solution parameters. 9 lambda 0.8; 10 tol = 0.001; 11 max_it = 100; 12 num_divisions = 7; 13 14 [A,b,x] = heatFlow (h, k, T1, Ta, Tn, L, lambda, tol, max_it, num_divisions) C Reset W mK W mk h = 2500- k= 45- Tg = 40C MATLAB Documentation C Reset Run Function ?

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Income Tax Fundamentals 2013

Authors: Gerald E. Whittenburg, Martha Altus Buller, Steven L Gill

31st Edition

1111972516, 978-1285586618, 1285586611, 978-1285613109, 978-1111972516

More Books

Students also viewed these Databases questions

Question

Solve the relation Exz:Solve therelation ne %3D

Answered: 1 week ago