Temperature of fluid flowing through pipe

In summary, the temperature change when a fluid flows through a pipe from one end to another is dependent on the following parameters: -cross-sectional diameter of the pipe-viscosity-volumetric flow rate-specific heat of the fluid-length of the pipe
  • #106
Would that be equation number 14.4-7?

Using

Num = (0.4(Re^(1/2)) + 0.06(Re^(2/3)))*Pr^(0.4) (I neglect the viscosity factor, assuming it to be unity)

Given the Reynold number values Re = 53011 and Pr = 0.695, I get

Num = 152.82

k = 0.0346 (air @ 142.5)
x = 0.1

h = Nu*k/x => h = 52.88

Which one do we use?
 
Science news on Phys.org
  • #107
We use the one giving the lowest upper bound, namely #3. From this, it looks like, at least for 35 mph, the ratio of h2 to h1 is close to 1.0. I wonder how much this ratio would vary with speed. Maybe if it doesn't change much with speed, you can use 1.0 for all speeds. This would certainly simplify things for you greatly.

Chet
 
  • #108
We use the one giving the lowest upper bound, namely #3.

You mean the one in post #102, where I got a value of h = 23.43? I think this is rather surprising. I would have expected the value to be higher. Another thing I want to ask: Is our assumption of considering it to be a flat plate wrong? The reason I ask is because the pipe is nothing like a flat plate, its more like a cylinder moving along its height-axis.
 
  • #109
I'll explain later the connection between axial external flow along a cylinder, and flow at the entrance of a flat plate. But, right now, I'm out with my grandchildren. For now, consider the case in which the cylinder diameter is very large (like say a mile). How important would the curvature be then?

Why don't you do the calculation for the case of axial flow along a cylinder using the info in the paper you referenced? I predict you will get about the same result.

Chet
 
  • #110
That is so sweet. Have a nice time with your grand-kids :-)

Okay. I assume you are talking about the equation in slide 22?

Nucyl = 0.3 + (A/B)*C

where, A = 0.62*(Re^(1/2))*(Pr^(1/3))
B = (1 + (0.4/Pr)^(2/3))^(1/4)
C = (1 + (Re/282000)^(5/8))^(4/5)

Using Re = 53011, and Pr = 0.695

Nucyl = 141.4022

k = 0.0346, x = 0.1

h = Nu*k/x = 48.93

When you are free could you let me know if this is all correct? This value is far from the other 'h'. But it seems more correct because I would get a gas temperature that is double the value and that seems right. Should I go with this one?
 
  • #111
No. That equation is for flow across a cylinder, rather than axial. I found a reference that has axial flow, but I don't have my computer with me; it's bookmarked.

Chet
 
  • #112
Post me the link. I need to complete this without much more delay. :-/
 
  • #113
Jay_ said:
Post me the link. I need to complete this without much more delay. :-/
Hi Jay. Unfortunately, I misspoke. I did not bookmark the link, and now I can't find it again. Sorry.

Back to heat transfer in flow over a flat plate, and its relationship to heat transfer in axial flow over a cylinder. Imagine in the case of a cylinder that you increase its radius until it is infinite. Then you end up with a flat plate. So you know that a flat plate is going to be a limiting case of a cylinder. All the "action" in heat transfer and momentum transfer in axial gas flow over a cylinder occurs in very close proximity to the surface; this is the so-called boundary layer region. Outside the boundary layer, the temperature and velocity variation in the air are unaware that the cylinder is there. If the boundary layer is very thin compared to the radius of the cylinder, the curvature of the cylinder is unimportant in determining the heat transfer through the boundary layer, and the system can be treated as a flat plate.

Even though the car is moving through stagnant air, if the car velocity is constant, it doesn't matter whether you regard the car as moving and the air stagnant, or the car stationary and the air blowing backwards over the exhaust. This is just a change in inertial reference frame. But, it makes it much easier to analyze what is happening. So if air is blowing backwards axially along the tailpipe, the leading edge of the tailpipe is at the muffler. The boundary layer builds up in thickness from the muffler (leading edge) toward the back of the tailpipe, in proportion to the square root of distance backward. Since heat has to be conducted through the boundary layer to the fresh air in the free stream, this causes the heat transfer coefficient to decrease with distance measured backwards from the muffler. This can now be recognized as something very similar to what happens in heat transfer to a gas flowing along a flat plate, starting at the leading edge.

