A major source of geothermal energy is the Earth's molten core. As you travel down through the Earth's solid crust and into the semi-liquid mantle, the temperature rises to some 1,700 degrees. This internal heat can be used by drilling deep wells and circulating super-heated water to the surface, as happens in Reykjavik. A second source of geothermal energy comes from the Sun. As the Sun beats down on the Earth's surface, the ground water is heated up and stores the heat as latent energy.
A heat pump moves heat from one place to another by pumping a liquid through a heat exchanger. A fridge is the perfect example -- refrigerant is pumped round a network of pipes (the evaporator) inside the fridge. The refrigerant absorbs heat, becoming a gas in the process. This gas then passes outside into another network of pipes (the condenser) where it condenses back to a liquid, releasing the heat in the process. By this process heat is sucked out of the fridge and expelled into the outside air -- that is why the back of your fridge always feels warm.
As explained in section 1, ground water stores solar energy as latent energy. This energy can provide heating for a building by using a geothermal heat pump. These work on exactly the same principle as a domestic fridge. A large shallow pit is dug outside and hundreds of feet of pipe is snaked back and forth through it (like the heat exchanger on the back of your fridge). Water is pumped through this pipe at low pressure absorbing the heat from the ground. The water enters the house and is passed through a heat exchanger at high pressure. This concentrates the heat and provides enough energy to heat the house.
Just like your fridge, one side of the geothermal heat pump gets colder (the bit buried under ground) whilst the other side gets warmer (the bit inside your house). Because there is so much more ground than house, the house side of the system can get very warm for a very tiny drop in the temperature of the ground. Systems such as those offered by Calorex can provide hot water at 65 degrees centigrade -- that's nearly 150 degrees Fahrenheit.