How can I add an automatic bulk discount to a product?

How can we have an automatic bulk discount for books? Is there a way that it just appears if someone puts say 10 books in their cart it automatically adds a 10% discount?