Versatile Gasdynamics Computer Program for One-Dimensional Isentropic Rayleigh and Fanno Flows
Total Page:16
File Type:pdf, Size:1020Kb
University of Central Florida STARS Retrospective Theses and Dissertations 1987 Versatile Gasdynamics Computer Program for One-Dimensional Isentropic Rayleigh and Fanno Flows Robert Kenneth Smith University of Central Florida Part of the Engineering Commons Find similar works at: https://stars.library.ucf.edu/rtd University of Central Florida Libraries http://library.ucf.edu This Masters Thesis (Open Access) is brought to you for free and open access by STARS. It has been accepted for inclusion in Retrospective Theses and Dissertations by an authorized administrator of STARS. For more information, please contact [email protected]. STARS Citation Smith, Robert Kenneth, "Versatile Gasdynamics Computer Program for One-Dimensional Isentropic Rayleigh and Fanno Flows" (1987). Retrospective Theses and Dissertations. 5065. https://stars.library.ucf.edu/rtd/5065 A VERSATILE GASDYNAMICS COMPUTER PROGRAM FOR ONE-DIMENSIONAL ISENTROPIC, RAYLEIGH AND FANNO FLOWS BY ROBERTKENNETHS:MITH B.S., University of Tennessee, 1977 RESEARCH REPORT Submitted in partial fulfillment of the requirements for the Master of Science in Engineering in the Graduate ~tudies Program of the College of Engineering University of Central Florida Orlando, Florida Fall Term 1987 ABSTRACT The purpose of this research report IS to discuss the development and results of a computer program (GASDYNAMICS) that solves a variety of compressible one-dimensional ( 1-D) steady gas dynamics problems utilizing the algebraic equations that result from the governing differential equations assuming perfect gas conditions. This report shows how the governing differential equations that are derived from the ideal gas law, the definition of Mach number, and the fundamental conservation laws of mass, energy, and momentum can be developed into their algebraic forms when additional simplifying assumptions are made. GASDYNAMICS solves problems for either a converging or a converging-diverging nozzle followed by a constant diameter duct where either friction and/or heating occur. Any ideal gas may be assumed. The program performs analysis necessary to find the location of shocks in either the nozzle or the duct. This analysis requires an evaluation of the backpressure to inlet stagnation pressure relationship In addition to friction and/or heating terms to determine which, if either, factors will drive the shock location. GASDYNAMICS requires that the operator respond to a senes of questions concerning identification of the gas, initial stagnation properties, and duct to nozzle throat geometry. GASDYNAMICS outputs a tabulation of static pressure, stagnation pressure, static temperature, Mach number, mass flowrate per unit area, velocity and density at discrete points along the flowpath. These values are expressed in metric units. GASDYNAMICS was written using Applesoft Basic language on an Apple IIE Computer. The program has been modified by changing the program syntax to Microsoft Basic language. This modification, along with proper disk format, allows the program to run on either the Apple MacIntosh or IBM PC computers. ACKNOWLEDGEMENT I would like to thank all those who have contributed to this project. I am grateful to Dr. Eno for his leadership in making this project successful and also to Dr. Bishop and Professor Beck for their suggestions, comments, and encouragement. Special thanks are extended to Dr. Wilkerson of the University of Tennessee, who suggested the Zucrow book as a good reference and provided a large portion of my fundamental understanding of the subject. I am grateful to Mr. Joe Letosky, who was extremely helpful in providing access to the GALE editing program as well as other vital reference material in Applesoft and Microsoft Basic programing. More importantly Joe was the person that would listen to my programing problems and very often suggest solutions that eventually worked. Special thanks are extended to Ms. Pat Green and Ms. Susan Brinkley, who endured several revisions and spent many hours on the MacIntosh. They both did a great job typing this report. I am also grateful to Ms. Shirley Pencka for her expertise in producing the figures. 111 Most importantly I would like to thank my wife, Suzanne, and my children, Jason and Rachel. They were patient, understanding, and encouraging as I spent many hours working on this project and the courses that preceded it. IV PRESSURE p STATIC PRESSURE PB BACK PRESSURE PC CRITICAL PRESSURE RATIO PE CALCULATED EXIT PLANE PRESSURE PF STATIC PRESSURE RATIO FOR FANNO FLOW PG STAGNATION PRESSURE RATIO FOR FANNO FLOW PJ STAGNATION PRESSURE RATIO FOR RAYLEIGH FLOW PK STATIC PRESSURE RATIO FOR RAYLEIGH FLOW PL EXIT PLANE STATIC PRESSURE FOR A NORMAL SHOCK AT THE EXIT PLANE EP EXIT PLANE STAGNATION PRESSURE RATIO FOR EXIT PLANE FANNO FLOW KF EXIT PLANE STATIC PRESSURE RATIO FOR EXIT PLANE FANNOFLOW PO INLET STAGNATION PRESSURE (GIVEN INPUT) PR RATIO OF BACKPRESSURE TO STAGNATION PRESSURE PSTA STATIC PRESSURE@ WHICH M =1 FOR RAYLEIGH FLOW PSTARF STATIC PRESSURE@ WHICH M =1 FOR FANNO FLOW PT STAGNATION PRESSURE RATIO ACROSS A NORMAL SHOCK PW STAGNATION PRESSURE RATIO ON SUBSONIC SIDE OF SHOCK FOR FANNO FLOW. PY STATIC PRESSURE RATIO FOR FANNO FLOW@ SHOCK LOCATION. P'Z STATIC PRESSURE RATIO ACROSS A NORMAL SHOCK TEMPERATURE T STATIC TEMPERATURE 1E EXIT PLANE STA TIC TEMPERATURE. 1F STATIC TEMP. RATIO FOR FANNO FLOW TK STATIC TEMP. RATIO FOR RAYLEIGH FLOW 10 STAGNATION TEMPERATURE @ INLET (GIVEN INPUT) 1Q STAGNATION TEMP. RATIO FOR RAYLEIGH FLOW @ INLET TR STAG NATION TEMP. RATIO FOR RAYLEIGH FLOW @ EXIT TSTAR STAGNATIONTEMPERATURE RATIO ACROSS A RAYLEIGH DUCT IT CALCULATED STAGNATIONTEMP.@DUCTEXIT 1Z STATIC TEMP. RATIO ACROSS A NORMAL SHOCK THERMODYNAMIC PROPERTIES CP SPECIFIC HEAT GA SPECIFIC HEAT RATIO GM SPECIFIC HEAT RATIO - 1 ix TABLE OF CONTENTS List of Tables ...............................................vi L1st. o f p·1gures .............................................. v11 .. Nomenclature. .viii I. Introduction ............ ..............................1 II. Development of Governing Equations for Compressible Gas Dynamics ............................................. 5 II I. Computer Model Development.......................... 23 IV. Results and Discussion ................................ 45 V. Error Analysis ........................................68 VI. Application as a Teaching Aid.......................... 70 VII. Conclusions .......................................... 71 Appendices ................................................ 72 1) Computer Program Flowchart. ............. 73 2) Computer Program Listing .........................101 3) Computer Printout for Each Case................... 125 References ................................................140 V ..- LIST OF TABLES 1. Summary of Numerical Results ............................ 2. Effect of Heat Addition on Flow Properties for an Ideal Gas in a Constant Area Duct...................................... 3. Effect of Friction on Flow Properties for an Ideal Gas in a Constant Area Duct...................................... VI LIST OF FIGURES 1. Control Volume for Varying Area Flow with Heat Transfer and Fnct1on................................................ 6 2. Fanno Flow Line on Temperature--Entropy Diagram........... 14 3. Rayleigh Flow Line on Temperature--Entropy Diagram......... 16 4. Control Volume for Normal Shock Wave.................... 20 5. Converging/Diverging Nozzle. Reference Cases 1 and 5 ........26 6. Converging Nozzle. Reference Cases 2 and 4 ................ 50 7. Converging Nozzle Followed by a Constant Diameter Heated Duct. Reference Case 7. 51 8. Converging/Diverging Nozzle with Normal Shock. Reference Case 3. .54 9. Converging/Diverging Nozzle Followed by a Constant Diameter Heated Duct. Reference Case 6 ........................... 56 10. Converging/Diverging Nozzle Followed by a Constant Diameter Heated Duct. Reference Cases 8 and 9 ......................57 11. Converging/Diverging Nozzle Followed by a Constant Diameter Duct with Heating and Friction. Reference Case 10........... 62 12. Converging/Diverging Nozzle Followed by a Constant Diameter Heated Duct with Shock Wave and Friction. Reference Cases 11 and 12............................................... 63 13. Converging/Diverging Nozzle Followed by a Constant Diameter Adiabatic Duct with Shock Wave. Reference Case 13 ......... 65 Vll NOMENCLATURE Computer Pro2ram GEOMETRY AISTAR THROAT AREA AD DUCT AREA AX AREA@ SHOCK LOCATION AY AREA RATIO: NOZZLE AREA@ SHOCK LOC TO THROAT AREA WHERE MACH NUMBER=l ON SUBSONIC SIDE OF SHOCK AR AREA RATIO: AREA WHERE MACH NUMBER=l ON SUPERSONIC SIDE TO AREA ON SUBSONIC SIDE AA AREA RATIO: NOZZLE EXIT AREA TO THROAT AREA ID DUCTDIAMETER DR NOZZLE EXIT PLANE TO THROAT DIAMETER RATIO or THROAT DIAMETER IX NOZZLE DIAMETER@ SHOCK LOCATION DY NOZZLE TO THROAT DIAMETER RATIO AT SHOCK LOCATION FRICTION FL (FRICTION LENGTH)/DIAMETER OR FUD (GIVEN INPUT) FX CALCULATED FL/D FOR MACH NUMBER ON SUPERSONIC SIDE OF SHOCK FY CALCULATED FL/D FOR MACH NUMBER ON SUBSONIC SIDE OF SHOCK CA CALCULATED FL/D FOR A SPECIFIC MACH NUMBER CB DIFFERENCE BETWEEN FL & CA cc CALCULATED FL/D FOR EXIT MACH NUMBER CY CALCULATED FUD FOR MACH NUMBER ON SUBSONIC SIDE OF SHOCK MACH NUMBER M MACH NUMBER ME EXIT PLANE MACH NUMBER MT THROAT SECTION MACH NUMBER 1,1)( SUPERSONIC MACH NUMBER UPSTREAM OF A NORMAL SHOCK MY SUBSONIC MACH NUMBER DOWNSTREAM OF A NORMAL SHOCK viii THERMODYNAMIC PROPERTIES (CONTINUED) GP SPECIFIC HEAT RATIO+ 1 R GAS CONSTANT IE DENSITY MISCELLANEOUS BB PSEUDO FOR AREA RATIO