Skip to content Skip to navigation Skip to collection information

OpenStax_CNX

You are here: Home » Content » Physics for K-12 » Transformation of graphs

Navigation

Table of Contents

Recently Viewed

This feature requires Javascript to be enabled.
 

Transformation of graphs

Module by: Sunil Kumar Singh. E-mail the author

Summary: Solving problems is an essential part of the understanding process.

Transformation of graphs means changing graphs. This generally allows us to draw graphs of more complicated functions from graphs of basic or simpler functions by applying different transformation techniques. It is important to emphasize here that plotting a graph is an extremely powerful technique and method to know properties of a function such as domain, range, periodicity, polarity and other features which involve differentiability of a function. Subsequently, we shall see that plotting enables us to know these properties more elegantly and easily as compared to other analytical methods.

Graphing of a given function involves modifying graph of a core function. We modify core function and its graph, applying various mathematical operations on the core function. There are two fundamental ways in which we operate on core function and hence its graph. We can either modify input to the function or modify output of function.

Broad categories of transformation

  • Transformation applied by modification to input
  • Transformation applied by modification to output
  • Transformation applied by modulus function
  • Transformation applied by greatest integer function
  • Transformation applied by fraction part function
  • Transformation applied by least integer function

We shall cover first transformation in this module. Others will be taken up in other modules.

Important concepts

Graph of a function

It is a plot of values of function against independent variable x. The value of function changes in accordance with function rule as x changes. Graph depicts these changes pictorially. In the current context, both core function and modified function graphs are plotted against same independent variable x.

Input to the function

What is input to the function? How do we change input to the function? Values are passed to the function through argument of the function. The argument itself is a function in x i.e. independent variable. The simplest form of argument is "x" like in function f(x). The modified arguments are "2x" in function f(2x) or "2x-1" in function f(2x-1). This changes input to the function. Important to underline is that independent variable x remains what it is, but argument of the function changes due to mathematical operation on independent variable. Thus, we modify argument though mathematical operation on independent variable x. Basic possibilities of modifying argument i.e. input by using arithmetic operations on x are addition, subtraction, multiplication, division and negation. In notation, we write modification to the input of the function as :

Argument/input = b x + c ; b , c R Argument/input = b x + c ; b , c R

These changes are called internal or pre-composition modifications.

Output of the function

A modification in input to the graph is reflected in the values of the function. This is one way of modifying output and hence corresponding graph. Yet another approach of changing output is by applying arithmetic operations on the function itself. We shall represent such arithmetic operations on the function as :

a f x + d ; a , d R a f x + d ; a , d R

These changes are called external or post-composition modifications.

Arithmetic operations

Addition/subtraction operations

Addition and subtraction to independent variable x is represented as :

x + c ; c R x + c ; c R

The notation represents addition operation when c is positive and subtraction when c is negative. In particular, we should underline that notation “bx+c” does not represent addition to independent variable. Rather it represents addition/ subtraction to “bx”. We shall develop proper algorithm to handle such operations subsequently. Similarly, addition and subtraction operation on function is represented as :

f(x) + d ; d R f(x) + d ; d R

Again, “af(x) + d” is addition/ subtraction to “af(x)” not to “f(x)”.

Product/division operations

Product and division operations are defined with a positive constant for both independent variable and function. It is because negation i.e. multiplication or division with -1 is a separate operation from the point of graphical effect. In the case of product operation, the magnitude of constants (a or b) is greater than 1 such that resulting value is greater than the original value.

b x ; | b | > 1 for independent variable b x ; | b | > 1 for independent variable a f x ; | a | > 1 for function a f x ; | a | > 1 for function

The division operation is eqivalent to product operation when value of multiplier is less than 1. In this case, magnitude of constants (a or b) is less than 1 such that resulting value is less than the original value.

b x ; 0 < | b | < 1 for independent variable b x ; 0 < | b | < 1 for independent variable a f x ; 0 < | a | < 1 for function a f x ; 0 < | a | < 1 for function

Negation

Negation means multiplication or division by -1.

Effect of arithmetic operations

Addition/ subtraction operation on independent variable results in shifting of core graph along x-axis i..e horizontally. Similarly, product/division operations results in scaling (shrinking or stretching) of core graph horizontally. The change in graphs due to negation is reflected as mirroring (across y–axis) horizontally. Clearly, modifications resulting from modification to input modifies core graph horizontally. Another important aspect of these modification is that changes takes place opposite to that of operation on independent variable. For example, when “2” is added to independent variable, then core graph shifts left which is opposite to the direction of increasing x. A multiplication by 2 shrinks the graph horizontally by a factor 2, whereas division by 2 stretches the graph by a factor of 2.

