HW19solution

HW19solution - on plot(Mone, Tratio, '-k' , 'LineWidth' ,2)...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
AAE 334, Fall 2011, Homework 19 SOLUTIONS Due at beginning of lecture, Friday, October 28, 2011 A series of Matlab functions has been created to aid compressible flow students. They can be downloaded from Blackboard as one zipped file. A users guide is included in the zip file, so: Read it Note on the second page that the function names are related to equation numbers in the text. Try a few of the examples on the last page of the guide to For this assignment: 1. Download the file MLcompflow.zip …etc. 2. Compute and plot on one plot 1 2 p p , 1 2 , and 1 2 T T across a steady normal shock wave for Mach numbers of 1 to 5 using these functions. Hand in a hard copy of m-file and the plots. Set the upper end of the axis for property ratios to a value of 20. Here are two possible solutions to Part 2: Mone = [1:0.01:5]; pratio = NS_p2p1(Mone); Tratio = NS_T2T1(Mone); rratio = NS_r2r1(Mone); % clf plot(Mone, pratio, '--k' , 'LineWidth' ,2) hold
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Background image of page 2
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: on plot(Mone, Tratio, '-k' , 'LineWidth' ,2) plot(Mone, rratio, '-.k' , 'LineWidth' ,2) grid on legend( 'p_2/p_1' , 'T_2/T_1' , '\rho_2/\rho_1' ) set(gca, 'YLim' ,[0,20]) xlabel( 'Upstream Mach number, M_1' ) ylabel( 'Property Ratio' ) hold off 1 1.5 2 2.5 3 3.5 4 4.5 5 2 4 6 8 10 12 14 16 18 20 Upstream Mach number, M 1 Property Ratio p 2 /p 1 T 2 /T 1 2 / 1 Mone = [1:0.01:5]; pratio = NS_p2p1(Mone); Tratio = NS_T2T1(Mone); rratio = NS_r2r1(Mone); % clf semilogy(Mone, pratio, '--k' , 'LineWidth' ,2) hold on semilogy(Mone, Tratio, '-k' , 'LineWidth' ,2) semilogy(Mone, rratio, '-.k' , 'LineWidth' ,2) grid on legend( 'p_2/p_1' , 'T_2/T_1' , '\rho_2/\rho_1' ) set(gca, 'YLim' ,[0,20]) xlabel( 'Upstream Mach number, M_1' ) ylabel( 'Property Ratio' ) hold off set(gca, 'YTick' ,[1:10 20]) 1 1.5 2 2.5 3 3.5 4 4.5 5 1 2 3 4 5 6 7 8 9 10 20 Upstream Mach number, M 1 Property Ratio p 2 /p 1 T 2 /T 1 2 / 1...
View Full Document

Page1 / 2

HW19solution - on plot(Mone, Tratio, '-k' , 'LineWidth' ,2)...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online