I am looking for a sci-fi short story I read a long time ago, though I am not sure exactly when. It must be at least 8 years old, but I believe it is much older than that. Its theme is free will vs. determinism.
The story regards a man who wakes up in a locked room with no recollection of how he got there. Meals are provided to him, though he never sees another person (I think they came through a slot in the wall, or while he was asleep). The room is completely furnished.
The interesting part of the room is that there is a wall with a giant bookcase on it. There are large bound volumes upon the shelves. Upon opening a volume, the man discovers that everything he does is detailed in the books with a time stamp on the page. So when he opens to a random page for the first time, the page says the he opened the book to X page and began reading.
He gets frustrated with the books and tries to "beat" them by doing random actions. He spins the dial of the clock to a random time, opens a book and discovers that the book already had noted the time that he set the clock to. He tears up one of the volumes in frustration. The next time he wakes up, there is a new volume in place of the old torn up one. Eventually he decides not to be governed by the books and resolves not to open them anymore. He opens one book for the last time, looks only at the time at the top of the page, and resets his clock to the correct time as detailed by the book.
Does anyone know what this short story is titled or who wrote it? I have tried to Google this many times, but there are way too many sci-fi short stories about free will v. determinism.
EDIT: Just a note on what I did to research this question. I have done many Google searches regarding the many elements of the story I can remember. I have also emailed all my sci-fi fan friends with a description of the story to see if they have any idea. I have started just looking up lists of famous and classic sci-fi short stories from all authors and reading the descriptions, but there are so many out there that I don't know my chances of success this way.