tags:

views:

8695

answers:

71

Hello all,

I happened to debate with a friend during college days whether advanced mathematics is necessary for any veteran programmer. He used to argue fiercely against that. He said that programmers need only basic mathematical knowledge from high school or fresh year college math, no more no less, and that almost all of programming tasks can be achieved without even need for advanced math. He argued, however, that algorithms are fundamental & must-have asset for programmers.

My stance was that all computer science advances depended almost solely on mathematics advances, and therefore a thorough knowledge in mathematics would help programmers greatly when they're working with real-world challenging problems.

I still cannot settle on which side of the arguments is correct. Could you tell us your stance, from your own experience?

+26  A: 

computer science != programming

OK, seriously, I know good a bad programmers who were English and Psychology majors and some that were Computer Science majors. Some very famous guys that I admire as developers didn't have a CS background. Larry Wall(Perl), for example, was a linguist. On the other hand, it helps to know something about the domain you are working on because then you can at least see if your data makes sense and help your customer/users drill down to what they really want. And yes, there's the issue of computational complexity and efficient data structures and program correctness. That's stuff you learn in Computer Science and that's useful to know in almost any domain, but it's neither necessary nor sufficient.

David Nehme
I think the best quote I've heard is "Computer science is no more about computers than astronomy is about telescopes."(Dijkstra)
tloach
I think stackoverflow.com was created basically to overcome this one-liner type of answers, yet there are 15 like-minded people who lifted up this useless answer to the top. I have nothing personal with you, however I've flagged your answer as "offensive". It is so at least to me.
simsim
@simsim: I find it offensive that people think a CS degree is somehow about programming.
tloach
@simsim: It doesn't matter what Joel and Jeff had in mind when they created this website. It's all about creating a community where programmers help each other. I think David's short answer is right on target. +1
Scottie T
simsim
A: 

I don't agree that you need advanced mathematics. I studies Physics along side Computer Science, so I had the advanced courses, but I don't think it's been necessary for any projects. The knowledge I gained before University was more than enough.

GavinCattell
A: 

Nope, don't need math. Haven't done any since I graduated, and probably forgotten what little calculus I mastered anyway.

Think of it like a car. How much math/physics do you think is behind things like traction control and ABS braking? Lots. How much math do you need to know to use those tools? None.

EDIT: One thing to add. Industry is probably important here. A programmer working at a research firm, or writing embedded traction control systems for that car, is probably far more likely to need math than your average business tool programmer.

Telos
+42  A: 

While advanced mathematics may not be required for programming (unless you are programming advanced mathematics capability) the thought process of programming and mathematics are very similar. You begin with a base of known things (axioms, previously proven theories) and try to get to someplace new. You cannot skip steps. If you do skip steps, then you are required to fill in the blanks. It's a critical thought process that makes the two incredibly similar.

Also, mathematicians and programmers both think critically in the abstract. Real world things are represented by objects and variables. The ability to translate from concrete to abstract also links the two fields.

There's a very good chance that if you're good at one, you will probably be good at the other.

Jarrett Meyer
And so you could say that someone who does a lot of crosswords or plays Scrabble is more likely to be good at programming than someone who does not. The relationship seems to be about the likelihood rather than a strict dependency.
Liam
The rigor and discipline of solving a problem in math translates to programming. You need to have the ability to deconstruct a problem and approach it from first the obvious direction, and then from more creative directions in both disciplines.
Bramha Ghosh
Two great programmers I admire a lot didn't study Computer Science, but rather were trained as mathematicians and just changed career paths: Miguel de Icaza and Alexander Stepanov. By the way, Stepanov once stated that while working on math "you don't start with axioms: you *end* up with axioms". :D
Joe Pineda
@Liam - It's about pattern matching and juggling things in memory in the short term. Both activities require those skills.
drachenstern
+3  A: 

Of course it depends on what kind of programmer you want to be, or better what kind of programmer your employers want you to be. I think calculus and algebra are essentials, statistic and linear programming is indeed a good tool to have in your briefcase, maybe analysis (derivative, integrals, functions...) could be done without. But if you want to know how things work skin-deep (electronics, for example, or some non trivial algorhytms) "advanced" math is something you'd better not go without anywhere.

Manrico Corazzi
+20  A: 

I have a maths degree, but I can't remember requiring that maths a single time in my career. It was useful in terms of training my mind for logical thinking, but I've not written any code using fluid dynamics, quantum theory or Markov Chains. (The last is the most likely to come up, I suspect.)

Most line-of-business developers won't need advanced maths most of the time. Sometimes knowing trigonometry can help, and certainly being able to understand enough maths to implement algorithms described mathematically can be important - but beyond that? Nah.

Don't forget that most programmers aren't advancing computer science - they're building applications. I don't need to know advanced engineering to drive a modern car, even though that car has almost certainly been improved through advanced engineering.

