 We're now going to look at another hydrostatic pressure distribution and this case will be for gases. So if you recall in the case of liquids it was relatively easy. For gases it's a little bit more tricky because the density cannot be assumed to be a constant for gases and so what we will be doing is we will be using an equation of state that relates the density of a gas to its pressure and temperature and the one that we will use is the ideal gas equation and that is P is equal to rho RT and we'll use that in the integral that relates pressure to density and the gravity vectors. If you recall what we derived was an equation that looks something like this assuming that there is no acceleration or vorticity shear within our fluid and subbing in the expression of the ideal gas equation we get minus P over RT for rho g and we'll rearrange this and what we get on the left hand side an integral from 1 to 2. We have a natural logarithm here and then on the right hand side g over R 1 to 2 and R is the ideal gas constant for whatever gas we're dealing with in this case we're talking about air typically. So with this that's what the equation comes out to be but you can see in order to solve it we need we need to have a relationship for temperature as a function of z or position within the atmosphere and and so we need that relation before we can proceed so what we're going to do we're going to look at a couple of cases here and the first one will be the assumption of an isothermal atmosphere and we'll assume temperature is T0 288.16 Kelvin so 273 plus that'd be 5678 15 degrees C is what we're looking at and when we do that looking back at our integral equation that's this one right here when you put that temperature and that's just going to be a constant so it's a relatively straightforward integral and what we get is P2 is equal to P1 and the exponential remember we had a natural log and that's where the exponential is coming from and temperature is a constant so that's what we get if we can assume it to be an isothermal atmosphere fairly straightforward. Now in reality the atmosphere is not isothermal it does change as you go up with elevation and there are different models we have a US standard atmosphere that we quite often assume and the way that the temperature changes if we were to look at temperature oops sorry it shouldn't be temperature temperature should be on the horizontal axis so if we have temperature and then z that would be elevation or altitude what we'll find down here you have the planetary boundary layer and so the temperature more or less will change depending upon day or night but when you get above the planetary boundary layer temperature will drop down and if you ever go on a flight and you have a map in front of you watch the temperature and plot it as a function of elevation and it should decrease linearly as you go up and that is within the in the troposphere the temperature will drop like that and that goes up to about 36,000 feet or 11,000 meters and this is average it depends upon the weather conditions if you have fronts coming in or where you are in terms of north or south in the globe but typically it drops down linearly and then we get to the tropopause and at the tropopause what happens is the temperature then goes constant and that is the stratosphere and I believe the stratosphere goes up somewhere to about 65,000 feet so it's quite high but whenever you're flying in an aircraft the highest you probably get to be about 45,000 feet so you'd probably be in this range here but we have a linear relationship in the troposphere we get to the tropopause and then it becomes a constant temperature and this is typically somewhere around minus 60 degrees C I think technically it's minus 56 is what they do for the standard atmosphere but it's anything around there that's usually where the temperature is but the important point here is that in the troposphere so up to about 36,000 feet which is 11,000 meters we have a linear relationship and we can work with that in order to solve for the the pressure as a function of elevation so here we can say the temperature in the troposphere is expressed as T naught minus B times Z where T naught is again 15 degrees C 288.16 K 15 degrees C and B that is the rate at which the temperature is dropping it is a certain number of kelvin so 6.5 milli kelvin per meter that you go up and with that if we go back to our equation where was the equation if we go back to this equation here and we put in that distribution for the temperature for the stratosphere which is this one here with those constants what we will find is we get the pressure as being the atmospheric pressure times 1 minus B Z divided by T naught raised to the power of G divided by the gas constant for air and B that would be the slope of the temperature gradient so for air atmospheric air G over R B that ratio is 5.26 and PA typically is 101 325 Pascal's so this would be the relationship that you would use for the pressure in the troposphere as you go up and that would apply up to about 11,000 meters or 36,000 feet so two different relationships the first one we had was if we had an isothermal atmosphere now you can use that and if you're in the troposphere below the tropopause you can use this relationship here to estimate the the pressure of the atmosphere as you go up and so those are two cases of looking at hydrostatic pressure distribution for a gas and in this case we've looked at air and our atmosphere