O'Reilly logo

Processing Creative Coding and Computational Art by Ira Greenberg

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

B MATH REFERENCE

Appendix B includes mathematical concepts and code examples that didn't quite fit within earlier sections of the book, but nonetheless could be useful and hopefully interesting for creative coding.

Algebra

We use the term literate to describe a person fluent in the use of a natural language. The term numerate describes a similar fluency with math, and algebra is first and foremost at the core of that fluency. Programming and algebra have a close relationship, as they both utilize expressions composed of symbols. Following are some handy rules and procedures fundamental to algebra and programming.

Adding negative numbers

Adding two negatives results in a larger negative:

−3+(−6)=−9

Here's another (simpler) way to write the previous ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required