I'm curious as to which books you are reading... that may help with the answer.
So, there are two different meanings for the word "routine."
One is a series of phases of an effect using the same props. Think about an Ambitious Card routine, a Cups & Balls Routine, a Coin Matrix routine or a Wildcard Routine. The common theme between those routines is that there is a variety of effects which are similar in nature performed with the same props.
The other meaning of a "routine" is a series of different effects performed in sequence. What ties the effects together is that the effects make sense to be performed in sequence and that there are logical transitions from one effect to another (i.e. avoiding the Rocky and Bullwinkle "and now for something completely different!"). For example, the same selected card can be used to tie a routine together (e.g. it turns face up in the deck, has its back change color and then teleports to the performer's shoe). The routine can build on itself by starting with a four ace production, using the produced aces with coins for a Matrix and then doing a coin trick. Another way to tie the routine together is through presentation where the effects could be presented around the same idea (e.g. about how you are just lucky or how you always lose things) or could be tied together with a singular story. In that context, I think the idea of "theme" means that the effects make sense to be performed together for some reason.