On the other hand, modification in the output of function is reflected in change in graphs along y-axis i.e. vertically. Effects such as shifting, scaling (shrinking or stretching) or mirroring across x-axis takes place in vertical direction. Also, the effect of modification in output is in the direction of modification as against effects due to modifications to input. A multiplication of function by a positive constant greater than 1, for example, stretches the graph in y-direction as expected. These aspects will be clear as we study each of the modifications mentioned here.

Forms of representation

There is a bit of ambiguity about the nature of constants in symbolic representation of transformation. Consider the representation,

a f b x + c + d ; a , b , c R a f b x + c + d ; a , b , c R

In this case "a", "b", "c" and "d" can be either positive or negative depending on the particular transformation. A positive "d" means that graph is shifted up. On the other hand, we can specify constants to be positive in the following representation :

± a f ± b x ± c ± d ; a , b , c > 0 ± a f ± b x ± c ± d ; a , b , c > 0

The form of representation appears to be cumbersome, but is more explicit in its intent. It delinks sign from the magnitude of constants. In this case, the signs preceding positive constants need to be interpreted for the nature of transformation. For example, a negative sign before c denotes right horizontal shift. It is, however, clear that both representations are essentially equivalent and their use depends on personal choice or context. This difference does not matter so long we understand the process of graphing.

Transformation of graph by input

Addition and subtraction to independent variable

In order to understand this type of transformation, we need to explore how output of the function changes as input to the function changes. Let us consider an example of functions f(x) and f(x+1). The integral values of inedependent variable are same as integral values on x-axis of coordinate system. Note that independent variable is plotted along x-axis as real number line. The integral x+1 values to the function f(x+1) - such that input values are same as that of f(x) - are shown on a separate line just below x-axis. The corresponding values are linked with arrow signs. Input to the function f(x+1) which is same as that of f(x) corresponds to x which is 1 unit smaller. It means graph of f(x+1) is same as graph of f(x), which has been shifted by 1 unit towards left. Else, we can say that the origin of plot (also x-axis) has shifted right by 1 unit.

Figure 1: Each element of graph is shifted left by same value.
Shifting of graph parallel to x-axis
 Shifting of graph parallel to x-axis  (t11a.gif)

Let us now consider an example of functions f(x) and f(x-2). Input to the function f(x-2) which is same as that of f(x) now appears 2 unit later on x-axis. It means graph of f(x-2) is same as graph of f(x), which has been shifted by 2 units towards right. Else, we can say that the origin of plot (also x-axis) has shifted left by 2 units.

Figure 2: Each element of graph is shifted right by same value.
Shifting of graph parallel to x-axis
 Shifting of graph parallel to x-axis  (t12a.gif)

The addition/subtraction transformation is depicted symbolically as :

y = f x y = f x ± | a | ; | a | > 0 y = f x y = f x ± | a | ; | a | > 0

If we add a positive constant to the argument of the function, then value of y at x=x in the new function y=f(x+|a|) is same as that of y=f(x) at x=x-|a|. For this reason, the graph of f(x+|a|) is same as the graph of y=f(x) shifted left by unit “a” in x-direction. Similarly, the graph of f(x-|a|) is same as the graph of y=f(x) shifted right by unit “a” in x-direction.

1 : The plot of y=f(x+|a|); is the plot of y=f(x) shifted left by unit “|a|”.

2 : The plot of y=f(x-|a|); is the plot of y=f(x) shifted right by unit “|a|”.

We use these facts to draw graph of transformed function f(x±a) by shifting graph of f(x) by unit “a” in x-direction. Each point forming the plot is shifted parallel to x-axis (see quadratic graph showm in the of figure below). The graph in the center of left figure depicts monomial function y = x 2 y = x 2 with vertex at origin. It is shifted right by “a” units (a>0) and the function representing shifted graph is y = x a 2 y = x a 2 . Note that vertex of parabola is shifted from (0,0) to (a,0). Further, the graph is shifted left by “b” units (b>0) and the function representing shifted graph is y = x + b 2 y = x + b 2 . In this case, vertex of parabola is shifted from (0,0) to (-b,0).

Figure 3: Each element of graph is shifted by same value.
Shifting of graph parallel to x-axis
 Shifting of graph parallel to x-axis  (t1.gif)

Example 1

Problem : Draw graph of function 4 y = 2 x 4 y = 2 x .

Solution : Given function is exponential function. On simplification, we have :

y = 2 - 2 X 2 x = 2 x - 2 y = 2 - 2 X 2 x = 2 x - 2

Here, core graph is y = 2 x y = 2 x . We draw its graph first and then shift the graph right by 2 units to get the graph of given function.

Figure 4: Each element of graph is shifted by same value.
Shifting of exponential graph parallel to x-axis
 Shifting of exponential graph parallel to x-axis  (t3.gif)

Note that the value of function at x=0 for core and modified functions, respectively, are :

