It was a very interesting experience. I spent about four months doing nothing but reading books and online articles to understand all aspects of the subject better. I then pulled all this material together into topics, which broke down into chapters. Then I wrote the narrative, fitting these references in where appropriate. Perhaps the most important task was the final editing, where I managed to cut the number of words from 112K to 69K and the number of references from 1200 to about 750. (They say a book should not go beyond 70K words.) Getting all the references in the right format and adding small 1, 2, 3, ...,750 and hyperlinks to the bibliography took, literally, weeks! Still, I'm quite pleased with the result.