Jump to content
• Advertisement

# Programming and Higher Mathematics

## Recommended Posts

I've been wondering why universities require Computer Science students to take a lot of mathematics classes. What sort of things will higher mathematics such as trigonometry, calculus, etc. help me achieve with computer science? I'm especially interested in programming.

#### Share this post

##### Share on other sites
Advertisement

Well, from my perspective of 20 years which was mostly outside Game development:

• Computer programs are Logic constructs which is actually Maths. In fact, having gone to Uni into Physics, my very first Programming course was showing us how it could be done entirely as a Maths construct.
• Trignometry is essential in Games programming as a lot of what ends up as code are 2D and 3D calculations.
• Probability, Statistics and Queue Theory are essential in figuring out things like how much load peak load can be on a system or things like the likelyhood of system failure given the likelyhood of failure of each redundant sub-system. By analysing these things one can make appropriate choices when designing a system in terms of how much error margin to add or how much effort to devote to dealing with recovering from certain kinds of failures.
• A number of other Maths elements go into things like Neural Networks or Genetic Algortithms. Other complex AI techniques might involve Monte Carlo Simulations, which is a Numerical Analysis thing.
• Further Numerical Analysis might be used in things like finding formulas that fit desired points so that you create a continous curve that matches a set of desired waypoints. Or at least in understanding how Bezier curves work.
• Things like derivatives and integrals are used in simulating physical processes (so, in Game making also) as well as things like understanding how a discontinuity in the first order derivative on a surface curve would cause artifacts in specular illumination (usefull if for example you're doing mesh generation).
• If you're doing games which are simulations you probably want to know about positive and negative feedback loops and maybe some of the basic stuff that relates to Economics. The maths that relates to Economics is also used in things like multiplayer games which have some kind of Economy.
• For certain kinds of mesh/texture generation it might help to at least know what Chaos Theory is.
• Beyond that, if you're doing Tech in business domains other than Games, certain disciplines often turn out to be useful in understanding the Business and making software for it (just like Trignometry and Calculus, for example, are very important in most Game development but not at all in most other programming areas).

More in general, to me personally it always worked well to be able to understand WHY and HOW things works rather than merely use other people's code, and for that it helps to have a deep groundwork of understanding in, amongst other things, Maths.

Edited by Aceticon

#### Share this post

##### Share on other sites

An observation I can add to what Aceticon has said is this:
Higher level maths allow you to execute more effective code with less computing power.
Take the following example for instance, I want to know how much money I will have at the end of the year if I save \$100 every month.  With the lowest level maths skill I can write the following code

JanuarySavings + FebruarySavings + MarchSavings + AprilSavings + MaySavings + JuneSavings + JulySavings + AugustSavings + SeptemberSavings + OctoberSavings + NovemberSavings + DecemberSavings = YearsSavings;

With a just a touch more advanced math I could write

MonthlySavings * 12 = YearsSavings;

The illustration here being that multiplication is just a tad bit more abstract a concept as opposed to addition.  Now take into consideration all the other primitive operations you learned in highschool and apply them to your logical program and the speed and execution of your program will improve.

Advanced math is taking this same illustration to the next degree.  The more tools you have in your Mathematical Tool box the more effective and complex your programs can become.

Edited by Awoken

#### Share this post

##### Share on other sites
5 hours ago, RidiculousName said:

IWhat sort of things will higher mathematics such as trigonometry, calculus, etc. help me achieve with computer science?﻿ I'm especially interested in programming.

All of it.

#### Share this post

##### Share on other sites
6 hours ago, RidiculousName said:

I've been wondering why universities require Computer Science students to take a lot of mathematics classes.

Becouse computer is universal digits-mill. Computer able to  mill digits only. Illusion that computer able to do somethyng else comes from properly organized process of digits milling. To organize a digits-mill properly required to complitely describe mathematicaly this "something else". Really  on my first year at university we has more hours of mathemathic than any other engineering sciences students has during 5 university years, and  than we still has math hours during all 5 years.

6 hours ago, RidiculousName said:

What sort of things will higher mathematics such as trigonometry, calculus, etc. help me achieve with computer science

It just a basics required to study anything else and discover a fields of tasks that have to be implemented. Mathematic is universal language  of sciences. Any process can be described by set of differential equations. So calculus and linear algebra just a working horse required to study and discover anything else.

6 hours ago, RidiculousName said:

I'm especially interested in programming.

Programming != coding. It is kind of engeenering. Coding is just a final part. Programing language is just something like pen intended to describe a way to solve a problem (aka algo) to computer. But to describe it by code you have to find it way first. It require to describe problem mathematically first.

Edited by Fulcrum.013

#### Share this post

##### Share on other sites
6 hours ago, RidiculousName said:

I've been wondering why universities require Computer Science students to take a lot of mathematics classes. What sort of things will higher mathematics such as trigonometry, calculus, etc. help me achieve with computer science? I'm especially interested in programming.﻿

As I'm sure you'll discover, trigonometry and calculus are not exactly higher mathematics.

Those requirements are usually come from a notion that studying that kind of thing will prepare you for the other, computer science-y math that you'll have to deal with. There's a certain assumption that going into your program, you're familiar with the notations that you would learn in those subjects, eg. sigma notation for summations. They expect you to have some amount of basic knowledge going in so they don't have to drag everyone up to standard in the first year.

A lot of the "theoretical" computer science classes will essentially be discrete mathematics courses. Those are the courses where you'll learn things like basic set theory, graphs, propositional logic, and complexity theory. In addition to that, most universities require CS students to take some amount of "actual" math and statistics, of course, though typically less so than physics or engineering students might and with more choice in what specific classes to take. For instance, differential equations were not required by my program - I took linear programming and number theory instead. At the time, I was a lot more interested in systems programming, programming language theory, and compiler construction than I was anything related to the stuff the engineering faculties were doing. Looking back, I wish I had taken more abstract math courses. Abstract algebra (group theory, rings, etc.) would have been more interesting and applicable than linear programming has turned out to be, and maybe then I would actually understand that "monads" thing in Haskell.

More "practical" CS courses won't be especially math heavy - my software engineering classes barely even required arithmetic! - but you'll still use the stuff you learned in the theoretical courses. Whether those math fields are useful in your professional life will be highly dependent on what kind of work you're doing. If you're doing graphics or gameplay programming, trigonometry and linear algebra will be indispensable. If you're doing physics, calculus will be very useful. If you're doing lower-level systems development, trigonometry won't be terribly helpful (when's the last time anyone here needed to know the arc-cosine of some number when implementing a memory allocator?), but complexity theory and number theory definitely will be.

