Dimension of Miracles is a 1968 satirical science fiction novel, with elements of absurdism,[1] by American writer Robert Sheckley.
[2] Thanks to a computer error, Tom Carmody, an unlucky civil servant, wins the main prize of the Galactic Lottery.
At the same time, his removal from his home environment has caused, by the 'universal law of predation', a predatory entity to spring into existence that perpetually pursues and aims to destroy him.
So Carmody is forced to be on the run, and with the help of his Prize meets several well-meaning (but usually not very competent) aliens that attempt to find where, when and which Earth he belongs on.
In an interview for Neil Gaiman's book Don't Panic: The Official Hitchhiker's Guide to the Galaxy Companion, Adams said he had not read anything by Sheckley until after writing the Guide (the first volume in the series) and having seen it printed, and later found some of the parallels between the two works to be eerie, but after all a coincidence.