Jon Skeet
I agree with most of what you said, however, couldn't it be said that many aspects of programming can be markedly easier by understanding common math principles? Sometimes a formula for something is far easier to program than the algorithm to reach that same value...as long as you know that formula
BenAlabaster
@balabaster: Sometimes - but I'd say that doesn't happen very often. Equally, you don't really need to know a formula beforehand to use it. Being *competent* at maths is good, so you can understand formulae when you see them, but you rarely need degree-level maths itself IMO.
Jon Skeet
Math degree? Then you know it's not just numbers. I have two math degrees, and use the content often: boolean algebra to analyze/simplify logic, automata/language theory for DSL construction, algebra for big-O performance analysis, etc.
joel.neely
+12  A: 

I would argue that having advanced logic (discrete) math can really help. That along with set theory. When dealing with common computer programs, these disciplines can help a lot. However, a lot of the other math I took in university was calculus, which as far as I can see, had very limited usage. Since 90% (or something like that) of programming is doing business apps with very simple math, I would say that for the most part, you can get by with very little math knowledge. However, a good understanding of boolean algebra, logic, discrete math, and set theory can really put you up to that next level.

Kibbee
+2  A: 

Most of the programming I have done involved physics simulations for research including things like electromagnetism, quantum mechanics and structural mechanics. Since the problem domains have advanced mathematics associated with them I would be hard pressed to solve them without using advanced mathematics.

So the answer to your question is - it depends on what you are trying to do.

MikeCroucher
+4  A: 

Mathematics are needed for developers in some fields but are almost useless in others.

If you are a game developer and have to work with physics a lot - understanding of math is crucial. If you are working with advanced visual controls - you could not do much without geometry. If you're planning to do some financial calculations - it would REALLY help to have solid knowledge of statistics.

On the other hand over last 5 years I had only 2 or 3 projects where ANY amount of math was required at all. Of these there was only 1 occurrence when a Google search did not help.

At the end of the day even financial calculations are very often something your clients do for you and give you formulas to implement.

So if you're in 'applied software' business you are likely to never use your math degree. If you're in academic software maths are crucial.

Ilya Kochetov
To "game developer" I'd add "simulation developer". I remember back in '93 driving all over town trying to find a math book sufficiently advanced to explain how Quaternions work to me, so that I could properly code a dead recokining algorithm. Thank God for the Internet today!
T.E.D.
+2  A: 

Advanced maths knowledge is vital if you're going to be writing a new programming language. Or you need write your own algorithms.

However, for most day-to-day programming - from websites to insurance processing applications - only basic maths are necessary.

Oak
+6  A: 

What type of Programming? In my commercial experience, I have needed no advanced mathematics, but this is heavily dependent on the field you are in.

Computer graphics require a large amount of advanced maths. A lot of academic computer programming requires advanced maths.

So saying there tends to be a correlation between people who are good at maths and people who are good at programming.

Hope this wishy washy answer helps.

David Waters
+1  A: 

IMO, you probably need an aptitude for mathematics, without necessarily having much knowledge in the field. So the things you require to be good at maths are similar to the things you require to be good at programming.

But in general, I can't remember the last time I used any sort of advanced maths in day-to-day programming, so no.

Lehane
+1  A: 

I don't think that higher math is a requirement for being a good programmer - as always it depends on what you are coding.

Of course if you are in 3D graphics programming, you'll need matrices and stuff. As author of business software, you'll probably need statistics math.

But being a professional programmer for almost 10 years (and another 10 years amateur) "higher math" is not something that I needed regularily. In about 99.8% of all cases it's just plus, minus, division and multiplication in some intelligent combinations - in most cases it's about algorithms, not math.

BlaM
+2  A: 

Learning higher math, for most programmers, is important simply because it bends your brain to think logically, in a step-by-step manner to get from one thing to another.

Very few programming jobs, though, require anything above high school math. I've used linear algebra once. I've never used calculus. I use algebra every day.

Lucas Oman
+9  A: 

It depends on what your are doing. If you do a lot of 3D programming, 3D geometric is certainly necessary knowledge, don't you agree? ;-) If you want to create a new image format like JPG or a new audio format like MP3, you are also pretty lost if you can't understand a cosine or fourier transformation, as these are the basics most lossy compression bases on. Also many other problems can be resolved better if you know your math rather well.

For many other programming tasks you will most likely not need a lot of math.

Mecki
A: 

See also Is Programmng == Math? from stackoverflow.

While I don't think it's required for programming, I can't tell you how many times I've been able to use linear algebra concepts to write a clear and short solution to replace a convoluted (and sometimes incorrect) one. When dong any graphics or geometry (and even some solver) work, knowledge of matrices and how to work with them has also been extremely useful.

Philip Rieck
+5  A: 

Yeah, there is no need for advanced mathematics - if you are programming commercial - off the shelf software.

However when dealing with hardcore stuff such as:

  • Calculating trajectories to control a robot
  • Creating AI-like applications to support uncertainty and automatic reasoning
  • Playing with 3-D motion and graphics

Some advanced mathematics knowledge might come in handy. And it's not like they are "out-of-this world" problems.

