Who says the gun shoots 1 Joule? It's the BB that has 1 Joule of muzzle energy. The gun may be more or less efficient with differing BB weights, hence the changes in energy with different BB weights. That BB merely "accepted" 1 Joule of energy. The gun amy in fact be capable and producing more output potential energy than what the actual kinetic energy of the BB is. The hop-up will eat up some energy in friction, air loss around the BB will eat up some, air seal losses in the hop-up may change due to different weights as well.
There's alot that goes on inside an airsoft gun, lots of areas for losses.
Age verifier Northern Alberta
Democracy is two wolves and a sheep discussing what's for dinner.
Freedom is the wolves limping away while the sheep reloads.
Never confuse freedom with democracy.