Transforming general graphs

We learned how to transform the graphs of power functions xnx^n and the trigonometric function sin(x)\sin(x):

f(x)=A(xv)n+bg(x)=Asin(u(xv))+b\begin{array}{lll} f(x) &=& A(x-v)^n+b\\ g(x) &=& A\sin(u(x-v))+b \end{array}

where the parameters A,u,vA, u, v and bb tells you by how much the graph of xnx^n or sin(x)\sin(x) are stretched in yy-direction (by AA), then stretched in xx-direction (by 1/u1/u), then shifted left or right (by vv), and finally shifted up or down (by bb).

Note 1

As a side remark, note that we did not use the parameter uu (xx-direction) for the power function. We could do this, and then it would look as follows:

f(x)=A(u(xv))n+bf(x)=A(u(x-v))^n+b

The reason why this is not necessary is that we can always write

f(x)=A(u(xv))n+b=Aun(xv)n+b=A(xv)nf(x)=A(u(x-v))^n+b=Au^n(x-v)^n+b=A^\prime (x-v)^n

that is, we can replace stretching in xx-direction by 1/u1/u by the transformation stretch in yy-direction by unu^n. Think about it: draw the graph of x2x^2 and stretch in in xx-direction by the factor of 44 - it gets wider. Let's call this graph gg. But it is easy to find a value AA to stretch the graph of x2x^2 in yy-direction to obtain the same graph: A=116A=\frac{1}{16}. Indeed, for f(x)=116x2f(x)=\frac{1}{16}x^2 we get the same graph gg, as a table of values quickly shows.

We can transform any function in this way. We will discuss this in a moment, but let's first revisit the notation of a function, as this will be essential for what follows.

Note 2

Consider a function ff, say

f(x)=x24x+1f(x)=x^2-4\cdot x+1

Recall that this notation defines a machine. The xx wrapped in the brackets after the ff stands for the input of the machine ff. The algebraic formula x24x+1x^2-4\cdot x+1 determines what to do with the input to produce the output of the machine. So perhaps a more intuitive notation would be to use a container instead of the letter xx, like

f()=24+1f(\square)=\square^2-4\cdot \square+1

and whatever is in the container in f()f(\square) appears also in the containers in the formula. This container notation might resolve a lot of confusing issues surrounding the notation of functions, but alas, we tend not to use this notation. So instead of

f(1)=1241+1=2f(\boxed{1})=\boxed{1}^2-4\cdot \boxed{1}+1 = -2

we simply write

f(1)=1241+1=2f(1)=1^2-4\cdot 1+1 = -2

Importantly, if we write f(x)=theplaceholder(orvariable)f(x)= the placeholder (or variable) xindicateswheretheinputappearsintheformulaindicates where the input appears in the formulax^2-4x+1.Themeaningofthisnotationisthatevery. The meaning of this notation is that _every xintheformulaisreplacedwiththethinginthebracketsin the formula is **replaced** with the thing in the bracketsf(..)$ to dertermine the output_. For example,

f(1)=1241+1=2f(house)=house24house+1=??f(x1)=(x1)24(x1)+1=x26x+6f(sin(x))=sin(x)24sin(x)+1f()=24+1\begin{array}{lll} f(1) &=& 1^2-4\cdot 1+1 = -2\\ f(\text{house}) &=& \text{house}^2-4\cdot \text{house}+1= ??\\ f(x-1) &=& (x-1)^2-4\cdot (x-1)+1 = x^2-6x+6\\ f(\sin(x))&=&\sin(x)^2-4\cdot \sin(x)+1\\ f(\square) &=& \square^2-4\cdot \square +1 \end{array}

Notice that

  • in the third example we have to wrap the input x1x-1 into brackets in te formula, so that the input is squared: we cannot write f(x1)=x124x1+1f(x-1)=x-1^2-4\cdot x-1+1. The way we treat ++ and \cdot, this would not square the input x1x-1, only 11, and it would not multiply the input x1x-1 by 44, only xx.
  • some inputs lead to new functions, e.g. f(x1)=x26x+6f(x-1)=x^2-6x+6, so we could write g(x)=f(x1)=x26x+6g(x)=f(x-1)=x^2-6x+6
  • for some inputs, like house, the formula does not make sense in terms of adding and multiplying, but this is okey.

Let's assume we have a starting function ff, whose graph is shown below. Let's apply each type of transformation to the graph of ff and see what the function equation of the resulting graph looks like.

  1. Stretching in yy-direction by factor AA.