I had to create a software to try to "predict" the necessary amount of paper for an office (and it was hell just to find out the best way to approximate values).

You have to be careful, though, because it is easy to get lost when using advanced things - there is a friend of mine who resorted to using Turing to store the state of a dynamic menu just to display it correctly - humm... perhaps he wnet too far in his imagination.

rshimoda
you could add things like compressing files or editing MP3 files or anything that requires actually understanding what the computer is doing, rather than just throwing a website together.
tloach
A: 

There are plenty of programming tasks that can be done well without a background in advanced math. It is probably safe to say the majority of programming jobs available will rarely require anything more than high school level math. But you are not going to write the software that helps put the shuttle in space by hacking away with your freshman college algebra math level. So, while advanced math is usually not vital to many programming tasks the more difficult problems will absolutely require it. Studying math also teaches valuable problem solving skills that can be used almost anywhere. I guess you could say it's not necessary most of the time, but it's certainly going to help almost all of the time.

jm4
+2  A: 

Someone with a solid mathematical (which is not merely arithmetic) or logic background will cope well with algorithms, variable use, conditional reasoning and data structures.

  • Not everyone can design a UI.
  • Not everyone can make efficient code.
  • Not everyone can comment and document clearly.
  • Not everyone can do a good algorithm

Mathematics will help you to a point, but only to a point.

Unsliced
A: 

For your general GUI and Web applications only basic mathematics knowledge will ever be needed.

Once a lifetime you might have an odd project where you need calculus or linear algebra.

(If you do 3D game programming or some other specific field of programming, you might need it everyday thou)

mliesen
+1  A: 

Mathematical knowledge is often useful to a programmer, as are graphic design skill, puzzle-solving ability, work ethic and a host of other skills and traits. Very few programmers are good at everything that a programmer can possibly be good at. I wouldn't agree with any statement of the form "you're not a real programmer unless you can {insert favorite programming ability here}".

But I would be wary of a programmer who couldn't do Math. More so than of one who couldn't draw.

MusiGenesis
+11  A: 

I'll go against the grain here and say "Yes"

I switch from Civil Engineering to programming (Concrete Sucks!). My math background consists of the usual first year stuff, second and third year Calculus(Diff EQ, volume integrations, Series, Fourier and Laplace transforms) and a Numerical Analysis course.

I find that my math is incredibly lacking for computer programming. There are entire areas of Discrete math and logic that I am missing, and I only survive due to an extensive library of textbooks, Wikipedia and Wolfram. Most advanced algorithms are based on advanced math, and I am unable to develop advanced algorithms without doing extensive research (Essentially the equivalent to a half-course worth of work.) I am certainly unable to come up with NEW algorithms, as I just don't have the mathematical foundations as the shoulders of giants upon which to stand.

chris
How many fundamental algorithms does an average programmer really write? I'd guess 80% of the programming jobs involve no math beyond basic algebra.
dbkk
+5  A: 

I agree with Chris. I would say "Yes", also. But this depends on your market as stated above. If you are simply creating some basic "off-the-shelf" applications or writing tools to help your everyday work...then math isn't nearly as important.

Engineering custom software solutions requires lots of problem solving and critical thinking. Skills that are most definitely enhanced when a mathematics background is present. I minored in Math with my Computer Engineering degree and I give credit to all of my math-oriented background as to why I'm where I am today.

That's my 2 cents, I can tell from reading above that many would not agree. I encourage all to consider that I'm not saying you can't have those skills without a math background, I'm simply stating that the skills are side-effects of having such a background and can impact software positively.

MaTT
A: 

There are some good points to this question in my opinion.

As David Nehme posted here, computer science and programming are two very different subjects.

I find it perfectly possible that a programmer with very basic high-school and early college math skills may be a competent programmer. Not so sure about the computer science graduate, though.

As you correctly pointed out, the algorithm creation process is very much related to how you crunch math. Even if this is just a result of the type of mathmatical and analytical process you must accomplish to correctly design an algorithm.

I also think it very much depends on what you're doing, more than it depends on your job description or skills. For instance, if the programming and math are both tools to produce some effect, than you surely have to be competent with both (i.e.: you are making a modelization programme for some purpose). Although, if the programming is the ultimate objective of your activity, than math is most probably not required. (i.e.: you are making a web application)

Joum
+3  A: 

I dont think advanced mathemetics knowledge is a requirement for a good programmer, but based on personal experience I think that programmers who have a better grasp at advanced maths also make better programmers. This may simply be due to a more logical mind, or a more logical outlook due to their experiences of solving mathematical problems.

+1  A: 

Programming requires you to master, or at least learn, two subjects. Programming itself and what ever domain your program is for. If you are writing accounting software, you need to learn accounting, if you are programming robot kinematics, then you need to understand forward and reverse kinematics. Account might only take basic math skills, other domains take other types of math.

Jim C
+1  A: 

It's important to keep perspective. Learning math, advanced math, calc, etc. is great for thought processes and many programming positions expect and may make use of math and math concepts. But many programming jobs use little to no math at all.

