Robert van Gulik
beware the wisdom of the magistrate
Robert van Gulik was a Dutch diplomat and Sinophile. While stationed in China he became acquainted with the rich tradition of the Chinese detective novel, which goes back to the Ming dynasty. Chinese detective novels almost always star a district magistrate, who is detective, judge, and jury all-in-one; during the course of the novel, the magistrate usually solves three unrelated cases. The magistrate is always clever, wise, and just.
Most of the Chinese novels he read he judged unsuitable for Western readers of detective fiction, in that the magistrate leaned too heavily on intuition or evidence from ghosts or omens to solve his cases. He found one in particular, though, which he thought would be of great interest: the Dee Goong An. He translated it; it is published in this country as Celebrated Cases of Judge Dee. Later, he decided to try writing his own stories in the same style, drawing plots from the full body of Chinese detective fiction, and holding Judge Dee to a stricter, more rational approach to detection. His first efforts were successful, and he went on to write many novels about the Judge.
The novels are set in the days of the Tang dynasty, as were his Ming dynasty models; and like those models, the dress and social customs portrayed belong properly to the Ming era rather than the Tang.