Step 1 of 4: Work–energy theorem for a fluid element
Intuition
The liquid pressure 'pushes' the element like hands at both ends of the pipe: the hand behind pushes harder than the hand ahead resists, and the difference is the net energy the fluid receives.
Analysis
Consider the fluid between two cross-sections , of a stream tube. Pressure at end 1 pushes the slug forward by (positive work ); pressure at end 2 opposes the motion (negative work ). With no viscosity these are all the external works besides gravity; by the work–energy theorem, their difference equals the gain in kinetic plus gravitational potential energy of the slug.