Edited by Oberon_Command

#### Share this post

##### Share on other sites
54 minutes ago, Oberon_Command said:

Whether those math fields are useful in your professional life will be highly dependent on what kind of work you're doing.

Really only university studied coursee that i never used into real developdment is a operational calculus. But main concept of it - to transform task to basis/space where it easy to solve and than transform results back used very very often

54 minutes ago, Oberon_Command said:

If you're doing graphics or gameplay programming, trigonometry and linear algebra will be indispensable.

If you have deal with robotics, CAD/CAM, physic process simulations or any other real-world related task you  will requilre it much more then for gameplay an graphics programming. Of cource theory of graph, theory of sets and many other theories required not less than calculus and lenear algebra.  And theory of complexity required anywere, becouse it applicable to any kind of tasks regardless where same algo works.

Edited by Fulcrum.013

#### Share this post

##### Share on other sites
1 hour ago, Oberon_Command said:

At the time, I was a lot more interested in systems programming, programming language theory, and compiler construction than I was anything related to the stuff the engineering faculties were doing﻿.

May be it language issue, but on slavic languages anything of it called engeenering. By other world anything related to any tech (not machinery or construction only) or ever chemistry and economy, that require to find way how to solve tasks and prove it solution by calculations/mathematical theories doing by persons that have qualification engeener of related field. For eхample engeeneer-programmer, engeneer-builder, engeneer-economist or ever engeneer-mathemathic and so on.

Edited by Fulcrum.013

#### Share this post

##### Share on other sites
8 hours ago, RidiculousName said:

I've been wondering why universities require Computer Science students to take a lot of mathematics classes. What sort of things will higher mathematics such as trigonometry, calculus, etc. help me achieve with computer science? I'm especially interested in programming.

First of all, ... trigonomy, calculus, etc. are what we studies in high school here. It's not exactly higher level of math.

Secondly... Computer Science is a branch of mathematics. These subjects might be carried over from mathematics program. It might not help you to be a good computer scientist, but since computer scientist are also kind of mathematician so you're expected to know a little bit of them....

#### Share this post

##### Share on other sites
32 minutes ago, mr_tawan said:

calculus, etc. are what we studies in high school here. It's not exactly higher level of math﻿.

Of course STEM classes of high schools here have basics of calculus like theory of limits, basics of  derivatives and integrals. But first university year studies it on much higher level than 2 years of high school. Trigonomerty really studied in secondary school

## Create an account or sign in to comment

You need to be a member in order to leave a comment

## Create an account

Sign up for a new account in our community. It's easy!

Register a new account

## Sign in

Already have an account? Sign in here.

Sign In Now

• Advertisement
• Advertisement

• ### Popular Contributors

1. 1
Rutin
28
2. 2
3. 3
4. 4
5. 5
• Advertisement

• 12
• 13
• 11
• 10
• 13
• ### Forum Statistics

• Total Topics
632953
• Total Posts
3009441
• ### Who's Online (See full list)

There are no registered users currently online

×

## Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!