y = 2 x = 2 0 = 1 y = 2 x = 2 0 = 1

y = 2 x - 2 = 2 - 2 = 1 4 = 0.25 y = 2 x - 2 = 2 - 2 = 1 4 = 0.25

Multiplication and division of independent variable

Let us consider an example of functions f(x) and f(2x). The integral values of independent variable are same as integral values on x-axis of coordinate system. Note that independent variable is plotted along x-axis as real number line. The integral 2x values to the function f(2x) - such that input values are same as that of f(x) - are shown on a separate line just below x-axis. The corresponding values are linked with arrow signs. Input to the function f(2x) which is same as that of f(x) now appears closer to origin by a factor of 2. It means graph of f(2x) is same as graph of f(x), which has been shrunk by a factor 2 towards origin. Else, we can say that x-axis has been stretched by a factor 2.

Figure 5: The graph shrinks towards origin.
Multiplication of independent variable
 Multiplication of independent variable  (t13.gif)

y = f x y = f b x ; | b | > 1 y = f x y = f b x ; | b | > 1

Let us consider another example of functions f(x) and f(x/2). The integral values of independent variable are same as integral values on x-axis of coordinate system. Note that independent variable is plotted along x-axis as real number line. The integral x/2 values to the function f(x/2) - such that input values are same as that of f(x) - are shown on a separate line just below x-axis. The corresponding values are linked with arrow signs. Input to the function f(x/2) which is same as that of f(x) now appears away from origin by a factor of 2. It means graph of f(x/2) is same as graph of f(x), which has been stretched by a factor 2 away from origin. Else, we can say that x-axis has been shrunk by a factor 2.

Figure 6: The graph stretches away from origin.
Multiplication of independent variable
 Multiplication of independent variable  (t14.gif)

y = f x y = f x b ; | b | > 1 y = f x y = f x b ; | b | > 1

Important thing to note about horizontal scaling (shrinking or stretching) is that it takes place with respect to origin of the coordinate system and along x-axis – not about any other point and not along y-axis. What it means that behavior of graph at x=0 remains unchanged. In equivalent term, we can say that y-intercept of graph remains same and is not affected by scaling resulting from multiplication or division of the independent variable.

Negation of independent variable

Let us consider an example of functions f(x) and f(-x). The integral values of independent variable are same as integral values on x-axis of coordinate system. Note that independent variable is plotted along x-axis as real number line. The integral -x values to the function f(-x) - such that input values are same as that of f(x) - are shown on a separate line just below x-axis. The corresponding values are linked with arrow signs. Input to the function f(-x) which is same as that of f(x) now appears to be flipped across y-axis. It means graph of f(-x) is same as graph of f(x), which is mirror image in y-axis i.e. across y-axis.

Figure 7: The graph flipped across y. -axis.
Negation of independent variable
 Negation of independent variable  (t15.gif)

The form of transformation is depicted as :

y = f x y = f - x y = f x y = f - x

A graph of a function is drawn for values of x in its domain. Depending on the nature of function, we plot function values for both negative and positive values of x. When sign of the independent variable is changed, the function values for negative x become the values of function for positive x and vice-versa. It means that we need to flip the plot across y-axis. In the nutshell, the graph of y=f(-x) can be obtained by taking mirror image of the graph of y=f(x) in y-axis.

While using this transformation, we should know about even function. For even function. f(x)=f(-x). As such, this transformation will not have any implication for even functions as they are already symmetric about y-axis. It means that two parts of the graph of even function across y-axis are image of each other. For this reason, y=cos(-x) = cos(x), y = |-x|=|x| etc. The graphs of these even functions are not affected by change in sign of independent variable.

Example 2

Problem : Draw graph of y=cosec(-x) function

Solution : The plot is obtained by plotting image of core graph y=cosec(x) in y axis.

Figure 8: The transformed graph is image of core graph in y-axis.
Changing sign of the argument of graph
 Changing sign of the argument of graph  (t8a.gif)

Combined input operations

Certain function are derived from core function as a result of multiple arithmetic operations on independent variable. Consider an example :

f x = - 2 x - 2 f x = - 2 x - 2

We can consider this as a function composition which is based on identity function f(x) = x as core function. From the composition, it is apparent that order of formation consists of operations as :

(i) f(2x) i.e. multiply independent variable by 2 i.e. shrink the graph horizontally by half.

(ii) f(-2x) i.e. negate independent variable x i.e. flip the graph across y-axis.

(iii) f(-2x-2) i.e. subtract 2 from -2x.

This sequence of operation is not correct for the reason that third operation is a subtraction operation to -2x not to independent variable x, whereas we have defined transformation for subtraction from independent variable. The order of operation for transformation resulting from modifications to input can, therefore, be determined using following considerations :