Computer science, being a math discipline, of course requires lots of math. But few programming jobs are derivatives of comp sci. CS is a very specific discipline. There is a reason why IT schools now have Software Engineering as a separate discipline from CS. They are very different fields.

Comp Sci, for example, does not prepare you well for the world of most web applications. And software engineering does not prepare you well for compiler design and kernel development.

Scott Alan Miller
A: 

If you need advanced mathematics in your daily job as programmer really depends on your tasks. I need them. The reason is I have to work with hydraulic calculations for piping systems to evaluate in code the piping system before it gets built. You never want to stand near a collapsing piping system because of under or overpressure. ;)

I guess for many other kinds of 'simulations of the real world' you will need advanced mathematics too.

Mil
A: 

Statistical machine learning techniques are becoming increasingly important.

Jamie Eisenhart
A: 

for loops are the only thing you need these days.

+1  A: 

See this earlier post

JosephStyons
A: 

Programming is a tool of Computer Science.

In many area's of Programming math is in the back seat. You don't know how to quick sort download a module to do it for you. You don't understand elliptical curves, no problem buy an AES encryption module.


Now for Computer Science. Yes you need higher level math. No doubt about it. Cryptography, Operating Systems, Compiler Construction, Machine Learning, Programming Languages, and so on all require some form of higher math (Calculus, Discrete, Linear, Complex) to fully understand.

J.J.
A: 

I feel this question (which I get quite a bit) is best answered with an analogy.

Many of us lift weights. Why? Is it because we're preparing for that day when we become a professional weightlifter? Will we ever encounter the lifting of weights as a job requirement?

Of course not. We lift weights because it exercises our muscles. It keeps us fit and in shape. A fit person will perform better in other areas: hiking, construction, running, sleeping, etc.

Learning mathematics is like weightlifting for the brain. It exercises the mind and keeps it in shape. You may never use calculus in your career, but your brain will be in better shape because of it.

Barry Brown
+5  A: 

The fundamental concept of maths is the following, devising, understanding, implementation, and use of algorithms. If you cannot do maths then it is because you cannot do these things, and if you cannot do these things then you cannot be an effective programmer.

Common programming tasks might not need any specific mathematical knowledge (e.g. you probably won't need vector algebra and calculus unless you're doing tasks like 3D graphics or physics simulations, for example), but the underlying skillsets are identical, and lack of ability in one domain will be matched by a corresponding lack of ability in the other domain.

DrPizza
A: 

business programming: arithmetic, some algebra

engineering: numerical analysis

scientific programming: the sky's the limit

Steven A. Lowe
+1  A: 

It's not required by a long shot, but...

as a trivial example--Without an understanding of geometry, you couldn't do a lot of stuff with squares and rectangles. (Every programmer has/gets geometry, so it's just an example).

Without Trig, there are certain things that are tough to do. Try to draw an analog clock with no understanding of trig--you can do it, but the process you have to go through is essentially re-inventing Trig.

Calculus is interesting. You'll probably never need it unless you design games, but calculus teaches you how to model things that act much more "Real world". For instance, if you try to model a tree falling, to get the speed right at every point along the arch you probably need a good deal of math.

On the other hand, it's just a matter of being exact. Anything you can do with calculus you can probably do with looping and approximations.

Beyond that, to make things even more life-like, you will probably need fractals and more advanced math.

If you are programming web sites and databases, you hardly need algebra 101.

Bill K
A: 

About the only useful things you can learn at university are theoretical.

Marcin
A: 

Maths is as much about a way of thinking as it is about the skills themselves. And even that lies on several levels. Someone else noted that the analytical and abstraction skills common to maths are valuable to programming and that is one level. I would also argue that there is another level which contains precise analogues that carry from one to the other - for example the set theory behind relational databases, which is all hidden by the SQL semantics.

Very often the "best" - by which I mean most performant and concise - solutions are those which have a bit of maths behind them. If you start to think about your data-oriented programming problems as matrix manipulation, which many are, you can often find novel solutions form the world of maths.

Obviously it is not necessary to be a maths expert in order to program, anyone can be taught, but it is one of the skills that is worth having - and looking for in recruits.

Simon
A: 

In some programming I imagine that math would be most helpful, but not to be a programmer. I'm lucky if I can add 2+2 without my handy dandy calculator.

Jeremy Reagan
A: 

Depends on the programming task. I would put 'take data from a database and display it on a website' style programming towards the not-so-much side and then 'video games' on the other side (i work in games and I feel like I use some random different flavor of math every day, and would probably use more if i knew more).

Jeff
+49  A: 

To answer your question as it was posed I would have to say, "No, mathematics is not necessary for programming?" However, as other people have suggested in this thread, I believe there is a correlation between understanding mathematics and being able to "think algorithmically". That is, to be able to think abstractly about quantity, processes, relationships and proof.

