# Multivariable Functions

Sometimes we think of functions as little **machines** that turn an input number into an output number.

But to a mathematician, a function doesn't *need* to take one input and give one output. Some functions take **two numbers as input** and give one number as output.

## Multivariable Equations

Evaluating a function like $f(x, y) = x^2 + y^2$ works the same way as evaluating a familiar 2D function. To find $f(3, 4)$, you replace each x with 3 and each y with 4.

^{2}+

^{2}= 25

**Watch out!** Unlike what we're used to, y is an *input* to this function, not the output.

#### Let's practice!

If $f(x, y) = 5x - y^2$ then $f(3, 2) =$ ?

## Multivariable Tables

The table for a multivariable function has two (or more) inputs and one output. For example, consider this function that calculates the cost of a rental car at $25/day + $0.14/mile.

x Days | 1 | 2 | 1 | 3 | 4 |
---|---|---|---|---|---|

y Miles | 30 | 65 | 24 | 92 | 105 |

$f(x, y)$ Price ($) | 29.2 | 59.1 | 28.36 | 87.88 | 114.7 |

#### Let's practice!

Complete the following table for the function $f(a, b) = 2ab$

## Multivariable Graphs

A normal function with one input and one output is graphed on two axes, usually x and y.

With a multivariable function, we have more than one input, so we need to add a third axis. This makes a 3D graph.