Question: what is the relationship between altitude and temperature in each layers?
Answer: Temperature increases as you gain altitude in the stratosphere and the thermosphere. Temperature decreases as you gain altitude in the troposphere and mesosphere. Air temperature varies in complicated ways with altitude.