The easiest way to calculate the density of dry air is by applying the ideal gas law. The ideal gas law expresses density as a function of temperature and pressure. Also, just like all gas laws, it is an estimate.