How should I start with learning math required for AI [closed] - math

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 10 years ago.
Improve this question
I have studied mathematics, but that was long time ago. I have been a programmer for 8 years but when I started to study concepts in AI and data mining I find it very difficult to understand the theory.
Now I have wasted 2-3 years and I have got nothing. I need to first understand the math concepts required to learn AI and data mining.
I don't know where to start. Which books and tutorials do you recommend I should start with from the AI point of view.
How should I go about obtaining the fundamental requirements to use AI and Data Mining concepts.
EDIT:
I got this list from internet
Matrix algebra: most machine learning models are represented as matrices and vectors. Concepts like eigenvectors and singular value decomposition appear all over the place.
Bayesian statistics: probability, Bayes' rule, common distributions (e.g., beta, Dirichlet, Gaussian), etc.
Multivariable calculus: most learning techniques use gradients and Hessians at their core to fit parameters. (If you want to get fancier, study numerical optimization.)
Information theory: entropy, KL divergence, etc. Just the basics here.
In limited cases, higher-level math can be useful. E.g., to understand manifold learning, you'll want to know some basic notions from geometry and topology. Occasionally abstract algebra is used (e.g., see "expectation semirings" for learning on hyper-graphs). I would learn these as-needed, but if you have a chance to learn them early it can't hurt.
Can anyone recommend some books on those

My resource for studying math : http://www.khanacademy.org/
You will be able to find A LOT on all math fields.

I agree with #Lostdreamer that KhanAcademy.org has great material for learning various math concepts.
For an excellent introductory online course on Machine Learning I highly recommend the Machine Learning course being offered on Coursera.org. It is taught by Stanford Professor Andrew Ng You can watch the videos as many times as you need to understand the concepts.
The exercises and programming assignments help drive home the concepts.
I recommend that you register for it the next time it is offered. Here's a link to the course registration page.
Here's a link to a preview of the material in the course.
The course contains a basic review of linear algebra including basic matrix concepts that help me review this material.

I highly recoment #HeatfanJohn 's course, I've already made it, without any knoledge of AI and it turned out pretty good, the teacher is amazing and the course is extremely clear, try it!
In addition I made this other AI course in the same time as the other. This one is much more general, you will learn a bit about everything in AI and there are not any previous knowledge you should have. If you are not used to do math, this one is easier than the ML one (in ML you need to make exercises in matlab, that are sometimes a little bit tricky) but I found it more interesting for a general overview.
I highly recommend you to do both
https://www.ai-class.com/
One you become addicted to AI (you will for sure if you make this two courses!) I reccomend
Udacity, an amazing computer science free online "university". The best teacher in the world teaching you awesome things for free. If this is not awesome enough I'll tell you that the AI class teachers made this web page. One is Google's research director (Peter Norvig) and other one is the guy that made the first autonomous driving car (Sebastian Thrun). Awesome people

Related