The question of the validity of using the correlation for flow over a flat plate to describe flow and heat transfer over a cylinder hinges on the thickness of the thermal boundary layer compared to the radius of the cylinder. If this ratio is low compared to unity, then it is valid to use the flat plate approximation. Let's see how this plays out in our situation. The equation for the heat flux through the boundary layer is given by:
[tex]q= k\frac{ΔT}{δ}[/tex]
where δ is the boundary layer thickness and ΔT is the wall temperature minus the free-stream air temperature. This is the equation we used in freshman physics for heat conduction through a slab of thickness δ. The only question is, "what is the boundary layer thickness δ?" Now, from our heat transfer correlation, we also know that:
[tex]q = h ΔT[/tex]
If we combine these two equations, we get:
[tex]h=\frac{k}{δ}[/tex]
Now, the local Nusselt number for flow over a flat plate from our correlation is given by:
[tex]Nu_x=\frac{hx}{k}[/tex]
where x is the distance from the leading edge of the plate (i.e., in our situation, the distance measured backwards from the muffler). If we combine these two equations, we obtain:
[tex]δ=\frac{x}{Nu_x}[/tex]
So, for x = 10 cm, we calculate δ≈0.5 cm. This compares with a cylinder radius of 3.5 cm, so the ratio of the boundary layer thickness to the cylinder radius is only ≈ 0.15. This validates the use of the flat plate approximation for our situation.

There are lots of factors that can affect the accuracy of the heat transfer coefficient we calculate, and the uncertainties are large (over and above neglecting the curvature of the tailpipe surface). The biggest one is the effect of the muffler. Its presence prevents the existence of a sharp leading edge to the tailpipe. There is also heat from the muffler entering the free-stream air that blows backwards over the tailpipe, and this affects the temperature difference ΔT. There can also be a circulation zone (stagnation zone) that forms in the wake of the muffler which will affect both the air flow and the heat transfer.

To model the heat transfer coefficient very accurately, one would have to construct a computational fluid dynamics (CFD) model of the flow and heat transfer that includes air flow over both the muffler and the exhaust pipe. This is well beyond the scope of what your assignment calls for. Therefore, we will have to live with the inaccuracies, and do the best we can with the correlations we have (using our best judgement). We have gotten about as much as we can out of this approach. That's why I was suggesting earlier some calibration experiments which measure both the exhaust gas temperature out of the tailpipe (or in the muffler) and the surface temperature of the exhaust pipe.

Chet
 
  • #114
Thanks Chet. So ultimately, we are using the value (and equation) in post # 102?

I did not bookmark the link, and now I can't find it again. Sorry.

It might be in your browser history. If you could, dig it out of there. I find it hard to accept that value of the gas being very close to the value of the outside wall.
 
  • #115
Jay_ said:
Thanks Chet. So ultimately, we are using the value (and equation) in post # 102?
Yes.

I find it hard to accept that value of the gas being very close to the value of the outside wall.
On what do you base this? I'm having trouble understanding why the calculated h2 seems low to you.

I might also point out that the lower the value of h2, the better off you are. If h2 were zero, for example, the wall temperature measurement would give you the exact exhaust gas temperature.

Chet
 
  • #116
Okay. Let me use what we have done.
 
  • #117
Hey Chet. I hope you are still watching this thread because I may have questions all of a sudden. Can I use the formulas for the heat capacities in Perry's book table 2-194?

For the gases, N2, CO2 and H2O, we have a neat formula with the temperature variable and the maximum uncertainty is 3% (on that of Nitrogen). I have a question though. The unit is in cal/deg. mol if I need it in J/deg. kg which is the S.I. unit.

So for this conversion I multiply by 4.184 (convert calories to joules) and divide by the molecular weight (convert moles to grams in the denominator) times a 1000 (make it kilograms in the denominator) right?
 
  • #118
