The easiest way to keep cats out of your garden is to get a cat! Cat's will tend to go to the loo on the edge of our just outside their territory. For most cats in a modern urban environment, their territory has been shrunk down to the back garden, and will be delineated by the garden fence/wall/shrubs. The effect of this is that if you have no cat, next doors cats territory will tend to extend into your garden, and they'll go into it to use it as a loo. If you had a cat, it would protect it's territory, and go to the loo in your neighbours gardens!
Personally I like dogs and cats, but it would be unfair of me to have a dog which would have to be stuck indoors by itself most of the day. A cat can look after itself, so for me (and probably a lot of people who work in places like London), is a more practical option.