Programmer understanding academic writings on maths [closed]

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 10 years ago.
Improve this question
I would like to know in which order I should learn different areas of maths so I can have a robust overview of all the theory in case I need something for a computer programming problem.
So I've created this mind map
I do not intend to know all those small details about how to do a certain thing (e.g. "gauss-jordan reduction"), I would rather look over an example, but then do it with math software like sage-maths or mathematica.
I would like to know, for instance, how to get to a taylor series, given the analytical function (I know it already, I am merely illustrating the kind of knowledge depth I expect).
So all I all, I want to be able to read academic articles about maths which have applicability in computer science / programming, and actually understand something from those articles, so I can use that knowledge in solving actual programming problems.
The open question is:
(a) In what order do you suggest to learn about these areas, on what areas should I insiste more?
(b) Do you see any missing areas in the mind map?
I was recommended this book in a data structures and Algorithms class a few years ago. It covers a lot of relevant areas ( probability, graphs, counting, relations, etc.) and it's free! :-)
If you want to be serious, you should get a graduate level course on computer science in a university. There is no replacement for this.
You must know basic set theory, big O, basic data structures, basic real analysis. I suggest looking at Cormen et al. 'Introduction to Algorithms', and/or Manber's 'Introduction to Algorithms: A Creative Approach'. For number theory, check Victor Shoup's book - contains far too much, but it is readable at any level.
I suggest not bothering at all with topics such as: complex analysis, functional analysis, projective/inversive geometry, control theory, mathematical physics, until you know you need them.
Instead of making your graph bigger and bigger, make it as small as possible.
There is a good book, that I think would help you to get more out of computer science research papers and dissertations. It's called "Concrete Mathematics: A foundation for Computer Science", and it's available on Amazon:
http://www.amazon.com/Concrete-Mathematics-Foundation-Computer-Science/dp/0201558025/ref=sr_1_1?s=books&ie=UTF8&qid=1341081763&sr=1-1&keywords=math+computer+science
I think this would help because it will all be relevant, and its consolidated which will help expedite the learning process.
Even if you don't have any money, just Google it and take a look at the index to get an idea of what areas you might want to learn.
And here's one more interesting book.
This is almost impossible to answer as many programming tasks require no mathematical knowledge (other than counting and basic logic) at all. If you have specific interests in an area (such as numerical linear algebra or statistics for example) then start there. Still what I would suggest is getting a good grasp of how finite precision arithmetic works. Perhaps read an introductory text on numerical analysis as this will give a good understanding of what numerical stability is. A good book on analysis of algorithms (with regards to speed and efficiency) would do no harm, and if you plan on doing any kind of mathematical programming, getting a sound knowledge of linear algebra is a very good idea. Almost everything in applied mathematics reduces to ultimately solving a linear system of equations (or doing so iteratively).
There is no right answer to be honest.