1 : Order of operations for transformation due to input is opposite to the order of composition.

2 : Precedence of addition/subtraction is higher than that of multiplication/division.

Keeping above two rules in mind, let us rework transformation steps :

(i) f(x-2) i.e. subtract 2 from independent variable x i.e. shift the graph right by 2 units.

(ii) f(2x-2) i.e. multiply independent variable x by 2 i.e. shrink the graph horizontally by half.

(iii) f(-2x-2) i.e. negate independent variable i.e. flip the graph across y-axis.

This is the correct sequence as all transformations involved are as defined. The resulting graph is shown in the figure below :

Figure 9: Operations are carried in sequence.
Graph of transformed function
 Graph of transformed function  (t16.gif)

It is important the way graph is shrunk horizontally towards origin. Important thing is to ensure that y-intercept is not changed. It can be seen that function before being shrunk is :

f x = x - 2 f x = x - 2

Its y-intercept is 2. When the graph is shrunk by a factor by 2, the function is :

f x = 2 x - 2 f x = 2 x - 2

The y-intercept is again 2.The graph moves 1 unit half of x-intercept towards origin. Further, we can verify validity of critical points like x and y intercepts to ensure that transformation steps are indeed correct. Here,

x = 0, y = - 2 X 0 2 = - 2 x = 0, y = - 2 X 0 2 = - 2 y = 0, x = - y + 2 2 = - 2 2 = - 1 y = 0, x = - y + 2 2 = - 2 2 = - 1

We can decompose a given function in more than one ways so long transformations are valid as defined. Can we rewrite function as y = f{-2(x+1)}? Let us see :

(i) f(2x) i.e. multiply independent variable x by 2 i.e. i.e. shrink the graph horizontally by half.

(ii) f(-2x) i.e. negate independent variable i.e. flip the graph across y-axis.

(iii) f{-2(x+1} i.e. add 1 to independent variable x x i.e. shift the graph left by 1 unit.

This decomposition is valid as transformation steps are consistent with the transformations allowed for arithmetic operations on independent variable.

Figure 10: Operations are carried in sequence.
Graph of transformed function
 Graph of transformed function  (t17.gif)

Horizontal shift

We have discussed transformation resulting in horizontal shift. In the simple case of operation with independent variable alone, the horizontal shift is “c”. In this case, transformation is represented by f(x+c). What is horizontal shift for more general case of transformation represented by f(bx+c)? Let us rearrange argument of the function,

f b x + c = f { b x + c b } f b x + c = f { b x + c b }

Comparing with f(x+c), horizontal shift is given by :

Horizontal shift = c b Horizontal shift = c b

Collection Navigation

Content actions

Download:

Collection as:

PDF | EPUB (?)

What is an EPUB file?

EPUB is an electronic book format that can be read on a variety of mobile devices.

Downloading to a reading device

For detailed instructions on how to download this content's EPUB to your specific device, click the "(?)" link.

| More downloads ...

Module as:

PDF | EPUB (?)

What is an EPUB file?

EPUB is an electronic book format that can be read on a variety of mobile devices.

Downloading to a reading device

For detailed instructions on how to download this content's EPUB to your specific device, click the "(?)" link.

| More downloads ...

Add:

Collection to:

My Favorites (?)

'My Favorites' is a special kind of lens which you can use to bookmark modules and collections. 'My Favorites' can only be seen by you, and collections saved in 'My Favorites' can remember the last module you were on. You need an account to use 'My Favorites'.

| A lens I own (?)

Definition of a lens

Lenses

A lens is a custom view of the content in the repository. You can think of it as a fancy kind of list that will let you see content through the eyes of organizations and people you trust.

What is in a lens?

Lens makers point to materials (modules and collections), creating a guide that includes their own comments and descriptive tags about the content.

Who can create a lens?

Any individual member, a community, or a respected organization.

What are tags? tag icon

Tags are descriptors added by lens makers to help label content, attaching a vocabulary that is meaningful in the context of the lens.

| External bookmarks

Module to:

My Favorites (?)

'My Favorites' is a special kind of lens which you can use to bookmark modules and collections. 'My Favorites' can only be seen by you, and collections saved in 'My Favorites' can remember the last module you were on. You need an account to use 'My Favorites'.

| A lens I own (?)

Definition of a lens

Lenses

A lens is a custom view of the content in the repository. You can think of it as a fancy kind of list that will let you see content through the eyes of organizations and people you trust.

What is in a lens?

Lens makers point to materials (modules and collections), creating a guide that includes their own comments and descriptive tags about the content.

Who can create a lens?

Any individual member, a community, or a respected organization.

What are tags? tag icon

Tags are descriptors added by lens makers to help label content, attaching a vocabulary that is meaningful in the context of the lens.

| External bookmarks