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 ...

Get Processing Creative Coding and Computational Art now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.