The scientific principle that makes heat pumps work is that heat always attempts to equalize temperature by moving from warm to cool. The heat pump takes advantage of this principle to provide heating and cooling in an extremely efficient manner. In the summer, the compressor moves freon through a coil in the ductwork where it absorbs heat in the air. It then compresses the freon to make it even warmer. The freon is then pumped to the coils outside where a fan blows air across the coils, removing heat and cooling the freon before it returns inside to absorb more heat.
In the winter, the flow of freon is reversed. It flows through the outside unit where it absorbs heat from the outside air. From there, it goes to the inside coil where it radiates it's heat to the inside, cooler air. It is then returned to the outside unit again to absorb more heat energy.