Google would pretty quickly answer this question. I don't want to spoonfeed, so here is the theory of it:
Pressure can be expressed as energy density (energy per unit volume). This is derived by multiplying P = F/A (pressure) by d/d (distance/distance), P
= (F*d)/(A*D), which yields P = W/V. Work isn't strictly "energy" per se, but rather a change in energy over a distance, so under ideal conditions you
can find change in energy given pressure and volume. Using this equation, you get can just divide delta P in pascals (898674.73 Pa) by one
m^{3}, giving you 898674.73 J energy over that change in pressure.
However, compression doesn't work in such a perfect way. The above equation does not account for heat. If we account for heat transfer, things get
more realistic. Assuming the heat from compression is transferred away from the gas (isothermal compression), you can base it on PV = nRT. Work is
equal to the integral of pressure with respect to volume from initial volume to final volume, so just do ∫[V_{1}
V_{2}](P(V))dv to get work. P(V) can be found by putting PV = nRT in terms of P. It's late at night where I am right now, and I'm far
too tired to explain why the integration works here, but it's pretty simple to figure out with basic calculus and physics knowledge. I'll leave the
rest up to you; just solve the integral (or simplify it first if you so desire) and you'll get delta E in joules.
As for your second question, it depends on the volume of the receiving system.
"I've made a huge mistake"
