How do gas molecules constantly bounce without losing energy? From a related question (How does pressurized gas constantly push?), i asked myself this: How do gas molecules constantly bounce off each other without losing energy?
If you drop a ball, it bounces a bunch of times, but the height of each bounce gets shorter and shorter. Because it loses energy in each bounce.
So I don't see how a pressurized gas doesn't lose energy. As I understand it, pressure is a manifestation of lots of molecules bouncing off each other. So over time, shouldn't the pressure drop as the molecules lose speed? and eventually all the molecules will settle in a pile on the floor.
I think another way to phrase this is, how do elastic collisions not lose any energy in the exchange? My understanding of the 2nd law of thermodynamics is that some energy is always "lost" when it's converted from one form to another, or transferred from one object to another. I.e., no transfer/conversion of energy is ever 100% efficient.
 A: As the comments to the question have stated, in real gasses ( contrasted to ideal gasses which just bounce around elastically) there exist both elastic and inelastic scatterings controlled by quantum mechanical interactions.
Photons are generated leading to what we call Black Body radiation  and an isolated gas volume will lose energy according to the Stephan Boltzmann law.

the Stefan–Boltzmann law states that the total energy radiated per unit surface area of a black body across all wavelengths per unit time (also known as the black-body radiant exitance or emissive power), is directly proportional to the fourth power of the black body's thermodynamic temperature T:


Thus the gas does lose energy if the temperature of matter surrounding it is lower.
In answer to

I think another way to phrase this is, how do elastic collisions not lose any energy in the exchange

Elastic means an interaction of two particles where before and after , kinetic energy is conserved. If one assumes that only kinetic energies exist for this scatter ( as in the ideal gas) then energy is conserved because what one particle loses the other gains . If there are other forms of energy that can contribute to the two particle interaction then it is the total energy that is conserved. With billiard balls classically friction has to be taken into account with the energy balance, the same with the bouncing ball, and the kinetic energies stop being the total energy of the system. For particles in a gas it is the quantum mechanical  framework, described above.
A: The simplest possible answer is that in a closed system the lowest entropy state is one where the temperature is (statistically) uniform. 
A: When a ball bounces lower each time, it loses kinetic energy. This is a result of internal friction - the kinetic energy is converted to internal heating.
When two atoms bounce off each other inelastically, where does the energy go? I can think of two mechanisms.
The first is heating. In that case, one of the atoms must get the energy, because that's how "heat" is stored in a substance... 
The other mechanism would be electromagnetic radiation. Some of that does occur - it's black body radiation as explained in Anna V's answer. This radiation interacts with the walls of the vessel - if the walls are at the same temperature as the gas, an equal amount of radiation will come back as was emitted, and the two remain in thermal equilibrium (in other words, another photon somewhere else will carry the energy back into the gas). If the walls are not at the same temperature, then the temperature of the gas will change over time because of the interaction between walls and gas - the two will tend towards equilibrium.
In conclusion - there is no place for the energy to be "lost". And so it isn't...