I started programming when I was about 9 years old and it would be a stretch to say I had learnt much mathematics by that stage. However, with a bit of effort I was able to understand variables, for loops, goto statements (forgive me, I was Vic 20 BASIC and I hadn't read any Dijkstra yet) and basic co-ordinate geometry to put graphics on the screen.

I eventually went on to complete an honours degree in Pure Mathematics with a minor in Computer Science. Although I focused mainly on analysis, I also studied quite a bit of discrete maths, number theory, logic and computability theory. Apart from being able to apply a few ideas from statistics, probability theory, vector analysis and linear algebra to programming, there was little maths I studied that was directly applicable to my programming during my undergraduate degree and the commercial and research programming I did afterwards.

However, I strongly believe the formal methods of thinking that mathematics demands — careful reasoning, searching for counter-examples, building axiomatic foundations, spotting connections between concepts — has been a tremendous help when I have tackled large and complex programming projects.

Consider the way athletes train for their sport. For example, footballers no doubt spend much of their training time on basic football skills. However, to improve their general fitness they might also spend time at the gym on bicycle or rowing machines, doing weights, etc.

Studying mathematics can be likened to weight-training or cross-training to improve your mental strength and stamina for programming. It is absolutely essential that you practice your basic programming skills but studying mathematics is an incredible mental work-out that improves your core analytic ability.

Mark Reid
Wow, 9 years old? That's pretty hardcore... I started age 11 at ***computer camp*** (lol).... Anyone start younger? Anyone pop out of the womb writing GOTOs on your placenta?
Robert Fraser
Define 'start programming' ;)
DMan
Implementing a simple version of space invaders on a Vic 20.
Mark Reid
A: 

Hmm... in the case of such subjective questions, why can't we accept more than one answer? Mark Reid has just posted an interesting reply, and while I thought that I could accept his answer alongside the one I chose earlier, the system automatically unaccepted the former.

Anyway, I kept Mark's answer as accepted to bring new blood into this question. ;)

Thanks everyone so far; I was totally impressed with the instant & focused reactions from the community.

simsim
A: 

Depends on what you do: Web developement, business software, etc I think for this kind of stuff you don't need math.

If you want to do computer graphics, audio/video processing, AI, cryptography, etc then you NEED a math background, otherwise you can simply not do it.

A: 

Two things come to mind:

  • Context is all-important. If you're a games programmer or in an engineering discipline, then math may be vital for your job. I do database and web development, therefore high school-level math is fine for me.
  • You are very likely to be reusing someone else's pre-built math code rather than reinventing the wheel, especially in fields like encryption and compression. (This may also apply if you're in games development using a third party physics tool or a 3D engine.) Having a framework of tried and tested routines for use in your programs prevents errors and potential security weaknesses - definitely a good thing.
Dave R.
A: 

Certian kinds of math I think are indispensible. For instance, every software engineer should know and understand De Morgan's laws, and O notation.

Other kinds are just very useful. In simulation we often have to do a lot of physics modeling. If you are doing graphics work, you will often find yourself needing to write coordinate transformation algorithms. I've had many other situations in my 20 year career where I needed to write up and solve simultanious linear equations to figure out what constants to put into an algorithm.

T.E.D.
+1  A: 

I used a great deal of math when I was solving problems in solid mechanics and heat transfer using computers. Linear algebra, numerical methods, etc.

I never tap into any of that knowledge now that I'm writing business applications that deliver information from relational databases to web-based user interfaces.

I still would recommend a better math background to anyone.

Discrete math is very helpful to a developer; I have no formal training in it.

I think the techniques laid out in "Programming Collective Intelligence" are far from the stuff I did as an ME and could fall into the business apps that I'm doing now. Netflix has certainly made a nice business out of it. This group intelligence stuff appears to be on the rise.

duffymo
+1  A: 

To answer the question: no.

Mathematical talent and programming talent: strong correlation, little to no causality.

One is certainly not a prerequisite for the other, and beefing up your math skills isn't going to make you a better programmer unless you're programming in one of the specialized domains where math is pretty integral (3D graphics, statistics programming, etc.)

That said, of course a math background will certainly not hurt and will greatly help you in some cases. And as others have noted the thought processes involved in mathematics and programming are quite similar; if you have an talent for one you'll probably find you have a talent for the other.

If I was going to recommend a math requirement for programmers it'd be some basic statistics. Nearly all programming jobs require a little reporting of some sort.

The need for mathematics does increase a little as you start to do more of the advanced and/or fun stuff. Games are pretty math-heavy, so are performance-critical applications where you really need to understand the costs of different algorithms.

John Booty
+1  A: 

I'm going to sit right on the fence with you here... there are a lot of good arguments both for and against, and all of most of them equally valid. So which is the right answer?

Both...depending on the situation. This isn't a case of "if you're not with us, you're against us".

There are many aspects of math that do make areas of programming much easier: geometry, algebra, trigonometry, linear equations, quadratic equations, derivatives etc. In fact a lot of the highest performance "algorithms" have mathematical principles at their heart.

