Вы находитесь на странице: 1из 3

MAE 1202: Aerospace Practicum

Laboratory Homework #3 Due: February 18, 2011

YOU: Another laboratory homework assignment?!? But this is only a 2 credit class and there are
already a bunch of lecture homework problems due next Wednesday.

ME: This laboratory exercise is designed to help you with the lecture-based homework and even
give you some of the answers to the lecture homework problems. It is also designed to give you
more practice using MATLAB and to show you how when used by the forces of good it can be
an extremely powerful engineering tool.

1. Consider homework problem 4.8: A supersonic nozzle is also a convergent-divergent duct,


which is fed by a large reservoir at the inlet to the nozzle. In the reservoir of the nozzle, the
pressure and temperature are 10 atm and 300 K, respectively. At the nozzle exit, the pressure is 1
atm. Calculate the temperature and density of the flow at the exit. Assume the flow is isentropic
and, of course, compressible.

The following MATLAB script will give you the answer to this problem. As you type in this
script, make sure that you completely understand each line of the code. All the equations are
taken from Equation 4.37 in the textbook.

% Script to calculate isentropic relations


% based on Equation 4.37 from Introduction to Flight
close all; % closes any plot windows that may be open
clear all; % clears all variables from memory from any previous scripts

gamma=1.4; % Specific heat ratio for air


R_universal=8314; % Universal gas constant
M=28.97; % Molecular weight of air
R=R_universal/M; % Gas constant for air

% Enter relevant values


p_inlet_atm=10; % inlet pressure in atmospheres
p_inlet_pa=p_inlet_atm*101325; % inlet pressure in Pascals or N/m^2
p_exit_atm=1; % exit pressure in atmospheres
p_exit_pa=p_exit_atm*101325; % exit pressure in Pascals or N/m^2
T_inlet=300; % inlet pressure in Kelvin

% The inlet density may be found from the ideal gas equation
rho_inlet=p_inlet_pa/(R*T_inlet);

% Find the exit temperature


PR=p_exit_atm/p_inlet_atm; % PR=pressure ratio

T_exit=PR^((gamma-1)/gamma)*T_inlet % exit temperature in Kelvin


TR=T_exit/T_inlet; % TR=temperature ratio

% Find the exit density


rho_exit=PR^(1/gamma)*rho_inlet % exit density in kg/m^3

DR=rho_exit/rho_inlet; % DR=density ratio

1
The answer to problem 4.8 is: Texit=155.4 K and ρ exit=2.27 kg/m3
Note: I am giving you the answer so you can check your work and ensure that you
understand the problem completely – not just so you can turn it in for credit.

Now that you have a fancy MATLAB script to answer problem 4.8, let’s see how useful it is.
Notice that problem 4.8 is actually poorly written by the author – no where does it mention what
type of gas is used! The MATLAB script assumed air since that is probably what is most
common in a supersonic nozzle. However, other supersonic facilities or nozzles may have
different gases flowing in them. Use the given MATLAB script to examine the same inlet and
exit conditions but with the following gases:

Helium (Molecular weight, M = 4.0, specific heat ratio, γ = 1.667)


Argon (Molecular weight, M = 39.94, specific heat ratio, γ =1.667)
Solid rocket combustion gas, which is a mixture of chemicals that you will learn a lot about
during your senior year in MAE: 4262 (M=25, γ =1.2)

What are the exit temperature and density for these three cases? Display your results in a
suitable table (presented in a MS Word document) which shows the gases used and the exit
temperature and density.

Most solid rockets operate well into the upper atmosphere where the ambient pressure is less
than 1 atmosphere. Furthermore, the combustion chamber gases are usually at pressures that are
higher than 10 atmospheres. Re-run the solid rocket combustion gas case using the molecular
weight and specific heat ratio (for helium and argon) given above, but with an inlet pressure (of
the combustion chamber) of 25 atmospheres and an exit pressure (called the back pressure) equal
to the ambient pressure at an altitude of 20 km. How different are your results from the
pressures given in the initial problem?

2. Consider homework problem 4.20: A Pitot tube is mounted in the test section of a low-speed
wind tunnel. The flow in the test section has a velocity, static pressure, and temperature of 150
MPH, 1 atm, and 70 ºF, respectively. Calculate the pressure measured by the Pitot tube.

This problem can be solved by applying the ideal gas law to find the density in the test section
and then calculating the total pressure using the Bernoulli equation. The answer to this problem
is the total pressure = 2172 lb/ft2. Let’s now assume that we want to know the total pressure not
only at 150 MPH but from speeds from 0 to 300 MPH, which is the incompressible flow limit
discussed in the textbook. The following MATLAB script will generate a plot the total pressure
vs. velocity.

% Script to calculate total pressure inside a Pitot tube


% for a low-speed subsonic wind tunnel based on Problem 4.20

close all; % closes any plot windows that may be open


clear all; % clears all variables from memory from any previous scripts

% Given data

2
V_MPH=[0:5:300]; % velocity range in MPH
p_atm=1; % test section pressure in atmospheres
T_F=70; % test section temperature in degrees F
R_air=1716 % gas constant for air in ft*lb/(slug*R)

% Convert given data to standard units


V_ft_s=V_MPH*5280/3600; % velocity in ft/s
p_lb_ft2=p_atm*2116.2; % pressure in lb/ft^2
T_R=T_F+459.67; % temperature in Rankine

% Calculate density in the test section


rho=p_lb_ft2/(R_air*T_R);

p_total=p_lb_ft2+0.5*rho*V_ft_s.^2;
% notice the use of the '.' in the above line. This tells MATLAB that you want
% to take each element of the vector V_ft_s and square it. If the '.' was not
% there MATLAB would think that you want to multiply the vector V_ft_s by itself
% using matrix multiplication. Try this line of code without the '.' and you
% will get an error. It takes a little practice when to use the '.' or not, but
% remember if you are not multiplying two matrices together, and just multiplying
% elements of an arrary or vector you need the '.'. This understanding will come
% with further practice.

figure(1)
plot(V_MPH, p_total);
grid on;

xlabel('Velocity, MPH');
ylabel('Total Pressure, lb/ft^2');
title('Plot of Predicted Pitot Tube Pressure vs. Wind Tunnel Speed');

Notice that if you zoom in on this plot to 150 MPH, you will find the answer agrees with the
solution presented.

Modify this script to plot on a single graph the total pressure, pt, the static pressure, p, and
the dynamic pressure, q, vs. speed in MPH. At the MATLAB command prompt, type: help
legend. Use this command to add a legend to your plot and locate it in the upper left
corner. Using the ‘legend’ command indicate which of your curves are the total pressure,
static pressure and dynamic pressure. Next, generate a second figure, which shows the
value of the static pressure and dynamic pressure as percentage of the total pressure vs.
speed in MPH. Comment on each of these results for the incompressible flow range. Finally
using the subplot command, try to modify the script to show both of the two plots on the
same figure. To learn more about subplot at the command prompt, type: help subplot

EXTRA CREDIT BONUS: Any additional homework problem that you do this week both
by hand and using MATLAB, you will get 1 extra point on your midterm exam. This
means that you can earn up to 6 extra points on your midterm, which is quite significant.

Вам также может понравиться