# First Law of Thermodynamics

The first law of thermodynamics, an expression of the principle of conservation of energy, states that energy can be transformed (changed from one form to another), but cannot be created or destroyed. It is usually formulated by saying that the change in the internal energy of a system is equal to the amount of heat supplied to the system, minus the amount of work done by the system on its surroundings.

## Open Systems

In open systems, matter may flow in and out of the system boundaries. The first law of thermodynamics for open systems states: the increase in the internal energy of a system is equal to the amount of energy added to the system by matter flowing in and by heating, minus the amount lost by matter flowing out and in the form of work done by the system. The first law for open systems is given by:

$\mathrm{d}U=\mathrm{d}U_{in}+\delta Q-\mathrm{d}U_{out}-\delta W\,$

where Uin is the average internal energy entering the system and Uout is the average internal energy leaving the system

The region of space enclosed by open system boundaries is usually called a control volume, and it may or may not correspond to physical walls. If we choose the shape of the control volume such that all flow in or out occurs perpendicular to its surface, then the flow of matter into the system performs work as if it were a piston of fluid pushing mass into the system, and the system performs work on the flow of matter out as if it were driving a piston of fluid. There are then two types of work performed: flow work described above which is performed on the fluid (this is also often called PV work) and shaft work which may be performed on some mechanical device. These two types of work are expressed in the equation:

$\delta W=\mathrm{d}(P_{out}V_{out})-\mathrm{d}(P_{in}V_{in})+\delta W_{shaft}\,$

Substitution into the equation above for the control volume cv yields:

$\mathrm{d}U_{cv}=\mathrm{d}U_{in}+\mathrm{d}(P_{in}V_{in}) - \mathrm{d}U_{out}-\mathrm{d}(P_{out}V_{out})+\delta Q-\delta W_{shaft}\,$

The definition of enthalpy, H, permits us to use this thermodynamic potential to account for both internal energy and PV work in fluids for open systems:

$\mathrm{d}U_{cv}=\mathrm{d}H_{in}-\mathrm{d}H_{out}+\delta Q-\delta W_{shaft}\,$

Enthalpy, H is a thermodynamic propert of system definite

$H = E + pV,\,$

where E represents the energy of the system. In the absence of an external field, the enthalpy may be defined, as it is generally known, by:

$H = U + pV,\,$

where (all units given in SI)

H is the enthalpy (in joules),
U is the internal energy (in joules),
p is the pressure of the system, (in pascals), and
V is the volume, (in cubic meters).

During steady-state operation of a device (see turbine, pump, and engine), any system property within the control volume is independent of time. Therefore, the internal energy of the system enclosed by the control volume remains constant, which implies that dUcv in the expression above may be set equal to zero. This yields a useful expression for the power generation or requirement for these devices in the absence of chemical reactions:

$\frac{\delta W_{shaft}}{\mathrm{d}t}=\frac{\mathrm{d}H_{in}}{\mathrm{d}t}- \frac{\mathrm{d}H_{out}}{\mathrm{d}t}+\frac{\delta Q}{\mathrm{d}t} \,$

This expression is described by the diagram above.

## Closed Systems

In a closed system, no mass may be transferred in or out of the system boundaries. The system will always contain the same amount of matter, but heat and work can be exchanged across the boundary of the system. Whether a system can exchange heat, work, or both is dependent on the property of its boundary.

• Adiabatic boundary – not allowing any heat exchange
• Rigid boundary – not allowing exchange of work

One example is fluid being compressed by a piston in a cylinder. Another example of a closed system is a bomb calorimeter, a type of constant-volume calorimeter used in measuring the heat of combustion of a particular reaction. Electrical energy travels across the boundary to produce a spark between the electrodes and initiates combustion. Heat transfer occurs across the boundary after combustion but no mass transfer takes place either way.

Beginning with the first law of thermodynamics for an open system, this is expressed as:

$\mathrm{d}U=Q-W+m_{i}(h+\frac{1}{2}v^2+gz)_{i}-m_{e}(h+\frac{1}{2}v^2+gz)_{e}$

where U is internal energy, Q is heat transfer, W is work, and since no mass is transferred in or out of the system, both expressions involving mass flow, , zeroes, and the first law of thermodynamics for a closed system is derived. The first law of thermodynamics for a closed system states that the amount of internal energy within the system equals the difference between the amount of heat added to or extracted from the system and the wok done by or to the system. The first law for closed systems is stated by:

dU = δQ − δW

where U is the average internal energy within the system, Q is the heat added to or extracted from the system and W is the work done by or to the system.

Substituting the amount of work needed to accomplish a reversible process, which is stated by:

δW = PdV

where P is the measured pressure and V is the volume, and the heat required to accomplish a reversible process stated by the second law of thermodynamics, the universal principle of entropy, stated by:

δQ = TdS

where T is the absolute temperature and S is the entropy of the system, derives the fundamental thermodynamic relationship used to compute changes in internal energy, which is expressed as:

δU = TdS + PdV

The second law of thermodynamics is only true for closed systems. It states that the entropy of an isolated system not in equilibrium will tend to increase over time, approaching maximum value at equilibrium. Overall, in a closed system, the available energy can never increase, and it complement, entropy, can never decrease.

An isolated system is a type of closed system that does not interact with its surroundings in any way. Mass and energy remains constant within the system, and no energy or mass transfer takes place across the boundary.