As Jon pointed out, he's got a degree in maths but in the programming world he barely uses that knowledge. I propose that he does use maths far more than he probably considers, albeit unconsiously...okay, maybe not quantum mechanics, but the more basic principles. Every time we lay out a GUI we use mathematical principles to design in an aesthetically pleasing manner, we don't do that consciously - but we do do it.

In the business world, we rarely think about the maths we use in our software - and in a lot of aspects of the software we write, it's just standard algorithms to complete the same monotonous tasks to help the business world catch up with the technology that's available.

It would be quite easy to skip through a whole career without ever consciously using math in our software. However, having an understanding of maths helps make many aspects of programming simpler.

I think the question really boils down to: "Is advanced math necessary for programming?" and of course, to that question the answer is no... unless you're going to start getting into writing and/or cracking encryption algorithms (which is a fascinating subject) or working with hydraulic equations as Mil pointed out or flow control systems (as I have in the past). But I would have add that while basic math may not be necessary, it will make your life a lot easier.

BenAlabaster
A: 

I have a degree in math, and I can't say it has helped me in any way. (I develop general web apps, nothing scientific). I enjoy working with other developers with non-math degrees because they seem to think outside my "math" box and force me to do the same.

Mike K.
A: 

I admit that I have never used any advanced math in programming except in some pet projects that are about math topics.

That said, I do enjoy to working together with people that are bright enough to grok maths. Mastering complex and difficult stuff helps to get your brain into shape to solve complex and difficult programming problems.

hstoerr
+1  A: 

Necessary != Sufficient

Come on guys! the title says "necessary", I would argue that it is at best a sufficient condition to be able to program well. Just like their are many sufficient but not necessary conditions: 5 yrs experience, a CS Degree, or any scientific background.

Some could even argue that being a Poet or English major could make you a good API designer or that an Artist could be good at UI/Web programming.

But these are obviously not guarantees, just like knowing math may not make you a good programmer, but you could hack out some C++ or F# like the rest anyway...

+1  A: 

My response is absolutely not. I was/am (now unemloyed, thanks India) a computer programmer for 25+ year. And, in my whole career I NEVER encountered program LOGIC that required more than basic math skills. Unless you work with math everyday that exceeds basic math skills, the need for advanced math is nill. At the corporate level any complex math WILL be referred to a statician or mathematicain, who will provide the programmer with the necessary pseudo code, and both will collaborate in the thorough testing of the end product. Ultimately the ball is in the math nerd's court. At any level unless you're a mathmetician/statician/senior programmer the thought of having a programmer responsible for the expected results of a complex advanced math computer program is absurd, and very foolhardy.

Walter Smith
A: 

You don't need to learn math for programming.

But learning math trains you in thinking discipline. Therefore I would consider math to be good for the developers.

Vlad
You need basic, fundamental math for programming, such as addition, subtraction, multiplication and division.
Thomas Matthews
@Thomas: You can see arithmetical operations as black boxes, you don't need to study them :-)
Vlad
+2  A: 

I think it really depends on what you're trying to do, but IMHO, the CS and OS theory are more important than math here, and you really need only the math that they involve.

For example, there's a lot of CS background of scheduling theory and optimization that stands behind many schedulers in modern OSs. That is an example of something that would require some math, though not something super complicated.

But honestly, for most stuff, you don't need math. What you need is to learn the ability to think in base 2 and 16, such as the ability to mentally OR/AND. For example, if you have a byte and within that byte there are two 3-bit fields and 2 wasted bits, knowing which bits are in which fields are active when the byte value is something like 11 will make things slightly faster than having to use pen and paper.

Uri
Have you ever studied queueing theory? Have you ever studied memory managers and the statistical models that make developers choose one over the other? I don't necessarily disagree with the brunt of your answer, but your over-simplifying.
San Jacinto
@San: I'm sure that I am oversimplifying, but I think that most systems developers never need to know these things at this level. I studied it at the basic level in my first two degrees, and somewhat deeper during my Ph.D., but it was never my forte, I prefer to leave it to the experts. The OS folks I knew had math skills that blew me away.
Uri
@Uri, which I think is very valid. i think there is a need to differentiate systems programming from OS programming. Tightly woven concepts, but different nonetheless.
San Jacinto
A: 

You don't need much math. Some combinatorial thinking can help you frame and reduce a problem for fast execution. Being able to multiply is good. You're an engineer, approximations are fine.

SpecialK
A: 

I think for tasks you described not too much math is needed. but generally i think for real advanced system programming you:

  • Don't need calculus at all
  • Need good undestanding of computer internals
  • Need CS a LOT and OS theory
  • Need Discrete math (incl. algorythms and combinatorics)
Andrey
OMG, calculus helps with algorithm writing. You will need algebra to assist with scheduling algorithms. Boolean Algebra to assist with semaphores and event flags. Graph theory will help too.
Thomas Matthews
A: 

No, you don't need to know any math (except maybe binary/oct/hex/dec representations) for system programming and stuff like that.