Jay_ said:
Hey Chet. I hope you are still watching this thread because I may have questions all of a sudden. Can I use the formulas for the heat capacities in Perry's book table 2-194?
I don't have Perry's Handbook in front of me, but, if the table heading is something like heat capacities for ideal gas region, then yes, these are the formulas you want.
For the gases, N2, CO2 and H2O, we have a neat formula with the temperature variable and the maximum uncertainty is 3% (on that of Nitrogen). I have a question though. The unit is in cal/deg. mol if I need it in J/deg. kg which is the S.I. unit.

So for this conversion I multiply by 4.184 (convert calories to joules) and divide by the molecular weight (convert moles to grams in the denominator) times a 1000 (make it kilograms in the denominator) right?
Yes. Another way to check is to see if it gives you the expected values when used to calculate the Prantdl number.

Chet
 
  • #119
I checked them directly, its right. The equations from Perry have to be multiplied by 4.2 (or 4.184, whichever) and divided by molecular weight to get it in S.I. I don't see why, but I get the answer without having to multiply by 1000. I guess its because they use the "small calorie".

And I am trying to find functions, instead of tables because functions can use temperature as the input to an equation. That way its continuous and not discrete, and any value of temperature can be used.

So I need the following as functions of temperature:

1. Specific heat capacities for N2, CO2 and H2O (CHECK)
2. Thermal conductivity for N2, CO2 and H2O (I have two equations for N2, CO2 which I am yet to verify).
3. Dynamic viscosity for N2, CO2 and H2O (this is giving me a hard time)
4. Dynamic viscosity for air (CHECK)
5. Thermal conductivity for air (CHECK)

If you come across anything (equation, as a function of temperature) do let me know.
 
  • #120
Jay_ said:
I checked them directly, its right. The equations from Perry have to be multiplied by 4.2 (or 4.184, whichever) and divided by molecular weight to get it in S.I. I don't see why, but I get the answer without having to multiply by 1000. I guess its because they use the "small calorie".

Are you expressing Cp in units of kJ/(kg-K)? If so, you, of course, don't need the factor of 1000.
And I am trying to find functions, instead of tables because functions can use temperature as the input to an equation. That way its continuous and not discrete, and any value of temperature can be used.

So I need the following as functions of temperature:

1. Specific heat capacities for N2, CO2 and H2O (CHECK)
2. Thermal conductivity for N2, CO2 and H2O (I have two equations for N2, CO2 which I am yet to verify).
3. Dynamic viscosity for N2, CO2 and H2O (this is giving me a hard time)
Make a semilog graph of viscosity as a function of 1/T. It should come close to a straight line (that you can fit with an equation).
4. Dynamic viscosity for air (CHECK)
5. Thermal conductivity for air (CHECK)

If you come across anything (equation, as a function of temperature) do let me know.
You can always put the data in as discrete values in a table that you can interpolate.
 
  • #121
You can always put the data in as discrete values in a table that you can interpolate.

There are certainly many sites which will allow me to find an equation using polynomial interpolation. But I would imagine that such a basic study of the physical parameters of important (common) gases like N2, CO2 and H2O should have been available now in literature.

But I will do what you are saying. Is it good if I tabulate the results in intervals of 20 degrees, or is that too much, or too less?
 
  • #123
Hi Chet,

In the stage where we are calculating the Nusselt number for the gas, is there a better way to come up with the proportionality constant instead of the graph in BSL? I mean, in my code, I want to actually get the value of the ordinate.

