Math And The Computer Science Major
An anonymous reader writes "What sort of math are CS majors expected to take? Why are these classes useful? Does programming really have that much to do with math? Lineman.Net has published an article that answers these questions and more. If you are considering a CS degree, be sure to give it a look and make sure you are taking steps to prepare for your college career."
...demand more math than others. Artificial intelligence techniques, for example.
And what the article said about game programming is right on... trying writing even a simple Brickout clone without knowing basic trigonometry and you'll run into problems.
The Army reading list
I am an engineer working with programmers and one of the biggest issues I have is getting them to implement some of the complex math in their code. Many struggle with it and that is a huge problem.
Evolution or ID?
Let's assume that you are well versed in Trig and Algebra (you should have learned them both in HS). Take, at minimum:
Discrete Mathematics (some call it Applied Mathematics)
Calculus
Number Theory (Cryptography)
Linear Algebra
I have a CS degree with a math minor and have been completely surprised at how often I've used the math portion of my education in the workplace. I'd recommend taking a good mathematical modeling course as well, as it typically offers a great mix of math, engineering, and CS.
Exactly. A computer scientist's need for math is much greater than a programmer's. Coputer science is an applied mathematics. When you design an abstract algorithm and you're technical manager wants to be sure that it necessarilly terminates - it helps if you can write a formal proof - even if just for yourself.
As for what math you should take - at a minimum you should take an intro to advanced mathematics class. You'll learn like the Principle of Mathematical Induction, how to write proofs, some basic set theory stuff, etc.
Then take another math course depending on your interests. Interested in using fractals for image compression? Take a course in nonlinear dynamic systems. The point is - if your interested in something you can do with computer science, look for a math course that goes through the underlying theory.
I went through a computer science undergrad which was part of the math faculty. As such, about a third of my courses were in math... not CS, math.
At first, I thought along the same lines as many of you. Unless I got into some hardcore graphics coding, I never thought I'd use half of what I was learning. And you know what? I was right.
However, what took me a while to realize is that this conclusion does not make math courses a waste. Those math courses, full of really tough proofs and theorems, tought me how to think. Every single day I use the thought patterns that I learned in my math courses to perform my programming job much better than if I had not been exposed to those math courses.
Were the math courses hard as hell? Damn straight! Were they worth it? Definitely :)
I don't know about your experience, but I find that post bachelor research in CS to be between 5 and 20 years ahead of industry. Some of the research goes no where, but some becomes the bleeding edge, then the mainstream. Like relational databases. Started (or first written up) as a paper in 1969. If you want to see where theory hits programming, check out game development. That is where most of the new technologies first hit development and get used successfully (the game may suck, but it becomes a showcase for some new techniques). Writing code for the TMS320 (a single chip digital signal processor) is an excercise in math: you spend more time modeling the code in Matlab than you do turning the code into C or assembly.
I am also finding that graphs (not those blasted pie charts) can be useful in solving complicated problems. And some of the tasks to do, can be described with names like traveling salesman problem or minimum spanning tree. One of the first shocks I ever got in a meeting full of programmers was having to spend most of it explaining graphing algorithms and why algorithm X would solve the problem and why the proposed solution in the meeting would be a bad one. It would be hard to correctly, or quickly, solve a minimum spanning tree problem if you could not recognize it, nor understand what the algorithms were trying to solve. Education is about learning to solve problems and recognizing new situations resembling a problem you already know how to solve. Being uneducated is like only having a hammer to solve problems: you can only fix things by bashing them, good for nails, but not a good tool to use to remove screws and bolts.
It is also fun to explain to the PHB why something he asks for is totally impossible. Usually it is headbangingly painful. .1 cannot be represented as a floating point number, but that ended up being a waste of time. Or how, to answer a question he had would require a time machine.
Him: This number must be absolutely accurate, no rounding is allowed.
Me: I can write 2 numbers on your notepad here that cannot be represented the way you describe.
Him: BS, there ain't no such animal.
Me: (writing) e and pi.
Him: (scowling).
I once tried to explain how
Our society does not value intelligence, and has been actively disparaging intellectuals for 200+ years. Our country may have been founded by intellectuals, but de Tocqueville pointed out the disparagement of intellectuals back in 1835 in Democracy in America.
from there, there're cool things like "modern math", and then you should go deep--way deep: two semesters of linear algebra, graph theory, set theory, algebra, real analysis, numerical methods, mathematical logic, ohh, right, and some more calculus... as a computer science graduate student, I'm hating my self for not taking these classes as undergraduate. (well, or for taking them and not remembering too much) It's all very very useful!!
Or.. well, it should not. A lot of the responses here mirror the main conception I came across while in University. "Everyone" wants to go to University, but they really just want to learn skills easily acquired at a trade school (not that there's anything wrong with that.) Engineering or CS (notice, it isn't called Computer Programming) majors should be embarrassed to be heard complaining about learning theory. How do you think people figure out new applications? There are entire countries full of hungry people who technically, know how to program. How are you better if that's all you know, too? My assumption is that the people complaining about theory simply find it too hard to understand. Though, the complainers are right, in a way, we don't need that many folks graduating from University. They should just be in some tech school. Oh, and the more mathematics you know, the better. How come most people don't get the fact that since math is just a big glob of abstract structures, you can take different parts and apply them to any application you want?
p
- linear algebra
- graph theory
- combinatorics
- logic
- abstract algebra (very cool, and useful in a surprising number of ways)
- multi-variable calculus
- numerical analysis (I found it boring, unlike everything else on this list, but it can end up being useful)
It's likely that you will have to take courses in subjects such as differential equations (either for your school's requirements, or as prerequisites for some of the above classes), but I don't think they're particularly useful to most people in CS.-- Tim Buchheim
Wow, math was anything but the easiest thing on my university schedule. Calc I&II for Engineers were classes they used to weed out students. That said, I really value what I learned.
Calc I or better yet, a calc heavy Physics I is the kind of class that will alter how you view the world. It's a must. After that, you might not use a ton of the math you learn in university at work. That said, taking classes in how to program mathmatical algorithms greatly helps me do my job and understand how computers work.
CS students are blessed/cursed with the likelyhood that some of the math that you learn will be from your CS department. It doesn't make matrix multiplication that much more pleasant, but it is interesting to write a simple search engine algorith that matches a terms in a documents to a vector of search terms.
I disagree with you on stats class. We were allowed to use Excel to do some of the gruelling number crunching for us once we'd done a handful by hand. Now, I can't do any of it by hand from memory but I'm ok with a book. I do understand what they heck is going on with some basic stats work and have a feeling for how to go about doing some vaguely interesting analysis of things I encounter.
The number one reason to learn advanced math is so that when you sit down in a movie and they've scribbled jibberish across a chalkboard in the background, you can follow what's being done, or at very least recognize the symbols.