George B.
Ahhh! Binary, octal, hex and decimal is your basic mathematics and number theory. Don't forget addition, subtraction, multiplication and division. Algebra helps with the concepts of variables and simplifying problems. There's also error propagation too.
Thomas Matthews
+10  A: 

If you find the subject fascinating enough to post this, just go ahead and start learning. The rest will come naturally.

Daniel I-S
Excellent point!
fastcodejava
+2  A: 

I began programming about the same time I entered my pre-algebra class.. So I wouldn't say math is all that important, though it can help in certain types of programming, especially functional.

I haven't taken Discrete Math yet, but I see a lot of theory stuff with programming written in a math-notation that is taught in this class.

Also, make sure you know how to calculate anything in any base, especially base 2, 8, and 16.

Also, one class that really brought home some concepts for me was this pre-programming class. We got taught unions, intersections, and all that happy stuff and It almost exactly parallels bitwise math. And we covered boolean logic very heavily. What I considered the most useful was when we learned how to reduce complex boolean statements. This was very handy:

(x|y) & (x|z) & (x|foo)

can be simplified to

x | (y & z & foo)

Which I previously did not quite grasp.

Earlz
+24  A: 

I guess I am going to be the first person to say you do need math. As others have said math is not all that important for certain aspects of development, but the fundamentals of critical thinking and structured analysis are very important.

More so, math is important in understanding a lot of the fundamentals that go into things like schedulers, optimizations, sorting, protocol management, and a number of other aspects of computers. Though the math involved from a calculation level is not complex (its mostly High school algebra) the theories and applications can be quite complex as a solid understanding of math through calculus will be of great benefit.

Can you get by without it, absolutely, and you shouldnt let a less then thorough knowledge of math hold you back, but if you had the chance, or the inclination I would study as much math as you could, calculus, numeric theory, linear algebra, combinatorics, practical applications, all of it has both practical and theoretical applications in a wide range of computer science.

I have known people who were highly successful on both sides of the fence (those without a strong focus on math, and those who went to school for physics or math), but in both groups they enjoyed numerical problems and learning about algorithms and math theory.

GrayWizardx
I second that. Though one can get by without it - will one regret his/her decision? If you expect to have even a moderately exciting/challenging job, those math skills you acquired will certainly help you.
andras
Fair enough! GrayWizardx and others: As a self-learner, what do you recommend in terms of reading materials? I was massively turned off by the murderously bad way in which math was taught to me when I was younger. I don't want to lay blame elsewhere, but math was presented viciously. Now it's time to redeem. How EASY is it to learn the math outlined here (calculus, linear algebra, Discrete Math, etc.) on your own? Is there a particular set of textbooks recommended for this approach? A college degree is not an option anymore!
Emmel
@Emmel, I actually saw "The Manga guide to Math" and "The Manga guide to Calculus" at a Barnes and Noble out there, and I know I have seen a "Complete Idiots Guide to Linear Algebra" the other day. As for actual resources, there use to be some great math websites (for students, etc) but I am not sure how many of them are still around. One thing I do every once in a while is go to a community college and "audit" the math classes (take it for pass/fail) and just get a refresher. Havent done it in 5-6 years, but it was pretty helpful the last time.
GrayWizardx
A: 

I think Math is less important as you get closer to the hardware. On the opposite math are a lot more important when you are programing for specific fields like scientific research, financial softwares, simulations and many others higher level / more abstract domains.

Yet some specific math subjects might be of interest to you like algorithms, applied mathematics or boolean algebra and discrete mathematics in general.

f4
OMG, Math is more important the closer you get to the hardware. The are Digital Signal Processors (DSP) that require Fast Fourier Transforms, Graphics chips that require matrix algebra, microprocessors that use Boolean Algebra, statistics and probability theory, physics, and etc. Hardware beckons for mathematics.
Thomas Matthews
The OP is talking about getting into system programming, not designing a CPU. And I did mention some of those..
f4
A: 

Systems programming is not rocket science :-) IMHO, any good programmer can approach system programming. However, one need to know

  • Algorithms (this requires little math, but not too much to scare a good programmer),
  • Data structures, and
  • Some (not all) domain knowledge e.g. OS, Architecture, Compilers.

I think the most sought after qualities would be to write precise code and ability go in depth, if required, in any of the above items.

BTW, this is my personal theory, YMMV; I don't consider myself a good programmer yet! :-(

ArunSaha
+1  A: 

In my experience the Math requirement for a Computer Science degree exists simply to weed out those who will fail. If you cannot pass Calculus I and II you will most definitely not pass an advanced course on compiler construction, database or operating systems theory.

Brian Teeter
Where are these mathematicians coming from? I have a degree in Computer Science and use math all the time in systems programming. Calculus will put you far ahead of those who don't have those concepts (such as using limits, Reimann (sp!) sums, Product and Summations). But aren't compiler construction, database and operating systems theory required for a Computer Science Degree? And by your statements, requires Calculus.
Thomas Matthews
@Thomas Matthews you are correct. Most schools these days offer a "learn to program" degree and call it computer science. I was woefully under-prepared for Grad. school when I went and found deep struggle the entire time until I graduated, contrasting with my very-easy undergrad.
San Jacinto
+1  A: 

