We are living in the most mathematical age of all time, says professor of mathematics Rod Downey.
From online shopping and banking to non-skid braking, the massive computational power at our disposal has driven innovation in all aspects of society.
It's all based on mathematics, especially a branch of mathematics called logic.
Rutherford Medal winner Prof Downey works on computability, at the interface of maths and computer science, and has a particular interest in algorithms.
Prof Downey will speak about the significance of mathematical logic at his forthcoming Rutherford lecture which tours the country in March.
Photo: https://royalsociety.org.nz/
He says an algorithm is like a recipe - it contains a series of small logical steps, and if it works as planned you end up with a cake. He says the goal is to make algorithms as simple and efficient as possible.
Prof Downey says mathematics is about concepts and abstract ideas, rather than numbers.
"You take that abstraction and you seek to understand it," he says. "When you understand it very well then you can develop better algorithms, or you can develop better models for what you're trying to do. There's all kinds of things you can do and that's what mathematicians do - we think."
"The goal of mathematics whatever it may be is to try and build models of the universe, so you're trying to have a symbolic representation of the universe," he tells Kathryn Ryan.
By manipulating these models it allows us to better understand the wold we live in, he says.
"For example, the ancient Babylonians realised they could model building using geometries so they invented geometry to try and describe it, so you could then understand geometry by manipulating triangles."
Underpinning modern computing is logic, Prof Downey says.
"For computers, there are lots of logics associated with them, the one that works in the background is called Boolean Logic after someone called George Boole, and it's a very simple one just using true or false and that's the thing that all of these little processes are working with."
Boolean Logic, or propositional logic, is the simplest logic, he says.
"It works with propositions … if A is true then B is true, I accept that as my hypotheses, and if I tell you A is true you can conclude that B must be true.
"If I jump off the cliff then bad things happen, you can conclude that bad things will happen, it could be that bad things happen if I didn't jump off the cliff, it's the connection between the two logics, it's about analysing not the validity of the conclusions, but the validity if the reasoning between them."
Prof Downey along with computer scientist Professor Michael Fellows added to the world's understanding of algorithms with a concept they called "parameterised complexity".
It is method of understanding the complexity of algorithms based on the fact that many parameters in life are fixed, he says.
"You can model abstract situations with graphs; it might be you have a bunch of dots which we call vertices and they are connected by lines, and we call them edges, and that might represent a relationship between these two things like the dots might represent people and the edge might represent friends.
"In biology the dots might represent DNA and the edges might represent that there's a common factor. Once you understand one kind of graph it doesn't matter what the application is, it still works."
In the physical world Prof Downey and Fellows' work has been used for some varied and unlikely applications.
"It's been used to understand prostate cancer, food delivery in NSW, ear infections in the Northern Territory and it's real interesting because in the whole thing you're looking for clusters of similarities. You have something called cluster editing."
Algorithms have gone through drastic changes in the last 60 or so years, he says.
"They go back thousands of years but the whole idea of algorithmic analysis was that you'd look at these algorithms and say how long will this take and try and measure that."
When he and Prof Fellows designed a method of algorithm design which exploited known parameters, he says it came about by chance.
"We were trying to understand a very esoteric bit of maths well-quasi-ordering of finite graphs."
"It's an abstract piece of mathematics, a beautiful piece of mathematics, we loved it dearly, and we were studying this and going this is really interesting and then we gradually realised what was happening from this completely blue-sky research, well jeepers this might actually have some applications.
"All these other people around the world started applying these ideas and we thought that was lucky.
"My wife once said to me 'did I do something useful'? and I said it wasn't my fault - there's lots of science that works like that."
Mathematics is at the heart of all science today, Prof Downey says.
"All areas of science are mathematical, 150 years ago all biology was taxonomy, but now people have methods of analysing DNA, physics is mathematical."
And his passion for maths remains undimmed, he says.
"If people have a passion for something they pursue it. Roger Federer didn't become as good as he is at tennis without practising all the time, the trouble with mathematics is people get injured by it when they're young, we teach mathematics as if the only reason for learning mathematics is to know how to fill out your tax form; we don't teach literature like that.
"One of the great inventions of humankind is mathematics and it should be part of everyone's upbringing to understand that - but it's treated more as a punishment."
Professor Downey will speak about the significance of mathematical logic in his national talk tour presented by Royal Society Te Apārangi in partnership with Victoria University which runs from 19th - 28th March.
Mathematician Rod Downey. Photo: Victoria University of Wellington