Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

How would i go about coding this Calculate the temperature distribution across a metal plate using a finite difference method. Use finite central difference. Assume

How would i go about coding this Calculate the temperature distribution across a metal plate using a finite difference method.
Use finite central difference.
Assume steady conduction and that there is no heat conduction in the z-direction.
The plate is 2.5m by 2.5m, use an interval size of 0.125
The boundary conditions are
Tleft=50c,Ttop=20C,Tright=20c,Tbottom=100C
Make sure your output is in kelvin
Function ?
function [T, gridx,gridy, A, b]= heat_conduction(Tboundary, Lx, Ly, dx)
% extract boundary conditions
Tleft = Tboundary(1);
Ttop = Tboundary(2);
Tright = Tboundary(3);
Tbottom = Tboundary(4);
% calc number of intervals in x and y direction
% setup grid of points in a vector of gridx and grid y
% create adjacency matrix
A=zeros(n**m);
for i=1:1:n**m
for j=1:1:n**m
% set diagnonals of A to -4
% calc distance between two of the grid points
% if distance is less than dx, set A element to 1
end
end
% apply boundary conditions
% cycle through each point to determine the boundary condition it is in
if %bottom left corner
elseif % bottom right corner
elseif %top left corner
image text in transcribed

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_2

Step: 3

blur-text-image_3

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

Learn Mysql The Easy Way A Beginner Friendly Guide

Authors: Kiet Huynh

1st Edition

B0CNY7143T, 979-8869761545

More Books

Students also viewed these Databases questions