Live data from Hacker News

Math For Programmers

steve-yegge.blogspot.com

21–30 of 51 posts

Re: Math For Programmers

#21
Yes, yes, yes. Discrete math is useful every single day as a programmer, unless you see absolutely no need to ever think about what's happening under the hood. Sets, combinatorics, matrices, and on and on. Everything I learned in my "discrete computational structures" course is directly applicable in my day-to-day programming life.

Re: Math For Programmers

#22
post #11
post #2

What is kind of weird is seeing Information Theory and Kolmogorov Complexity being described as "kind of new". I guess in some sense it is, but for myself in 2012 I recall first hearing about the work of both Claude Shannon and Andrey Kolmogorov as a university student in 1982 in a first year maths / CS bridging lecture called computational mathematics or some such. Pretty much everything to do with signals, compress…

Think of it this way: The mathematical capstone of most undergrad non-math-major courseloads is Calculus II, which focuses on mathematics largely developed by Newton and Leibniz, as modified by Riemann. That takes you all the way to the mid 19th Century for what little of Riemann's work the course focuses on, with the bulk (Newton's and Leibniz's contributions) coming from almost two centuries earlier.

This is a rather simplistic account. Newton and Leibniz neither started nor finished the development of calculus, they just happened to make the connection between differentiation and integration which opened up the way for the spectacular development of the subject in later years and Leibniz invented some of the notation we still use, but there was lots of progress before and lots of progress since then, especially regarding logical foundations of the subject and a big part of it is now incorporated in the undergraduate curriculum. Linear-algebra based multi-variate calculus is pretty common in universities now too and it wasn't well developed before the 20th century.

Re: Math For Programmers

#23
> For programmers, the most useful branch of discrete math is probability theory. ... What's probability theory, you ask? Why, it's counting. ...

That paragraph made my left eye twitch a little. Not a big mistake, perhaps, but what he calls probability theory is actually combinatorics. Probability theory is decidedly non-discrete (integration of density functions?) and involves only two integers: 0 and 1. (A joke).

Many people are introduced to combinatorics in the context of probability theory. It (combinatorics) can be used to compute various probabilities, but still. You wouldn't call trigonometry calculus just because a course in calculus might involve the derivative of sine and cosine, so don't confuse probability theory and combinatorics.

Re: Math For Programmers

#24
lots of physicists commenting on the article, getting annoyed that the author doesn't dig calculus.

As a physicist (turned programmer turned physicist again) I'd just like to say that I quite like the idea of a liberal arts mathematics course - I would be much better at it if I had an overview of the field, and thus knew where to look for my solutions (like I do when debugging a program under X environment or framework).

Re: Math For Programmers

#25

Yes, yes, yes. Discrete math is useful every single day as a programmer, unless you see absolutely no need to ever think about what's happening under the hood. Sets, combinatorics, matrices, and on and on. Everything I learned in my "discrete computational structures" course is directly applicable in my day-to-day programming life.

Could you recommend a book or an online course? Or anything really? As more of a self-taught programmer, I'd love to be more acquainted with the mathematics that go along with computer science, but I'm really not sure where to start. I've been waiting for khan academy's offering on the subject but it's been years and it seems like they'll never get around to it.

Re: Math For Programmers

#26

Yes, yes, yes. Discrete math is useful every single day as a programmer, unless you see absolutely no need to ever think about what's happening under the hood. Sets, combinatorics, matrices, and on and on. Everything I learned in my "discrete computational structures" course is directly applicable in my day-to-day programming life.

Could you recommend a book or an online course? Or anything really? As more of a self-taught programmer, I'd love to be more acquainted with the mathematics that go along with computer science, but I'm really not sure where to start. I've been waiting for khan academy's offering on the subject but it's been years and it seems like they'll never get around to it.

I think this book is very good. Lots of exercises and very clear. http://www.amazon.com/Discrete-Mathematics-Norman-L-Biggs/dp...

Re: Math For Programmers

#27
It's a bit short sighted to claim that trigonometry and calculus are 'only necessary for scientists'.

For example, if you write code for some user interface, you'll have a very hard time to get smooth animations if you don't understand derivatives.

Re: Math For Programmers

#28
post #15
post #12

Earlier quoted context omitted.

Yes, but if we introduced Euler's work that early trigonometry would be reduced to the study of a single equation!

But in fact there's not much more in trigonometry. I always wondered how American schools can spend whole semester on single, simple subject.

Yeah trigonometry does become pretty trivial if you're prepared to use complex numbers and some calculus. Here in the UK we were introduced to this approach later on at A-level, but still had to tackle an incredible number of "solve for the missing length/angle/area" triangle problems first.

(One thing the endless triangle problems do provide is practice at converting geometric problems into algebraic ones. But yes, too much of them I'd say.)

I guess teachers consider complex numbers an abstraction too far in order to teach applications to geometric problems. They don't want to field endless 'woah that blows my mind' type questions about i at that stage. The downside then being that you have to memorise (or read off a cheat sheet) a lot more identities in order to manipulate things algebraically. And to convince yourself of the truth of those identities you need to rely on geometric proofs, which come more naturally to some than others. Probably makes the subject more intimidating than it should be.

Re: Math For Programmers

#29
I've never found any really good resource to learn Math from.

The problem I get is that whenever I see a big equation I tend to see a few greek symbols that I have never seen before and I have literally no idea whatsoever what they mean.

At least when looking at some unfamiliar code etc I can usually tell from function and variable names approximately what something is supposed to be.

Wikipedia is hopeless for learning because the math articles seem to be more interested in being complete and accurate than being accessible. When I hit a math page on something on wikipedia it tends to link off to a whole bunch of other pages on increasingly abstract parts of Math leaving me more confused than when I started.

I'd never have time to go through all of these topics and learn them properly, if I was going to do that I'd have become a mathematician.

Khan Academy is good, but seems to focus more on the mechanical skill of doing math rather than explaining concepts.

Re: Math For Programmers

#30

I've never found any really good resource to learn Math from. The problem I get is that whenever I see a big equation I tend to see a few greek symbols that I have never seen before and I have literally no idea whatsoever what they mean. At least when looking at some unfamiliar code etc I can usually tell from function and variable names approximately what something is supposed to be. Wikipedia is hopeless for learni…

Completely agree.
Post reply on HN