Principles of operation - how a heat pump works