Table of Contents

Polynomial Expansions


\begin{eqnarray*}
(x+y)^{2} &=& x^2 + y^2 + x*y & \\
(x+y)^{3} &=& x^{3}+3*x^{2}*y+3*x*y^{2}+y^{3}

\end{eqnarray*}

Binomial Formula


(x+y)^{n} &=& C_{0}^{n}{x}y^{0}+C_{1}^{n}{x}{y}+C_{2}^{n}{x}y^{2} + ... + C_{n}^{n-1}{x^1}{y^{n-1}}+C_{n}^{n}x^{0}y^{n}

Linearly Map a Value in a Range into another Range

Given a value $s$ such that $s \in [a_{1},a_{2}]$ we can map $s$ onto a different range such that $s \in [b_{1}, b_{2}]$ by using the formula:

\begin{eqnarray*}
t &=& b_{1} + \frac{(s-a_{1})(b_{2}-b_{1})}{a_{2}-a_{1}}
\end{eqnarray*}

Implementations