I still feel a few basic mechanical definitions are not being thought of. One particular professor keeps coming to mind, he would always draw energy diagrams of flows to try and assure us that the derivation was capturing all inputs. This is not that different as we have already heard about discreet particles in the system.
I am by no means even educated enough to comprehend all the inputs. But so far we have in our system Pressure, friction, gravity, and heat. The pressure is overcoming the friction of the projectile in the bore and gravity pulling down on the projectile both sides have losses to heat.
Now that said we also are dealing with how the energy in the system is being transmitted. Initially I was thinking simple SA times pressure = force. Then looking at it we have a wave of particles possibly traveling faster than the speed of sound. This becomes a problem since PV=nRt will describe the total pressure and also give us an energy input but the efficiency will be governed by the internal heat transfer of the media. I will admit I had to go to the bane of the academic Wikipedia and look up shock waves. In a sub category I found Detonation Wave.
I will quote here:
A detonation wave is essentially a shock supported by trailing exothermic reaction. It involves a wave traveling through a highly combustible or chemically unstable medium, such as oxygen-methane mixture or a high explosive. The chemical reaction of the medium occurs following the shock wave, and the chemical energy of the reaction drives the wave forward.
A detonation wave follows slightly different rules from an ordinary shock since it is driven by the chemical reaction occurring behind the shock wave front. In the simplest of theory for detonations, an unsupported, self-propagating detonation wave proceeds at the Chapman-Jouguet velocity. A detonation will also cause a shock of type 1, above to propagate into the surrounding air due to the overpressure induced by the explosion.
When a shockwave is created by high explosives such as TNT (which has a detonation velocity of 6,900 m/s), it will always travel at high, supersonic velocity from its point of origin.
Now if we contain the waves we can have superposition so I would think that the length of the barrel may in fact cause some harmonics. At this point I want to throw in the towel and say the only way I see to find out what is going on is to experiment. I think this system is way to complex to model on paper.