Finite element method introduction references [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 9 years ago.
Improve this question
Could you recommend some good articles/notes/tutorials on finite element method (FEM)? I don't deal with advanced math every day, so a tutorial that introduces me to math needed to understand FEM will be great.
My goal is to write my own simulation of deformable bodies (+plasticity). I must use FEM, but it will be good if I will know BEM (Boundary element method) and FDM (Finite difference method) too.
Really understanding Finite Element Methods requires quite a bit of fairly advanced mathematics; unless you have a few years to devote to the cause, let's leave that aside for now.
That said, the basic ideas underlying FEM are fairly simple if you have some experience with ODE solvers. Can you tell us some more about your background and what you really want to learn so that we can suggest some appropriate resources? Do you want to learn the underlying mathematics, or do you just want to learn some cookbook recipes for applying FEM to a certain class of problem?
Your question is unclear. I don't know what you want to know, because it's impossible to tell what you're ignorant of here.
You don't deal with advanced math every day. What do you know about the finite element method? Here are topics you'll need to know:
Statics and dynamics; how to draw free body diagrams
Solid mechanics - strength of materials, elasticity,
Continuum mechanics for large strain models: Lagrangian and Eulerian formulations
Material models - elasticity and plasticity
Partial differential equations
Method of weighted residuals and integral equations
Linear algebra
Numerical methods
Geometric modeling - CAD for geometry and meshing for FEA models
Commercial or open source packages
You don't say whether you want to use a commercial package (ANSYS, NASTRAN, ABAQUS) or something that you'll write.
As far as references go, there are lots of books available now, but they aren't easy to read or absorb. I'd recommend T.J.R. Hughes' Dover book on the subject. It's cheap and good.
But it's not easy.
I just skimmed through the paper. It looks like a survey article, with nothing new to contribute to the state of the art. It covers a lot more than just small strain plasticity of metals. I see fabric models, large strain problems, etc.
It also mentions boundary element methods and finite difference methods. Do you want to know about those, too? Boundary element methods are completely different from finite elements. The former are based on Green's function formulations; the latter use method of weighted residuals.
The paper doesn't have a great deal of depth to it, but it's very broad. What do you want to know?
I don't think it's possible for someone with so little background to write their own. A better place to start would be FENICS.
I can recommend Introduction to Finite Element Methods by Carlos A. Felippa. It is relativly easy to read.
You can find it here, the Chapters are linked on the main page.
Only the direct stiffness method is covered, think of deformations of trusses without time considerations.
It follows a very nice 'hands-on' approach with examples in Mathematica which are well suited for developer folks.
A really good introduction to FEA for beginners is "Practical Stress Analysis with Finite Elements" by Bryan J Mac Donald. This concentrates on stress analysis but shows you how the method works from both a practical and a theoretical point of view. Unlike a lot of other books it is not specific to any particular software and it is written in plain, easy-to-understand language.

Essential skills of a Data Scientist [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 8 years ago.
Improve this question
What are the relevant skills in the arsenal of a Data Scientist? With new technologies coming in every day, how does one pick and choose the essentials?
A few ideas germane to this discussion:
Knowing SQL and the use of a DB such as MySQL, PostgreSQL was great till the advent of NoSql and non-relational databases. MongoDB, CouchDB etc. are becoming popular to work with web-scale data.
Knowing a stats tool like R is enough for analysis, but to create applications one may need to add Java, Python, and such others to the list.
Data now comes in the form of text, urls, multi-media to name a few, and there are different paradigms associated with their manipulation.
What about cluster computing, parallel computing, the cloud, Amazon EC2, Hadoop ?
OLS Regression now has Artificial Neural Networks, Random Forests and other relatively exotic machine learning/data mining algos. for company
Thoughts?
To quote from the intro to Hadley's phd thesis:
First, you get the data in a form that
you can work with ... Second, you
plot the data to get a feel for what
is going on ... Third, you iterate
between graphics and models to build a
succinct quantitative summary of the
data ... Finally, you look back at
what you have done, and contemplate
what tools you need to do better in
the future
Step 1 almost certainly involves data munging, and may involve database accessing or web scraping. Knowing people who create data is also useful. (I'm filing that under 'networking'.)
Step 2 means visualisation/ plotting skills.
Step 3 means stats or modelling skills. Since that is a stupidly broad category, the ability to delegate to a modeller is also a useful skill.
The final step is mostly about soft skills like introspection and management-type skills.
Software skills were also mentioned in the question, and I agree that they come in very handy. Software Carpentry has a good list of all the basic software skills you should have.
Just to throw in some ideas for others to expound upon:
At some ridiculously high level of abstraction all data work involves the following steps:
Data Collection
Data Storage/Retrieval
Data Manipulation/Synthesis/Modeling
Result Reporting
Story Telling
At a minimum a data scientist should have at least some skills in each of these areas. But depending on specialty one might spend a lot more time in a limited range.
JD's are great, and for a bit more depth on these ideas read Michael Driscoll's excellent post The Three Sexy Skills of Data Geeks:
Skill #1: Statistics (Studying)
Skill #2: Data Munging (Suffering)
Skill #3: Visualization (Story telling)
At dataist the question is addressed in a general way with a nice Venn diagram:
JD hit it on the head: Storytelling. Although he did forget the OTHER important story: the story of why you used <insert fancy technique here>. Being able to answer that question is far and away the most important skill you can develop.
The rest is just hammers. Don't get me wrong, stuff like R is great. R is a whole bag of hammers, but the important bit is knowing how to use your hammers and whatnot to make something useful.
I think it's important to have command of a commerial database or two. In the finance world that I consult in, I often see DB/2 and Oracle on large iron and SQL Server on the distributed servers. This basically means being able to read and write SQL code. You need to be able to get data out of storage and into your analytic tool.
In terms of analytical tools, I believe R is increasingly important. I also think it's very advantageous to know how to use at least one other stat package as well. That could be SAS or SPSS... it really depends on the company or client that you are working for and what they expect.
Finally, you can have an incredible grasp of all these packages and still not be very valuable. It's extremely important to have a fair amount of subject matter expertise in a specific field and be able to communicate to relevant users and managers what the issues are surrounding your analysis as well as your findings.
Matrix algebra is my top pick
The ability to collaborate.
Great science, in almost any discipline, is rarely done by individuals these days.
There are several computer science topics that are useful for data scientists, many of them have been mentioned: distributed computing, operating systems, and databases.
Analysis of algorithms, that is understanding the time and space requirements of a computation, is the single most-important computer science topic for data scientists. It's useful for implementing efficient code, from statistical learning methods to data collection; and determining your computational needs, such as how much RAM or how many Hadoop nodes.
Patience - both for getting results out in a reasonable fashion and then to be able to go back and change it for what was 'actually' required.
Study Linear Algebra on MIT Open course ware 18.06 and substitute your study with the book "Introduction to Linear Algebra". Linear Algebra is one of the essential skill sets in data analytic in addition to skills mentioned above.

How can I learn higher-level programming-related math without much formal training? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
I haven't taken any math classes above basic college calculus. However, in the course of my programming work, I've picked up a lot of math and comp sci from blogs and reading, and I genuinely believe I have a decent mathematical mind. I enjoy and have success doing Project Euler, for example.
I want to dive in and really start learning some cool math, particularly discrete mathematics, set theory, graph theory, number theory, combinatorics, category theory, lambda calculus, etc.
My impression so far is that I'm well equipped to take these on at a conceptual level, but I'm having a really hard time with the mathematical language and symbols. I just don't "speak the language" and though I'm trying to learn it, I'm the going is extremely slow. It can take me hours to work through even one formula or terminology heavy paragraph. And yeah, I can look up terms and definitions, but it's a terribly onerous process that very much obscures the theoretical simplicity of what I'm trying to learn.
I'm really afraid I'm going to have to back up to where I left off, get a mid-level math textbook, and invest some serious time in exercises to train myself in that way of thought. This sounds amazingly boring, though, so I wondered if anyone else has any ideas or experience with this.
If you don't want to attend a class, you still need to get what the class would have given you: time in the material and lots of practice.
So, grab that text book and start doing the practice problems. There really isn't any other way (unless you've figured out how osmosis can actually happen...).
There is no knowledge that can only be gained in a classroom.
Check out the MIT Courseware for Mathematics
Also their YouTube site
Project Euler is also a great way to think about math as it relates to programming
Take a class at your local community college. If you're like me you'd need the structure. There's something to be said for the pressure of being graded. I mean there's so much to learn that going solo is really impractical if you want to have more than just a passing nod-your-head-mm-hmm sort of understanding.
Sounds like you're in the same position I am. What I'm finding out about math education is that most of it is taught incorrectly. Whether a cause or result of this, I also find most math texts are written incorrectly. Exceptions are rare, but notable. For instance, anything written by Donald Knuth is a step in the right direction.
Here are a couple of articles that state the problem quite clearly:
A Gentle Introduction To Learning
Calculus
Developing Your Intuition For
Math
And here's an article on a simple study technique that aims at retaining knowledge:
Teaching linear algebra
Consider auditing classes in discrete mathematics and proofs at a local university. The discrete math class will teach you some really useful stuff (graph theory, combinatorics, etc.), and the proofs class will teach you more about the mathematical style of thinking and writing.
I'd agree with #John Kugelman, classes are the way to go to get it done properly but I'd add that if you don't want to take classes, the internet has many resources to help you, including recorded lectures which I find can be more approachable than books and papers.
I'd recommend checking out MIT Open Courseware. There's a Maths for Computer Science module there, and I'm enjoying working through Gilbert Strang's Linear Algebra course of video lectures.
Youtube and videolectures.com are also good resources for video lectures.
Finally, there's a free Maths for CS book at bookboon.
To this list I would now add The Haskel Road to Logic, Maths, and Programming, and Conceptual Mathematics: A First Introduction to Categories.
--- Nov 16 '09 answer for posterity--
Two books. Diestel's Graph Theory, and Knuth's Concrete Mathematics. Once you get the hang of those try CAGES.
Find a good mentor who is an expert in the field who is willing to spend time with you on a regular basis.
There is a sort of trick to learning dense material, like math and mathematical CS. Learning unfamiliar abstract stuff is hard, and the most effective way to do it is to familiarize yourself with it in stages. First, you need to skim it: don't worry if you don't understand everything in the first pass. Then take a break; after you have rested, go through it again in more depth. Lather, rinse, repeat; meditate, and eventually you may become enlightened.
I'm not sure exactly where I'd start, to become familiar with the language of mathematics; I just ended up reading through lots of papers until I got better at it. You might look for introductory textbooks on formal mathematical logic, since a lot of math (especially in language theory) is based off of that; if you learn to hack the formal stuff a bit, the everyday notation might look a bit easier.
You should probably look through books on topics you're personally interested in; the inherent interest should help get you over the hump. Also, make sure you find texts that are actually introductory; I have become wary of slim, undecorated hardbacks labeled Elementary Foobar Theory, which tend to be elementary only to postdocs with a PhD in Foobar.
A word of warning: do not start out with category theory -- it is the most boring math I have ever encountered! Due to its relevance to language design and type theory, I would like to know more about it, but so far I have not been able to deal...
For a nice, scattershot intro to bits of many kinds of CS-ish math, I recommend Godel, Escher, Bach by Hofstadter (if you haven't read it already, of course). It's not a formal math book, though, so it won't help you with the familiarity problem, but it is quite inspirational.
Mathematical notation is is akin to several computer languages:
concise
exacting
based on many idioms
a fair amount of local variations and conventions
As with a computer language, you don't need to "wash the whole elephant at once": take it one part a at time.
A tentative plan for you could be
identify areas of mathematics that are interesting or important to you. (seems you already have a bit of a sense for that, CS has helped you develop quite a culture for it.)
take (or merely audit) a few formal classes in this area. I agree with several answers in this post, an in-person course, at local college is preferable, but, maybe at first, or to be sure to get the most of a particular class, first self-teaching yourself in this area with MIT OCW, similar online resources and associated books is ok/fine.
if an area of math introduces too high of a pre-requisite in terms of fluency with notation or with some underlying concept or (most often mechanical computation and transformation techniques). No problem! Just backtrack a bit, learn these foundations (and just these foundations!) and move forward again.
Find a "guru", someone that has a broad mathematical culture and exposure, not necessarily a mathematician, physics folks are good too, indeed they can often articulate math in a more practical fashion. Use this guru to guide you, as he/she can show you how the big pieces fit together.
Note: There is little gain to be had of learning mathematical notation for its own sake. Rather it should be learned in context, just like say a C# idiom is better memorized when used and when associated with a specific task, rather than learned in vacuo. A related SO posting however provides several resources to decipher and learn mathematical notation
Project Euler takes problems out of context and drops them in for people to solve them. Project Euler cannot teach you anything effectively. I think you should forget about it, if it is popular it does not mean anything. You cannot study Mathematics through Project Euler as it contains only bits and pieces(and some pretty high level pieces) that you're supposed to know in order to solve the problems. Learning mathematics means to consider a subject and a read a book about it and solving exercices or reading solutions, that's how you learn math. If it so happens that through your reading you find something that is close to some project euler thing, your luck , but otherwise Project euler is a complete waste of time. I think the time is much better invested choosing a particular branch of mathematics and studying that. Let me explain why: I solved 3 pretty advanced Projec Euler problems and they were all making appeal to knowledge from Number theory which I happened to have because i studies some part of it. I do not think Iearned anything from Project Euler, it just happened that I already knew some number theory and solved the problems.
For example, if you find out you like number theory, take H. Davenport -> Hardy & Wright -> Kenneth & Rosen's , study those.
If you like Graph Theory take Reinhard Diestel's book which is freely available and study that(or check books.google.com and find whichever is more appropriate to your taste) but don't spread your attention in 999999 directions just because Project Euler has problems ranging from dynamic programming to advanced geometry or to advanced number theory, that is clearly the wrong way to go and it will not bring you closer to your goal.
This sounds amazingly boring
Well ... Mathematics is not boring when you find some problem that you are attached to, which you like and you'd like to find the solution to, and when you have the sufficient time to reflect on it while not behind a computer screen. Mathematics is done with pen and paper mostly(yes you can use computers .. but that's not really the point).
So, if you find a real-world problem, or some programming problem that would benefit from
you knowing some advanced maths, and you know what maths you have to study , it can be motivating to learn in that way.
If you feel you are not motivated it is hard to study properly.
There is also the question of what you actually mean when you say learn. Does the learning process stop after you solved the problems at the end of the chapter of a book ? Well you decide. You can consider you have finished learning that subject, or you can consider you have not finished and read more about it. There are entire books on just one equation and variations of it.
The amount of programming-related math that you can learn without formal training is limited, but it's more than enough. But maybe you can self-teach yourself.
It all boils down to your resources and motivation.
To know mathematics you have to do mathematics not programming(project euler).
For beginning to learn category theory I recommend David Spivak's Category Theory for the Sciences (AKA Category Theory for Scientists) because its relatively comprehensible due to many examples that enable understanding by analogy and which quickly builds a foundation for understanding more abstract concepts.
It requires the ability to reason logically and an intuitive notion of what is a set. It proceeds from sets and functions through basic category theory to adjoint functors, categories of functors, sheaves, monads and an introduction to operads. Two main threads throughout are modeling databases in terms of categories and describing categories with annotated diagrams called ologs. The bibliography provides references to more advanced and specialized topics including recent papers by Dr. Spivak.
An expected outcome from reading this book is the capability of understanding category theory texts and papers written for mathematicians such as Mac Lane's Category Theory for the Working Mathematician.
In PDF format it is available from http://math.mit.edu/~dspivak/teaching/sp13/ (the dynamic version is recommended since its the most recent). The open access HTML version is available from https://mitpress.mit.edu/books/category-theory-sciences (which is recommended since it includes additional content including answers to some exercises).

Where can I find math topics and resources for programmers?

There are a few questions around that circle around this question but I feel this is different enough.
I've decided I want to improve the breadth and depth of my maths skills specifically in areas that are useful and/or interesting to programmers.
What topics should I study?
What resources do you recommend (blogs/books/online lectures...)?
I'm looking for easy to consume resources because I'll be doing this in my free time, I don't want to spend days struggling through a dense text but I want to get deeper than the surface. I've read the Yegge article on the topic (and most of the comments) which is useful but I think the voting system here will help me focus on the most useful/best resources and topics.
Edit:
I am looking to create myself a study course that I'll follow over the next few years, I'm not looking to solve a particular problem I just want to learn some new skills that will interest me and may be useful in my career in the future.
Concrete Mathematics: A Foundation for Computer Science would be my suggestion for a book that covers some advanced topics.
For an introduction to Discrete Mathematics I strongly suggest this.
I feel very lucky to have been provided this book from University
Any programmer would do well to have a solid understanding on the undergraduate level of these following math courses:
Calculus (at through multivariate calc)
Discrete Mathematics (absolutely essential)
Linear Algebra (necessary for an understanding of matrices)
Combinatorics (further development of Dicrete maths)
Introduction to Abstract Algebra (this will solidify your understanding of modulo number systems, in particular binary, octal, hex etc.). It also gives a deep understanding of set theory which is ubiquitous in practical programming and the comp sci literature.
This is the fundamentals. If your are thinking about graphics or game programming then you have a whole slew of additional courses in physics, graphic arts, and possibly fluid dynamics. Also Differential Geometry is essential for any real world modeling of motion on curved surfaces.
It's a bit off from your question, but let me suggest the Princeton Companion to Mathematics.
It gives an overview of all of mathematics, so it is more than "math useful to programmers", but it's style is as easy to understand as it gets, and the important parts are in there.
Some time ago Steve Yegge wrote a dedicated article about math for programmers. His thesis is: As a programmer you should learn math but you should do so in different way than in shool/university.
His summary is this:
Math is a lot easier to pick up after you know how to program. In fact, if you're a halfway decent programmer, you'll find it's almost a snap.
They teach math all wrong in school. Way, WAY wrong. If you teach yourself math the right way, you'll learn faster, remember it longer, and it'll be much more valuable to you as a programmer.
Knowing even a little of the right kinds of math can enable you do write some pretty interesting programs that would otherwise be too hard. In other words, math is something you can pick up a little at a time, whenever you have free time.
Nobody knows all of math, not even the best mathematicians. The field is constantly expanding, as people invent new formalisms to solve their own problems. And with any given math problem, just like in programming, there's more than one way to do it. You can pick the one you like best.
Math is... ummm, please don't tell anyone I said this; I'll never get invited to another party as long as I live. But math, well... I'd better whisper this, so listen up: (it's actually kinda fun.)
Sad note: Steve abandoned his blog because of too much aggressive feedback.
If you have any interest in game development, 3D graphics, or anything somewhat related to those, then do multivariate calculus and basic physics. This will help you understand the basic concepts much better. Also, linear algebra will help immensely with all of the matrix/vector stuff you will be doing.
If you are NOT interested in these topics, I would still say study calculus and physics. Why? Solving calculus and physics problems gives you good experience in problem solving and exercises the brain. Programmers NEED to be good problem solvers... that is our job. Concepts you pick up from these courses are things you will keep with you the rest of your life.
MIT and Stanford both have really good online courses for topics such as this. Of course you can't just jump into multivariate calculus without some more basic calc, but MIT and Stanford have resources for your basic calculus classes as well. Basic physics will be a little bit easier to pick up. Again, you can check MIT and Stanford for physics.
MIT OpenCourseWare:
Single Variable Calculus
Calculus
Multivariable Calculus
Physics I: Classical Mechanics
Mathematics for Computer Science
Generally speaking, the applications of math to computer programming are pretty domain-specific - that is, you need to know whatever math the specific program you're writing requires. The only mathematical topics I can think of that are generally applicable to all kinds of programming are simple arithmetic and boolean logic, but I think if you didn't already know those you wouldn't be much of a programmer ;-)
Basically, I would just recommend learning the math as needed for whatever project you're working on. If you want to give yourself a good excuse to learn some new math, start a hobby program that does something mathematical.
As for topics, look at some of the answers here. Recommended ressources are difficult for me to give, I'm German speaking. I would recommend starting with linear algebra and geometry, which you will find in computer graphics. Look at the undergraduate math series by Springer for example.
Number theory doesn't have many direct applications to programming (though there are some neat tricks you can use for optimization), but there are several basic concepts that make cryptology much easier to study.
My number theory class used Silverman's Friendly Introduction to Number Theory, which is one of the best math textbooks I've ever seen. It's very easy to read (the title is entirely accurate about its friendliness), but covers a wide range of topics. Silverman is also an author on my cryptography textbook, An Introduction to Mathematical Cryptography. It's more technical, addresses most areas of cryptography, and provides plenty of references for where to find more detail.
Consider Knuth's Art of Computer Programming series. It can get dense, but it will ground you in the math most needed for programming. I'd suggest going for the available fascicles of Volume 4 early on. These books are not for everybody, but if you find them interesting you will learn a whole lot.
They won't teach you calculus or geometry, which are important in many aspects of programming but tend to be more specialized.
I think you should dive into whatever interests you most and in order to find out what that is you should get some books which cover the facts and offer orientation and some books which nurture your motivation and curiosity. You really have to dive into it to find out, it's a pretty individual thing imho.
Facts / Orientation:
Donald Knuth -
Bronstein, Semendjajew
The Science of Programming -
Data Structures and Algorithms
Motivation / Curiosity:
The Road to Reality -
Fermat's Last Theorem -
Godel, Escher, Bach
Also for motivation on the more practical side:
projecteuler.net
What sorts of math problems do you want to solve? 'Math' is a pretty big area!
MIT has some online courses, but that's probably a big time investment.
Wolfram has some tutorials, but again, you need to know what you're looking for.

Resources