There are many different kinds of compressors, but typically the main purpose of using a compressor is to raise the pressure of a liquid or gas. Compressors are found in both gas power cycles and vapor compression refrigeration cycles. A compressor converts shaft power to a rise in enthalpy of a fluid. The rotating shaft is attached to a blade assembly. The rotating blades push on the gas and increase the pressure, thereby increasing the enthalpy.
Compressors are continuous flow processes, and can be either axial or radial.
To calculate these enthalpy changes, you need to know the initial and final states, for example, temperature and pressure, of the working fluid.