Thermodynamics · Energy balances for closed systems
A compressor that warms its air can still be losing heat; the exponent n tells you which way the heat goes before you calculate.