Now, ordinate axis has a complicated looking equation on it which uses the heat transfer coefficient (which we wouldn't have at that point). My question is : Is there a way to calculate the ordinate value instead of looking up the graph?
 
  • #124
Actually, the ordinate is simply Nu/(RePr^(1/3)). No equation is involved. I would fit a piecewise linear variation to the curve, as a function of Re. I would do the fit in the logs. So, once you know Re, you know Nu.

Chet
 
  • #125
But what is this linear variation exactly? What is the equation for it?

The graph in BSL doesn't have a very good resolution. The line of the sketch is not fine, its pretty thick and the ordinate axis is not calibrated.
 
  • #126
In the code I have for now, I am using 0.004 as the proportionality constant. However, there is another issue. The temperature of gas variable seems pretty high.

I put dummy values :

RPM : 88
temperature of pipe wall : 125 C (398 K)
ambient temperature : 35 C (308 K)
mileage : 28 mpg
x : 10 cm (0.1 m)
d : 7 cm (0.07 m)

I get the gas temperature as 1135 K (862 C). Are these values reasonable? If the temperature is 862 C, I imagine the pipe would start to melt?
 
Last edited:
  • #127
Jay_ said:
In the code I have for now, I am using 0.004 as the proportionality constant. However, there is another issue. The temperature of gas variable seems pretty high.

I put dummy values :

RPM : 88
temperature of pipe wall : 125 C (398 K)
ambient temperature : 35 C (308 K)
mileage : 28 mpg
x : 10 cm (0.1 m)
d : 7 cm (0.07 m)

I get the gas temperature as 1135 K (862 C). Are these values reasonable? If the temperature is 862 C, I imagine the pipe would start to melt?
No. It doesn't seem reasonable. What were your values of h1 and h2?

Chet
 
  • #128
Jay_ said:
But what is this linear variation exactly? What is the equation for it?

The graph in BSL doesn't have a very good resolution. The line of the sketch is not fine, its pretty thick and the ordinate axis is not calibrated.
Use 0.004 from 4000 to 10000, and 0.003 at 60000, with a linear fit on the log of the ordinate between 10000 and 60000.

I hate to bring this up at such a late date, but for the gas flow in the pipe, the figure assumes that the gas velocity profile is fully developed (parabolic) at the entrance to the pipe (exit of the muffler). But, for such a short pipe, this is unlikely to be the case. It will be closer to a flat velocity profile, with a boundary layer on the inside wall of the pipe. Under these circumstances, the correct correlation to use is the flat plate approximation (even inside the pipe), with the free stream gas velocity taken equal to the mass flow rate in the pipe divided by the gas density times the cross sectional area. I am recommending that you run a quick scouting calculation to see what value you get for h1 using this approach.

Chet
 
  • #129
Use 0.004 from 4000 to 10000, and 0.003 at 60000, with a linear fit on the log of the ordinate between 10000 and 60000.

Okay. So that fixes it.

Regarding your second paragraph - are you saying I need to calculate the Reynolds number, Nusselt number and heat transfer coefficient for the inside the same way I did for the outside and see what results I get.

In this case, I would need the density of the gas mixture because the Reynolds equation requires it. And the velocity would be the velocity of the gas? And then I use 0.332(Re^0.5)(Pr^(1/3)) ?
 
  • #130
Jay_ said:
Okay. So that fixes it.
Yes.
Regarding your second paragraph - are you saying I need to calculate the Reynolds number, Nusselt number and heat transfer coefficient for the inside the same way I did for the outside and see what results I get.
Yes, just to see.
In this case, I would need the density of the gas mixture because the Reynolds equation requires it. And the velocity would be the velocity of the gas?

No. You don't need the density. ρv=w/A.
And then I use 0.332(Re^0.5)(Pr^(1/3)) ?
Yes
 
  • #131
Okay. I made a huge blunder. When calculating the speed of the flat plate for hout, I multiplied the RPM data with the diameter of the pipe, it should the diameter of the tire!

Now I get hout = 10.7, and hin = 3.66. Do these values sound reasonable in SI units?

This time the dummy data was similar :

RPM : 88
temperature of pipe wall : 125 C (398 K)
ambient temperature : 35 C (308 K)
mileage : 28 mpg
tire diameter : 26 inches (0.6604 m) (The one I missed out!)
x : 10 cm (0.1 m)
d : 7 cm (0.07 m)

I get gas temperature to be 661 K (388 C)
 
  • #132
The car speed seems very low, and those h's seem very low. Please show the details of the calculations.

Chet
 
  • #133
I input the car speed. 88 RPM is slow, but a car can move at that speed right? In mph this speed is 6.8, which is indeed very slow. I increased the RPM to 400, which makes the speed in in mph as 30.94 (tire diameter is 26 inches).

Its hard to show the whole code. But I have attached a screen shot of the values (all are supposed to be in S.I. units). The ones that look odd, should probably tell me where I made a mistake?

I have attached a word file to this. The funny thing is, when I keep the pipe temperature the same (125 C) and increase the speed of the car (from 88 rpm to 400 rpm), the gas temperature inside decreases! I also found that this 'saturates' to the value of the pipe temperature (125 C), if I increase the speed indefinitely. I made rpm 1010 and then 1020 and found it comes to the pipe temperature in both instances.

In any case, below (in the attached .docx file) is the data I got for 400 rpm. Everything should be in S.I. units. So could you see which is odd?
 

Attachments

  • Values.docx
    30.1 KB · Views: 188
Last edited:
  • #134
Jay_ said:
I input the car speed. 88 RPM is slow, but a car can move at that speed right? In mph this speed is 6.8, which is indeed very slow. I increased the RPM to 400, which makes the speed in in mph as 30.94 (tire diameter is 26 inches).

Its hard to show the whole code. But I have attached a screen shot of the values (all are supposed to be in S.I. units). The ones that look odd, should probably tell me where I made a mistake?

I have attached a word file to this. The funny thing is, when I keep the pipe temperature the same (125 C) and increase the speed of the car (from 88 rpm to 400 rpm), the gas temperature inside decreases! I also found that this 'saturates' to the value of the pipe temperature (125 C), if I increase the speed indefinitely. I made rpm 1010 and then 1020 and found it comes to the pipe temperature in both instances.

In any case, below (in the attached .docx file) is the data I got for 400 rpm. Everything should be in S.I. units. So could you see which is odd?
It's very hard to tell without seeing the details of the calculations. One way of checking, of course, is to do the calculation by hand, which shouldn't take too much effort. So bite the bullet.

The heat transfer coefficient inside looks lower than what you calculated before for the same car speed, and the Re looks higher. Why? The Pr outside should be 0.69, shouldn't it? The Pr inside looks a little high (maybe), since the outside gas is mostly N2.

Chet
 
  • #135
The inside and outside gases are mostly N2. If the Pr values are wrong, then the cp, k and mu values may be wrong. I will check my functions.

The values may be slightly off because I am deriving them from the temperature polynomial function for cp, k, mu, rho (density) etc.
 
  • #136
Calculations :

This is the simple code I put in MATLAB :

Code:
rpm = 400; %input('Enter RPM data :\n');
T_pipe = 125; %input('\nEnter pipe temperature in deg. celsius :\n');
d = 7; %input('\nEnter diameter of pipe in centimeters : \n');
x = 10; %input('\nEnter distance of sensor from pipe end in centimeters : \n');
T_amb = 35; %input('\nEnter ambient temperature in deg. celsius :\n');
mpg = 28; %input('\nEnter mileage for the given drive cycle in miles per gallon: \n');
D = 26; %input('\nEnter the diameter of the tire in inches: \n');

D = D*2.54/100;
d = d/100;
x = x/100;
T_pipe = T_pipe + 273.15;
T_amb = T_amb + 273.15;
v = pi*D*rpm/60;
mph = 2.23694*v;
V_fuel = mph/(3600*mpg);
M_fuel = 6.073*V_fuel;

m_gas = 0.45359*15.7*M_fuel;

T_gas = 2.5*T_pipe;
T_gas_est = 0;

while (abs(T_gas - T_gas_est) > 0.2)

T_gas_est = T_gas;
Tf_in = mean([T_gas_est T_pipe]);
Tf_out = mean([T_amb T_pipe]);

sig_phi = SIGMA_PHI(Tf_in);                   % I can post HOW these functions are defined if needed
u_gas = VISCOSITY_GAS(Tf_in, sig_phi);   % SIGMA_PHI and all these are based from the mixing 
k_gas = THERMAL_GAS(Tf_in, sig_phi);      % rules in BSL
cp_gas = SPECIFIC_HEAT_GAS(Tf_in);

Re_in = (4*m_gas)/(u_gas*pi*d);
Pr_in = cp_gas*u_gas/k_gas;

Nu_in = 0.004*(Re_in)*(Pr_in^(1/3));  % Find equation for ordinate!
h_in = Nu_in*k_gas/d;

rho_air = DENSITY_AIR(Tf_out);       % I can post HOW these functions are defined if needed
u_air = VISCOSITY_AIR(Tf_out);
k_air = THERMAL_AIR(Tf_out);
cp_air = SPECIFIC_HEAT_AIR(Tf_out);

Re_out = (v*rho_air*x)/u_air;
Pr_out = (cp_air*u_air)/k_air;

Nu_out = 0.332*(Re_out^(1/2))*(Pr_out^(1/3));

h_out = Nu_out*k_air/x;

T_gas = (h_out/h_in)*(T_pipe - T_amb) + T_pipe;

end

Its pretty straight forward what we did, but merely put as code. Now the functions for obtaining the physical parameters of the gas and that of air, I took from the sources we discussed and I have them as polynomials in temperature. That's why I put the input as Tf_in (for the gases) and Tf_out (for air), these are basically the film temperatures.

Also, I changed the temperature from 125 C to 250 C, like we did earlier and I got a temperature of 527 C for the gas. Seems okay to me. Do you feel its all right?
 
Last edited:
  • #137
Okay, I just put the code in which T_pipe is still 125 C, sorry! Below I have attached the data I got for T_pipe being 250 C and I changed the rpm to 455 because it corresponds to the value of 35 mph we had considered earlier.

Code:
rpm = 455; %input('Enter RPM data :\n');
T_pipe = 250; %input('\nEnter pipe temperature in deg. celsius :\n');
d = 7; %input('\nEnter diameter of pipe in centimeters : \n');
x = 10; %input('\nEnter distance of sensor from pipe end in centimeters : \n');
T_amb = 35; %input('\nEnter ambient temperature in deg. celsius :\n');
mpg = 28; %input('\nEnter mileage for the given drive cycle in miles per gallon: \n');
D = 26; %input('\nEnter the diameter of the tire in inches: \n');

D = D*2.54/100;
d = d/100;
x = x/100;
T_pipe = T_pipe + 273.15;
T_amb = T_amb + 273.15;
v = pi*D*rpm/60;
mph = 2.23694*v;
V_fuel = mph/(3600*mpg);
M_fuel = 6.073*V_fuel;

m_gas = 0.45359*15.7*M_fuel;

T_gas = 2.5*T_pipe;
T_gas_est = 0;

while (abs(T_gas - T_gas_est) > 0.01)

T_gas_est = T_gas;
Tf_in = mean([T_gas_est T_pipe]);
Tf_out = mean([T_amb T_pipe]);

sig_phi = SIGMA_PHI(Tf_in);
u_gas = VISCOSITY_GAS(Tf_in, sig_phi);
k_gas = THERMAL_GAS(Tf_in, sig_phi);
cp_gas = SPECIFIC_HEAT_GAS(Tf_in);

Re_in = (4*m_gas)/(u_gas*pi*d);
Pr_in = cp_gas*u_gas/k_gas;

Nu_in = 0.004*(Re_in)*(Pr_in^(1/3));  % Find equation for ordinate!
h_in = Nu_in*k_gas/d;

rho_air = DENSITY_AIR(Tf_out);
u_air = VISCOSITY_AIR(Tf_out);
k_air = THERMAL_AIR(Tf_out);
cp_air = SPECIFIC_HEAT_AIR(Tf_out);

Re_out = (v*rho_air*x)/u_air;
Pr_out = (cp_air*u_air)/k_air;

Nu_out = 0.332*(Re_out^(1/2))*(Pr_out^(1/3));

h_out = Nu_out*k_air/x;

T_gas = (h_out/h_in)*(T_pipe - T_amb) + T_pipe;

end

I get the value of the temperature of gas = 511 C. Does it seem okay? When we did calculations earlier, we didn't actually use the mixing rules in BSL. One thing that bothers me is that the temperature is the same 250 C, and when I change the speed higher, I get a LOWER temperature value (527 C @ 400 rpm, as opposed to 511 C @ 455 rpm).
 

Attachments

  • Values.docx
    34.4 KB · Views: 190
  • #138
Jay_ said:
Calculations :

This is the simple code I put in MATLAB :

Code:
rpm = 400; %input('Enter RPM data :\n');
T_pipe = 125; %input('\nEnter pipe temperature in deg. celsius :\n');
d = 7; %input('\nEnter diameter of pipe in centimeters : \n');
x = 10; %input('\nEnter distance of sensor from pipe end in centimeters : \n');
T_amb = 35; %input('\nEnter ambient temperature in deg. celsius :\n');
mpg = 28; %input('\nEnter mileage for the given drive cycle in miles per gallon: \n');
D = 26; %input('\nEnter the diameter of the tire in inches: \n');

D = D*2.54/100;
d = d/100;
x = x/100;
T_pipe = T_pipe + 273.15;
T_amb = T_amb + 273.15;
v = pi*D*rpm/60;
mph = 2.23694*v;
V_fuel = mph/(3600*mpg);
M_fuel = 6.073*V_fuel;

m_gas = 0.45359*15.7*M_fuel;

T_gas = 2.5*T_pipe;
T_gas_est = 0;

while (abs(T_gas - T_gas_est) > 0.2)

T_gas_est = T_gas;
Tf_in = mean([T_gas_est T_pipe]);
Tf_out = mean([T_amb T_pipe]);

sig_phi = SIGMA_PHI(Tf_in);                   % I can post HOW these functions are defined if needed
u_gas = VISCOSITY_GAS(Tf_in, sig_phi);   % SIGMA_PHI and all these are based from the mixing 
k_gas = THERMAL_GAS(Tf_in, sig_phi);      % rules in BSL
cp_gas = SPECIFIC_HEAT_GAS(Tf_in);

Re_in = (4*m_gas)/(u_gas*pi*d);
Pr_in = cp_gas*u_gas/k_gas;

Nu_in = 0.004*(Re_in)*(Pr_in^(1/3));  % Find equation for ordinate!
h_in = Nu_in*k_gas/d;

rho_air = DENSITY_AIR(Tf_out);       % I can post HOW these functions are defined if needed
u_air = VISCOSITY_AIR(Tf_out);
k_air = THERMAL_AIR(Tf_out);
cp_air = SPECIFIC_HEAT_AIR(Tf_out);

Re_out = (v*rho_air*x)/u_air;
Pr_out = (cp_air*u_air)/k_air;

Nu_out = 0.332*(Re_out^(1/2))*(Pr_out^(1/3));

h_out = Nu_out*k_air/x;

T_gas = (h_out/h_in)*(T_pipe - T_amb) + T_pipe;

end

Its pretty straight forward what we did, but merely put as code. Now the functions for obtaining the physical parameters of the gas and that of air, I took from the sources we discussed and I have them as polynomials in temperature. That's why I put the input as Tf_in (for the gases) and Tf_out (for air), these are basically the film temperatures.

Also, I changed the temperature from 125 C to 250 C, like we did earlier and I got a temperature of 527 C for the gas. Seems okay to me. Do you feel its all right?
Hi Jay,

I feel that it's not of value (to you) for me to help troubleshoot and debug your program. That's experience that you should be getting. But, I will offer this piece of advice:
If you are using polynomials to evaluate the physical properties, make sure you are either using double precision (16 digets), or the specific algorithm that minimizes roundoff error.

Chet
 
  • #139
Okay. But do you think the values are not correct? I would only need to troubleshoot if that's the case right?
 
  • #140
Jay_ said:
Okay. But do you think the values are not correct? I would only need to troubleshoot if that's the case right?
You don't need my help to answer this. Just do the calculations by hand. It should only take about 20 minutes, and then you'll be sure.

Chet
 

Similar threads

  • Thermodynamics
Replies
2
Views
870
  • Introductory Physics Homework Help
Replies
19
Views
1K
  • Aerospace Engineering
Replies
10
Views
728
  • General Engineering
Replies
21
Views
2K
  • Mechanical Engineering
Replies
4
Views
838
Replies
14
Views
1K
Replies
18
Views
1K
  • General Engineering
Replies
11
Views
2K
Replies
3
Views
242
Back
Top