Azzera filtri
Azzera filtri

1D dimensional transient heat transfer model

2 visualizzazioni (ultimi 30 giorni)
Lindsay Mau
Lindsay Mau il 29 Lug 2020
I am using the implicit method to solve T=[A]^-1[B]. So far I have a code that displays the intial temperatures for 11 nodes. For example, node 10 is 61.51 degrees C after 30 seconds. However, how do I update the code to determine the temperature distribution after 1 hour. I need to find T0-T10. I know I need a for loop. Somehow I need to update the B matrix inside the for-loop so that it changes as time increases.
n= 120; %number of iterations
t=0;
dt=30; %change in time [seconds]
tmax=3600;
A=[-230,50,0,0,0,0,0,0,0,0,0;
50,-460,50,0,0,0,0,0,0,0,0;
0,50,-460,50,0,0,0,0,0,0,0;
0,0,50,-460,50,0,0,0,0,0,0;
0,0,0,50,-460,50,0,0,0,0,0;
0,0,0,0,50,-460,50,0,0,0,0;
0,0,0,0,0,50,-460,50,0,0,0;
0,0,0,0,0,0,50,-460,50,0,0;
0,0,0,0,0,0,0,50,-460,50,0;
0,0,0,0,0,0,0,0,50,-460,50;
0,0,0,0,0,0,0,0,0,50,-330];
rows=11;
B=[-14400;-28800;-28800;-28800;-28800;-28800;-28800;-28800;-28800;-28800;-16400];
%initial
%initial
for i=1:n
T = A\B (:,:);
end
disp (T)

Risposte (0)

Categorie

Scopri di più su Thermal Analysis in Help Center e File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by