What are examples of sci-fi books or short stories that have a mathematics theme? I'd like to have a pool of examples in mind that I could refer students to. The only example I've got in mind right now is The Feeling of Power by Asimov, which I sometimes show students when discussing calculator use.
On the off-chance you don't know about it, I recommend looking through entries at Alex Kasman's website Mathematical Fiction. This has been around quite a while. I don't know when I first learned about it, but definitely by the time of his 31 January 2000 announcement in sci.math, where I offered a few suggestions about a week later, some of which might be of use to you (may need to try the WayBack Machine for some of the URLs). For what it's worth, in June 2001 I wrote one of the descriptions at his request when he saw my comments about Steven Baxter's 1997 short story The Logic Pool in this 31 May 2001 sci.math post.
A couple of useful anthologies I have are
Other Dimensions edited by Robert Silverberg (1973, 1974)
Fantasia Mathematica edited by Clifton Fadiman (1958, 1997)
The Mathematical Magpie edited by Clifton Fadiman (1962, 1997).
I got a copy of the 1974 paperback edition of Silverberg's book shortly after it was published (this being when larger U.S. cities, such as Charlotte which was within an hour's drive of where I then lived, still had diners that also sold a large number of paperback books), and it played an important role in my early interest in mathematics, but I only got around to getting a copy of Fadiman's book (1958 original edition) a few years ago from amazon.com. Each of these books, and Fadiman's later book (which I apparently don't have a copy of, but it definitely merits including here), contains several stories that I think would interest some students.
A couple of authors who are especially mathematically competent are Rudy Rucker and Greg Egan. Rucker's fiction is easier reading and, to me at least, his fiction seems to have the strange quality of conveying a lot more underlying mathematical significance if I know something nontrivial about the mathematics involved. Egan's fiction is rather dense reading, but it also feels more realistic to me than most anything else I've read about how different "humanity" will be a thousand years from now, being more in accord with something I read several decades ago (don't remember by who) which said that humans eventually exploring our galaxy is likely to be as meaningful as saying bacteria landed on the moon in 1969.
Flatland is a classic and very short/readable.
I strongly recommend "The Curious Incident of the Dog in the Night-Time" by Mark Haddon. (I wouldn't consider the novel science fiction but it, in my opinion, has quite some mathematics in it.) From my blog post about it:
Although the story is told from the viewpoint of a 15-year-old boy, I found the observations on language (literal and figurative), writing (how to write detective fiction), the nature of the mind (how a normal person’s way of thinking differs from that of an autistic person, or of an animal, or of a computer), and mathematics very deep. I particularly like how a wide variety of mathematics is presented (probability, chaos, games, tessellations).
The writing is simple and I think the story can be understood by young teen-agers or maybe even younger children.
I would recommend Inverted World by Christopher Priest.
The maths content isn't clear till the denouement but it's spectacular and unique (in my experience) when it comes.
I don't want to spoil it for anyone by putting more detail here, but I just checked out the Kasman website from Dave L Renfro's answer (looks like an excellent resource) and that has this page on it if you want to know more (they add "The" to the title btw, looks like it's been published in both forms).
And He Built a Crooked House is a light fanciful short story based on an unfolded tesseract. Not a great work of literature, but semi-famous. Has a Wiki article.
It is in the anthology, Dave mentioned, but has its own notability. Also, I figure this is like the shape thread where we can show new ideas, since its a collection. (I would edit it in, but I'm a second class citizen, non-teacher, with no account...I know my place.)
Also, to slightly segue, but related, you can also consider to refer kids to math in art. Escher and Penrose stairs and Renaissance perspective and Dali and all that...Wiki articles on math and art, or fourth dimension in art, are starters (but not comprehensive). Maybe helpful for the arty "bad at math" crew. Or the engineer types that like hand drafting. Or even just buy some prints and put them on the classroom walls. Little bit of touchy feely visual motivation.
I just came across Solar Lottery by Philip Dick. I'll try to remember to update this answer with details after I read it. :)
I love a series of 4 books by Rosemary Kirstein. The first is titled The Steerswoman.
Steerswomen journey around the known lands, drawing maps and documenting what they see in their logbooks. Rowan, a steerswoman, finds an odd gem and starts asking people questions about it. Everyone must answer a steerswoman's questions (honestly) or be banned from every asking their own questions of the steerswomen, who are very knowledgeable. People usually enjoy helping the steerswomen by offering information.
The first book starts out seeming like fantasy, because there are wizards who do magic, and there are demons and goblins. But as the story progresses, Rowan keeps wondering what it means for something to be magic. The words science, gravity, and explosions (probably among others that I haven't noticed) are never mentioned, even though all are important themes in the story.
The thinking Rowan and others do about how gravity works, why and how things fall the way they do, is an important part of the storyline. I often quote from this book in my calculus I courses.
If your students are at university level, then "White Light" by Rudy Rucker is a banger.
It explores infinity. It is perhaps the only novel which features a practical application of the Banach-Tarski paradox.
Mind, if your prospective readers are at all prudish or sensitive, then perhaps not. Whatever you do, do not suggest it as recommended reading for high-school students or below, or you'll lose your job.