This is a complete model of the 1976 US standard atmosphere model with valid data between sea level and 1000 km. This set of functions returns Temperature, Pressure, Density, Speed of Sound, Gravity, Dynamic and Kinematic Viscosity, Coefficient of Thermal Conductivity, Gas Number Density at desired altitudes. Ability to convert to English Units as desired.
Values DO differ by less than 1% due to different integration technique and should be closer to the actual values of the integrals described in the 1976 U.S. Standard Atmosphere
atmo_compo.m-Gas composition for upper atmosphere program
atmo_p.m-Pressure Computation Program
atmo_temp.m-Temperature Computation Prgram
f_n.m-Gas Composition Integral Program
int_tau.m-Tau integral for Hydrogen
tester.m-Runs atmo.m code for complete atmosphere and does plots for each of the variables
Comments and errors are welcome
This code is not entirely correct. On error, among others, is that the author misinterpreted Equation (39) of the original published document on the Standard Atmosphere of 1976. This involves the calculation of the Hydrogen number density. The author oversimplified the equation. Also, the temperature gradient in Equation (28) involves a constant "a" which the author had the wrong sign on.
Do you have an alternate source or correction for your value of Helium number density @86km? The value in Table 9 looks like 10^10 to me, but you have it in "atmo_compo.m" as 10^14.
Nice submission otherwise, there's a lot you could do to vectorize the computations though.
way too slow
Good simple program. Found an error with output pressure in English units though. The conversion factor (unit_c(5)) used on line 162 in atmo.m should be 3.3852e3 instead of 0.0001450377.
Good program, no errors found for intended use
Accuracy is quite high for a simple program. Might suggest adding solar activity
it was so useful for me.
Great program for preliminary satellite drag calculations
I agree with the other comment. This program is impressive and useful. It does take a long time to run, but its worth it. Excellent download if you need to work with any portion of the atmosphere. Good work!
Very amazing-Well Written, some programs can be improved for speed but full atmosphere program taking a fraction of time to run and then interpolation commands used. Good job.
BTW, your new version doesn't have any errors with my 6.5 version.
May have some compatability problems with previous versions of Matlab. Sends any bugs/errors to email@example.com
Corrected for lower atmosphere calls only