From f35ea80659b6a49d1bb2ce1d7d002583f3f40947 Mon Sep 17 00:00:00 2001 From: prashantsinalkar Date: Tue, 10 Oct 2017 12:38:01 +0530 Subject: updated the code --- 587/CH2/EX2.14/example2_14.sce | 45 +++++++++++++++++++++--------------------- 1 file changed, 23 insertions(+), 22 deletions(-) (limited to '587/CH2/EX2.14') diff --git a/587/CH2/EX2.14/example2_14.sce b/587/CH2/EX2.14/example2_14.sce index d49bf3ec8..a6c6d7a36 100755 --- a/587/CH2/EX2.14/example2_14.sce +++ b/587/CH2/EX2.14/example2_14.sce @@ -1,23 +1,24 @@ -clear; -clc; - -//Example2.14[Heat Conduction in a Solar Heated Wall] -//Given:- -L=0.06;//Thickness of wall[m] -k=1.2;//Thermal Conductivity[W/m.degree Celcius] -e=0.85;//Emissivity -a=0.26;//Solar absorptivity -T1=300;//Temp of Inner surface of Wall[K] -q_solar=800;//Incident rate of solar radiation[W/m^2] -T_space=0;//Temp of outer space[K] -//Solution:- -//Integrating results into -function[f]=temp(T) - f(1)=(((a*q_solar)-(e*5.67*10^(-8)*T(1)^4))*(L/k))+T1-T(1); - deff('[f]=temp(T)',['f_1(T)=(((a*q_solar)-(e*5.67*10^(-8)*T(1)^4))*(L/k))+T1-T(1)']) -endfunction - - disp("K",xs,"The outer surface temperature is ") - //First execute the program with x0=[1] then [xs,fxs,m]=fsolve(x0',temp) then re-execute to obtain correct output as for 1st exeution 'xs' is undefined - q=k*(T1-xs)/L; +clear; +clc; + +//Example2.14[Heat Conduction in a Solar Heated Wall] +//Given:- +L=0.06;//Thickness of wall[m] +k=1.2;//Thermal Conductivity[W/m.degree Celcius] +e=0.85;//Emissivity +a=0.26;//Solar absorptivity +T1=300;//Temp of Inner surface of Wall[K] +q_solar=800;//Incident rate of solar radiation[W/m^2] +T_space=0;//Temp of outer space[K] +//Solution:- +//Integrating results into +function[f]=temp(T) + f(1)=(((a*q_solar)-(e*5.67*10^(-8)*T(1)^4))*(L/k))+T1-T(1); + deff('[f]=temp(T)',['f_1(T)=(((a*q_solar)-(e*5.67*10^(-8)*T(1)^4))*(L/k))+T1-T(1)']) +endfunction +x0=[1] +[xs,fxs,m]=fsolve(x0',temp); + disp("K",xs,"The outer surface temperature is ") + //First execute the program with x0=[1] then [xs,fxs,m]=fsolve(x0',temp) then re-execute to obtain correct output as for 1st exeution 'xs' is undefined + q=k*(T1-xs)/L; disp("W/m^2",round(q),"The steady rate of heat conduction through the wall is") \ No newline at end of file -- cgit