Unfortunately, at least in my experience, most textbooks are rather unfriendly for self-teaching (including the ones very frequently recommended), especially in the more theoretical fields like algorithms, theory of computation etc. (no solutions to exercises, not enough worked out examples, general strong reliance on classroom usage), it takes a long time to find good ones and even then a very long time to get to a decent speed in a new field, surely much longer then when taking a course. Thus I would recommend relying more on some online courses at least initially:
http://aduni.org/courses/ - Good discrete mathematics, algorithms, theory of computation courses (I recommend "taking" them in this order) without assuming any prerequisites
I think almost everyone with some programming experience should be able to work through them in the sequence listed in one year perhaps, at a satisfying level of detail. At the same time, many people programming professionally lack mastery of this basic material.
http://ocw.mit.edu/courses/electrical-engineering-and-comput... - Very good course covering the most crucial theoretical things every programmer should now
http://aduni.org/courses/ - Good discrete mathematics, algorithms, theory of computation courses (I recommend "taking" them in this order) without assuming any prerequisites
http://ocw.mit.edu/courses/electrical-engineering-and-comput... - More sophisticated "CS 101" kind of course
I think almost everyone with some programming experience should be able to work through them in the sequence listed in one year perhaps, at a satisfying level of detail. At the same time, many people programming professionally lack mastery of this basic material.