Author: Paul Orland
Publisher: Manning Publications
Date: January 2021
Audience: Python developers interested in mathematics
Reviewer: Mike James
Of course you have to learn math, right?
Mathematics has suddenly become important in many branches of programming. There are good jobs for data scientists and machine learning experts. If you’re looking to update your programming, math might be what you need to add.
It is assumed that mathematicians will be good at programming, but there are many programmers who have failed math because they met bad teachers or were just told that they weren’t good at it. domain. One of the problems is that early math is mostly arithmetic and it’s often said that if you can’t do arithmetic you can’t do math – which sucks because there are calculators handhelds and computers that free you from the need to be good at arithmetic. To do math, you need to understand the ideas of geometry and know how to do algebra. All of these may look like squiggles on the page, but there are deep concepts behind it all and learning the concepts is the best way to understand squiggles.
The book covers the math you might need for 3D graphics. machine learning and simulations. So nothing about statistics and so little help if you want to do some data mining. All the examples are in Python and if you don’t speak Python, the book won’t be of much use to you because its basic premise is that programming math helps you understand. I don’t really agree with this idea. Programming the math helps demystify it and make it more real, but it often doesn’t help you understand. Being able to create a program is proof that you understand, but I’m not sure it helps. What helps though are the many, many illustrations throughout the book. Considering the topic selections, that makes sense.
The book begins with an introduction which is essentially a pep talk to help you overcome your fear of math. It also attempts to motivate you by explaining how lucrative math can be.
Part 1 is about vectors and graphics. This is probably the most intuitive subject because you can draw diagrams. It runs at less than 200 pages and covers 2D to 3D graphics complete with matrices. The approach is not very abstract and this could be a problem for some. Summary can be difficult at first, but because it summarizes everything concisely, it is easier to remember. It mainly focuses on transformations, but it also covers solving linear equations. Nothing about eigenvalues or eigenvectors, so you won’t be able to follow PCA and other similar machine learning. data processing techniques.
Part 2 is about computation and it is very basic and very focused on simulating systems with acceleration and gravity. Oddly enough, in my opinion, there is a chapter on symbolic differentiation using computer algebra packages. The book goes into great detail on how to implement symbolic math using Python – interesting but not really useful if you’re just trying to understand math. The section ends with an overview of optimization – scaling and Fourier series. The Fourier section explains how to work with audio using Python, which again is fun, but I’m not sure that’s central to the purpose of the book. It’s also in the calculation section because you need an integral to calculate a Fourier transform but I think it would be better in the vector section because what we have is an infinite dimensional vector space.
The last part is about machine learning and it’s a fairly traditional approach to introducing ideas that you’ll find in almost any introduction to the subject. The calculations explained boil down to least squares and optimization of gradient descent. Along the way, we encounter subspaces, logistic regression, and neural networks.
Overall, this is a good book in its genre. It is clearly written and contains plenty of exercises and projects to keep you busy. It might have too much stuff like this for some readers because I have no idea how long it would take for you to think the book actually worked, but it wouldn’t be fast. This is not a quick introduction to the math typically needed for graphics, simulation, and especially machine learning. If you really wanted to master any of these areas, you’d find the book short on detail. For example in the graphics section there is nothing on homogeneous coordinates (theory) and nothing on collision detection (practice). away in one of the practical topics covered. This is not a book that focuses on concepts. He prefers to give concrete examples and then emphasize the concept involved. If this is how you like to learn, then this is a book you will continue with, but know that there are many pages and a lot of work. At the end of the day, you’ll have only just begun to learn math, but that might be all you can really want.
To keep up with our coverage of books for programmers, follow @bookwatchiprog on Twitter or subscribe to the I Programmer’s Books RSS feed for daily Book Watch releases and new reviews.