Well it is based on Boyle’s Law.
You may think it is difficult to understand but it isn’t and you see it and use it every day without realising it. Boyle’s Law basically means that temperature, pressure and volume are all interconnected, and if you fix one, and adjust one of the other two, this will cause the third to change.
In simple terms, think of a pressure cooker or a pot of jam. When you put the lid on a pressure cooker, you have just fixed the volume. Then you add heat, you have increased the temperature and the result is the pressure has increased. In a new pot of jam, the jam goes into the pot hot so has a high temperature. When you put the lid on the pot, you have fixed the volume of air above the jam. This air is at atmospheric pressure when you do this. Then the jam cools which is lowering of the temperature, the volume of the air above the jam stays pretty much the same, but the pressure of that air drops and becomes a vacuum.
When you know how this works you can use it to raise or lower the volume, temperature or the pressure to suit your needs. So, when heating your house, the air-source heat pump the heat pump lowers the pressure of the gas circulating around the fins of the heat pump so that it is colder than the surrounding air, and when it has travelled around the condenser and comes back into the heat pump, the compressor compresses it making the volume smaller, which in turn raises the temperature. This gas is then sent into the exchanger which has your heating system water circulating around it and the gas is hotter than the water so the water gets heated up by this gas. The heat pump has pumped heat from the outside air (the air-source heat) into the heating system.
This process can be used to heat or cool your heating system, heat your swimming pool or to heat your hot water.