Discrete math I found very helpful. I took Calculus, and there are some times it might have been very helpful too, but I don't remember any of it. For instance, the time I was trying to implement a DIS interface (which deals with things like rotational velocities and coordinate transformations). I spent a day driving all over town looking for a book to explain quaternions to me (this was pre-WWW). There was also a time I ended up needing to write a facility for some engineers to impliment n-linear interpolation. If you have no clue what that means, believe me I didn't either. Fortuntely, that was post-WWW.

My advice is to not sweat it. You may be hamstrung on a project or two, but not all that badly these days.

T.E.D.
+1  A: 

As a self taught programmer who started working on games about 30 years ago I would definitely say you need to get as much math as you can. Things like matrices, quaternions, ray tracing, particle systems, physics engines and such do require a good level of math comprehension and I only wish that I had learned all those things much earlier.

KPexEA
+4  A: 

In my experience math is required in programming, you can't get away from it. The whole of programming is based on math.

The issue is not black and white, but more colorful. The question is not whether or not you need math, but how much. The higher levels of math will give you more tools and open up your mind to different paths of though.

For example, you can program if you only known addition and subtraction. When multiplication is required, you will have to perform a lot of additions. Multiplication simplifies repetitive additions. Algebra allows one to simplify math before implementing it into programs. Linear Algebra provides tools for transforming images. Boolean Algebra provides mechanics for reducing all those if statements.

And don't forget the sibling to mathematics, Logic and Philosophy. Logic will help you make efficient use of case or switch statements. Philosophy will help you understand the thinking of the guy who wrote that code you are modifying.

Yes, you don't need much math to write programs. Some programs may require more math than others. More math knowledge will give you an advantage over those who have lesser understanding. In these times, people need every advantage they can get to obtain those jobs.

Thomas Matthews
+1  A: 

To do what you want, you do not have to know math, but you have to like it a lot.

AVB
+2  A: 

Well you generated a number of responses, and no I did not read them all. I am in the middle on this, no you certainly do not need math in order to be a programmer. Assembler vs device drivers in linux are no more or less complicated than the other and neither require math.

In no way shape or form do you need to take or pass a math class for any of this.

I will agree that the problem solving mindset for programming is quite similar to that of math solutions, and as a result math probably comes easily. or the contrary if math is hard then programming may be hard. A class or a degree or any pieces of paper or trophies are not required, going off and learning stuff, sure.

Now if you cannot convert from hex to binary to decimal quickly either in your head, on paper, or using a calculator you are going to struggle. If you want to get into networking and other things that involve timing, which kernel drivers often do but dont have to. You are going to struggle. I know of a very long list of people with math degrees and/or computer science, and/or engineering degrees that struggle with the rate calculations, bits per second, bytes per second, how much memory you need to do something, etc. To some extent it may be considered some sort of knack that some have and others have to work toward.

My bottom line is I believe in will power, if you want to learn this stuff you can and will, it is as simple as that. You dont need to take a class or spend a lot of money, linux and qemu for example can keep you busy for quite some time, different asm langauges, etc. crashable environments for kernel development, embedded, etc. You are not limited to that, but I dont believe that you have to run off and take any classes if you dont want to. If you want to then sure take some ee classes, some cs classes and some math classes..

dwelch
This isnt flame bait, but reality. Everything you need to know about digital electronics and software engineering from a programming perspective can be summed up with. 0, 1, and, or, not. those five things are what digital electronics and all programs operate on. You can build anything with a big box of fast nand gates.
dwelch
A: 

Unless you can be more specific, I'd recommend knowing Discrete Mathematics/Algorithms just the same as you would normally. Other than just 'systems programming' or 'assembly programming', are you looking to learn about hardware on a deeper level? If not, the suggestions above should be sufficient.

jgg
A: 

At the university we read the book "Concrete Mathematics" by Knuth, Graham and Patashnik. This is a math book with topics selected for computer science students. Several year later, I checked the book again and noticed that I've used every single topic in the book at least once (with the exception of Stirling numbers).

In most cases knowing some math helps to solve problems with less work, more elegant or to implement faster solutions. It also depends on the kind of work you are doing. I.e. math is more important when you concentrate on algorithms, than when you concentrate on engineering problems.

abc
+1  A: 

I work as a game programmer, in a team with artists, game designers, level designers, etc.

Having someone on the team who knows some maths is a net plus, just as it is a plus to have someone who plays all kinds of games, someone who'se a representative member of our target audience, someone who lived through some painful productions, etc.

Often, the ones who know the most maths will be programmers (sometimes game designers), because the domains are close enough. But, day to day, game programmers don't need much maths beyond 3D geometry and (sometimes) physics.

Among the maths I studied, I found statistics the most useful, though I sometimes find myself missing some concepts.

Emile