# Pressure Volume graphs and work done

So if I have a system where pressure, volume, and temperature change, how do I find the work done on the system? I look at an example where you simply use $\mathrm{d}W =-p\, \mathrm{d}V$, but I disagree with this because surely if pressure has changed then this can't include that fact.

Then I tried to find work by integrating $p(V)\,\mathrm{d}V$ where the boundaries are the change in V. This, however, leaves a factor of temperature T in the final answer suggesting it's dependent on just 1 value of [? something missing from OP?] as if the system is isothermal which is not true. Could I use the 1st law of thermodynamics? I can't decide if this is the correct direction of work in terms of whether the work is done by or on the system?

Can someone point out why I'm getting confused, please?

• Do you know anything about the type of process? Is it adiabatic e.g? Cyclic? Insulated? – Steeven Feb 25 '16 at 18:44
• You should know that the fact that we use one letter doesn't mean it's constant. $p$ can depend on whatever, and you don't need to write $p(V)$. Mathematicians write $y=f(x)$, physicist abuse and say $p=p(V)$. That said, there's no lack of information: all info is implied in the shape of the p(V) curve. Each type of process has its own curve. How T changes modifies the shape of $p(V)$. – FGSUZ Feb 5 '18 at 14:08

The work done on a gas is

the negative of the area under the $pV$ curve between $V_i$ and $V_f$ (Knight, Physics for Scientists and Engineers, 3rd edition, page 473)

So $$W=-\int_{V_i}^{V_f} p\,\mathrm{d}V .$$

What you must keep in mind is that $p$ can be a function of $V$ and/or $T$. In order to actually do the integral, you must replace $p$ by its functional form.

You might use the ideal gas law to get $$p=\frac{nRT}{V}.$$ Then you would need to find the function for $T$, unless the process is isothermal (constant $T$). Or there might be another gas law such as van der Waals. If the process is not isothermal, it might be adiabatic which gives you a second equation, $$p_iV_i^{\gamma}=p_fV_f^{\gamma},$$ to combine with your gas law to find the appropriate function for $p$.

Bottom line: $p$ is not necessarily a constant in the work integral. It can be a function. The type of process determines how you treat $p$.

Also note that if the volume of the gas doesn't change, no work is done on or by the gas.

The work done by the gas on the surroundings is always given by $$W = \int{P_{ext}dV}$$where $P_{ext}$ represents the pressure at the interface with the surroundings (for example, the inside face of a piston). If the process is reversible, then the pressure throughout the gas P is uniform, and the pressure at the interface is equal to P (i.e., $P_{ext} = P$). In addition, for a reversible process, the pressure P is given by the equation of state for the gas (e.g., the ideal gas law, van der Waals equation, Benedict, Webb, Rubin equation). If the process is irreversible, the pressure (and temperature) within the gas is non-uniform, and also depends on the rate at which the volume is changing. So, practically the only of establishing the interface pressure $P_{ext}$ for an irreversible process is to impose it externally.