Lesson Objectives
• Learn how to apply a vertical stretch to a graph
• Learn how to apply a vertical compression to a graph
• Learn how to apply a horizontal stretch to a graph
• Learn how to apply a horizontal compression to a graph

## How to Apply a Stretch or Compression to a Graph

When working with functions, we will often encounter the topic of graphing transformations. These transformations give us a way to graph a given function by altering the graph of a related function.

### Vertical Stretch or Compression

When we talk about stretching or compressing a graph vertically, we can use the following formula: $$g(x)=a \cdot f(x)$$ if |a| > 1:
The graph is vertically stretched.
if 0 < |a| < 1:
The graph is vertically compressed or shrunk.
Let's look at an example.
Example #1: Describe the transformation from f(x) to g(x). $$f(x)=\frac{1}{x}$$ $$g(x)=\frac{3}{x}$$ Since g(x) =  3 • f(x), we can say that compared to the graph of f(x), g(x) has been vertically stretched by a factor of 3.
Example #2: Describe the transformation from f(x) to g(x). $$f(x)=x^3$$ $$g(x)=\frac{1}{2}x^3$$ Since g(x) =  1/2 • f(x), we can say that compared to the graph of f(x), g(x) has been vertically compressed by a factor of 2.

### Horizontal Stretch or Compression

When we think about a horizontal stretch or compression, we can use the following rule: $$g(x)=f(ax)$$ If |a| > 1:
The graph is horizontally compressed.
If 0 < |a| < 1:
The graph is horizontally stretched. Let's look at an example.
Example #3: Describe the transformation from f(x) to g(x). $$f(x)=\frac{1}{x}$$ $$g(x)=\frac{1}{3x}$$ Since g(x) =  f(3x), we can say that compared to the graph of f(x), g(x) has been horizontally compressed by a factor of 3.

#### Skills Check:

Example #1

Describe the transformation from f(x) to g(x). $$f(x)=x^2$$ $$g(x)=\frac{1}{2}x^2$$

A
Vertically stretched by a factor of 2
B
Vertically stretched by a factor of 4
C
Vertically compressed by a factor of 2
D
Horizontally compressed by a factor of 1/2
E
Horizontally stretched by a factor of 2

Example #2

Describe the transformation from f(x) to g(x). $$f(x)=\sqrt{x}$$ $$g(x)=\sqrt{\frac{1}{2}x}$$

A
Vertically stretched by a factor of 2
B
Vertically stretched by a factor of 1/2
C
Vertically compressed by a factor of 2
D
Horizontally compressed by a factor of 2
E
Horizontally stretched by a factor of 2

Example #3

Describe the transformation from f(x) to g(x). $$f(x)=\sqrt{x}$$ $$g(x)=\sqrt{3x}$$

A
Vertically stretched by a factor of 1/3
B
Vertically stretched by a factor of 3
C
Vertically compressed by a factor of 1/3
D
Horizontally compressed by a factor of 3
E
Horizontally stretched by a factor of 3