0% found this document useful (0 votes)
7 views

Lecture # 5 (Functions)

Uploaded by

saadbutt43215
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
7 views

Lecture # 5 (Functions)

Uploaded by

saadbutt43215
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 32

Calculus &

Analytical
Geometry
(MATH- 101)
Instructor: Dr. Naila Amir ([email protected])
Transformation of Graphs

▪ Book: Thomas Calculus (14th Edition) by George B. Thomas, Maurice D. Weir, Joel R. Hass, Frank R. Giordano
▪ Chapter: 1 (1.1, 1.2, 1.3)
Scaling Graphs
Scaling a graph of a function
▪ Scaling is a non-rigid translation in which the size and shape of the graph of a function is changed.
▪ To scale the graph of a function we stretch or compress it, vertically or horizontally. This is
accomplished by multiplying the function 𝑓, or the independent variable 𝑥, by an appropriate
constant.
▪ A vertical scaling multiplies/divides every 𝑦 − coordinate by a constant while leaving the
𝑥 −coordinate unchanged.
▪ A horizontal scaling multiplies/divides every 𝑥 − coordinate by a constant while leaving the
𝑦 −coordinate unchanged.
Reflection a graph of a function
▪ A translation in which the graph of a function is mirrored about an axis.
▪ Reflections are just a special case of the scaling.
▪ To reflect about the 𝑦 −axis, multiply every 𝑥 by −1 to get −𝑥.
▪ To reflect about the 𝑥 −axis, multiply 𝑓(𝑥) by −1 to get −𝑓(𝑥).
Vertical and Horizontal Scaling and Reflection
2 f (x ) = 2 x 4 f (x ) = 4 x
yy


f (x ) = x
y







x
− − − −     
x
− − − −     x 
− − − −     
−
−
−

−
−
−

−
−
−

−
−
−

The graph 𝑎 𝑓(𝑥), where 𝑎 > 1, is the graph of 𝑓(𝑥) but vertically
stretched by a factor of “𝑎”.
What if the value of 𝒂 was positive but less than 1?

f (x ) = x
yyy



f (x ) =
1 1 

x 

2 2


x
xx
− − − −     

f (x ) =
−
− −
− −
− −
−  

1  
1 

−
−
− x
−
−
−
4 4
−
−
−

−
−
−

The graph 𝑎𝑓(𝑥), where 0 < 𝑎 < 1, is the graph of 𝑓(𝑥) but vertically
compressed by a factor of 𝑎.
What if the value of 𝒂 was negative?
yy


 f (x ) = x




xx
− − −
− −
−     

−
−

−
−

−
−

− f (x ) = − x−
−

The graph − 𝑓(𝑥) is a reflection about the 𝑥 −axis of the graph of


𝑓(𝑥). The new graph is obtained by "flipping“ or reflecting the function
over the 𝑥 −axis.
f (− x ) = (− x ) f (x ) = x
3 3

y

y





x x
−
− −
− −
− −
−          

−−

−
−

−
−

−
−

The graph 𝑓(−𝑥) is a reflection about the 𝑦 −axis of the graph of 𝑓(𝑥).
Summary
If 𝑎 > 1, then vertical stretch by a factor of 𝑎.

If 0 < 𝑎 < 1, then vertical compression by a factor of 𝑎.

If 𝑎 < −1, then reflection of graph.

𝑓(−𝑥) reflection about 𝑦 −axis vertical translation by 𝑘

a f (x − h ) + k
horizontal translation by ℎ Note: We always perform reflections before
vertical and horizontal translations
Summary:
Example: Using Graphing Calculator
Consider the square root function:
𝑦 = 𝑓 𝑥 = 𝑥,

and then
• Stretch it by 2 units in the 𝑦 −direction, i.e., consider
2𝑓 𝑥 = 2 𝑥.
• Shift it left 1 units, i.e., 2𝑓(𝑥 + 1) = 2 𝑥 + 1 and
• Shift it up 1 units, i.e., 2𝑓 𝑥 + 1 + 1 = 2 𝑥 + 1 + 1.

Note: If we compare this with:


𝑎𝑓 𝑏 𝑥 + 𝑐 + 𝑑,
This means we have 𝑓 𝑥 = 𝑥, 𝑎 = 2, 𝑐 = 1 and 𝑑 = 1.

https://www.desmos.com/calculator/26hwvdgfdp
Combining
Functions
Combining Functions
There exist different ways to combine functions to make new
functions:
• Arithmetic Combinations of Functions that includes Sums,
Differences, Products and Quotients.

• Composition of Functions.
Arithmetic Combinations of Functions
• Two functions 𝑓 and 𝑔 can be combined to form new functions

𝑓 + 𝑔, 𝑓 – 𝑔, 𝑓𝑔, 𝑓/𝑔

in a manner similar to the way we add, subtract, multiply, and divide real
numbers.
Sum of Functions
We define the function 𝑓 + 𝑔 by:

(𝑓 + 𝑔)(𝑥) = 𝑓(𝑥) + 𝑔(𝑥)

• The new function 𝑓 + 𝑔 is called the sum of the functions f and g.


• Its value at 𝑥 is 𝑓 𝑥 + 𝑔 𝑥 .
• Of course, the sum on the right-hand side makes sense only if both 𝑓(𝑥) and 𝑔(𝑥)
are defined, i.e., if 𝑥 belongs to the domain of 𝑓 and also to the domain of 𝑔.
• So, if the domain of 𝑓 is 𝐴 and that of 𝑔 is 𝐵 respectively, then the domain of the
function 𝑓 + 𝑔 is the intersection of these domains, i.e., 𝐴 ∩ 𝐵.
• Note that the sum of two even functions is even, and the sum of two odd functions is
odd.
Differences, Products, and Quotients
Similarly, we can define:
• the difference 𝑓 – 𝑔 𝑥 = 𝑓 𝑥 − 𝑔(𝑥),
• the product 𝑓. 𝑔 𝑥 = 𝑓 𝑥 . 𝑔(𝑥),
𝑓 𝑓(𝑥)
• the quotient 𝑥 = , as long as 𝑔(𝑥) ≠ 0.
𝑔 𝑔(𝑥)
Note:
• The difference of two even functions is even, and the difference of two odd functions
is odd.
• The product of two even functions is even, and the product of two odd functions is
even. The product of an even function and an odd function is an odd function.
• The quotient of two even functions is even, and the quotient of two odd functions is
even. The quotient of an even function and an odd function is an odd function.
Domain of Differences, Products, and Quotients
• The domain of each of these combinations is the intersection of the
domain of 𝑓 and the domain of 𝑔. In other words, both functions must be
defined at a point for the combination to be defined. One additional
requirement for the division of functions is that the denominator can't be
zero.

• Thus, if the domain of 𝑓 is 𝐴 and that of 𝑔 is 𝐵 respectively, then the


domain of the functions 𝑓 − 𝑔 and 𝑓. 𝑔 is the intersection of these
𝑓
domains, i.e., 𝐴 ∩ 𝐵, while domain of the quotient is 𝐴 ∩ 𝐵
𝑔
excluding those points at which 𝑔(𝑥) ≠ 0.
Algebra of Functions
• Let 𝑓 and 𝑔 be functions with domains 𝐴 and 𝐵 respectively..
• Then, the functions 𝑓 + 𝑔, 𝑓 – 𝑔, 𝑓. 𝑔, and 𝑓/𝑔 are defined as follows:

Function Domain
1. (𝑓 + 𝑔)(𝑥) = 𝑓(𝑥) + 𝑔(𝑥) 𝐴∩𝐵

2. 𝑓 − 𝑔 𝑥 = 𝑓 𝑥 − 𝑔 𝑥 𝐴∩𝐵

3. 𝑓. 𝑔 𝑥 = 𝑓 𝑥 𝑔 𝑥 𝐴∩𝐵

𝑓 𝑓 𝑥 𝑥 ∈ 𝐴 ∩ 𝐵|𝑔(𝑥) ≠ 0
4. 𝑥 =
𝑔 𝑔 𝑥
Example: Combinations of Functions
1
Let 𝑓(𝑥) = and 𝑔(𝑥) = 𝑥
𝑥−2

(a) Determine the functions 𝑓 + 𝑔, 𝑓 – 𝑔, 𝑓. 𝑔, and 𝑓/𝑔 and their domains.

(b) Find (𝑓 + 𝑔)(4), (𝑓 – 𝑔)(4), (𝑓. 𝑔)(4), and (𝑓/𝑔)(4).


Solution: (a)
• The domain of 𝑓(𝑥) is {𝑥|𝑥 ≠ 2} and the domain of 𝑔(𝑥) is {𝑥|𝑥 ≥ 0}.

• The intersection of the domains of 𝑓(𝑥) and 𝑔(𝑥) is:


{𝑥 | 𝑥 ≥ 0 and 𝑥 ≠ 2} = [0, 2) ∪ (2, ∞).
1
• 𝑓+𝑔 𝑥 =𝑓 𝑥 +𝑔 𝑥 = + 𝑥 Domain{𝑥|𝑥 ≥ 0 and 𝑥 ≠ 2}
𝑥−2

1
• (𝑓 − 𝑔)(𝑥) = 𝑓(𝑥) − 𝑔(𝑥) = − 𝑥 Domain{𝑥|𝑥 ≥ 0 and 𝑥 ≠ 2}
𝑥−2
Solution: (a)
𝑥
• 𝑓. 𝑔 𝑥 = 𝑓 𝑥 𝑔 𝑥 = Domain 𝑥 𝑥 ≥ 0 and 𝑥 ≠ 2
𝑥−2

𝑓 𝑓(𝑥) 1
• (𝑥) = = Domain{𝑥|𝑥 > 0 and 𝑥 ≠ 2}
𝑔 𝑔(𝑥) (𝑥−2) 𝑥

• Note that, in the domain of 𝑓/𝑔, we have excluded 0 because 𝑔(0) = 0.


Solution: (b)
• Each of these values exist because 𝑥 = 4 is in the domain of each function.
1 5
• 𝑓+𝑔 4 =𝑓 4 +𝑔 4 = + 4= .
4−2 2

1 3
• 𝑓−𝑔 4 =𝑓 4 −𝑔 4 = − 4= − .
4−2 2

1
• 𝑓𝑔 4 = 𝑓 4 𝑔 4 = 4 = 1.
4−2

𝑓 𝑓 4 1 1
• 4 = = = .
𝑔 𝑔 4 4−2 4 4
Practice: Combinations of Functions

Let 𝑓(𝑥) = 𝑥 and 𝑔(𝑥) = 4 − 𝑥 2 . Determine the functions 𝑓 + 𝑔, 𝑓 – 𝑔,


𝑓. 𝑔, and 𝑓/𝑔 and their domains. Moreover, plot the graph of all functions.
Arithmetic Combinations of Functions
Let 𝑓(𝑥) = 5𝑥 + 2 and 𝑔 𝑥 = 𝑥 2 − 1. Evaluate each combination at the point 𝑥 = 4. Note that: 𝑓(4) = 5(4) + 2 = 22
and 𝑔(4) = (4)2 −1 = 15.

Note:
• It doesn't matter if we combine and then evaluate or if we evaluate and then combine.
• In each of the above problems, the domain is all real numbers with the exception of the division. The domain in the
division combination is all real numbers except for 1 and -1.
Composition of Functions
Now, let’s consider a very important way of combining two functions to get a new function.

• Suppose 𝑓(𝑥) = 𝑥 and 𝑔(𝑥) = 𝑥2 + 1.

• We may define a function ℎ as:

ℎ 𝑥 = 𝑓∘𝑔 𝑥 =𝑓 𝑔 𝑥 = 𝑓 𝑥2 + 1 = 𝑥 2 + 1.

• The function ℎ is made up of the functions 𝑓 and 𝑔 in an interesting way: Given a number 𝑥,
we first apply to it the function 𝑔, then apply 𝑓 to the result.
Composition of Functions
• In this case,

• 𝑓 is the rule “take the square root.”

• 𝑔 is the rule “square, then add 1.”

• ℎ is the rule “square, then add 1, then take the square root.”

• In other words, we get the rule ℎ by applying the rule 𝑔 and then the rule 𝑓.
Composition of Functions
• In general, given any two functions 𝑓 and 𝑔, we start with a number 𝑥 in the domain of 𝑔 and
find its image 𝑔(𝑥). If this number 𝑔(𝑥) is in the domain of 𝑓, we can then calculate the value of
𝑓(𝑔(𝑥)).

• The result is a new function ℎ(𝑥) = 𝑓(𝑔(𝑥)) obtained by substituting 𝑔 into 𝑓. It is called the
composition (or composite) of 𝑓 and 𝑔 and is denoted by 𝑓 ◦ 𝑔 (“𝑓 composed with 𝑔”).

• The domain of 𝑓 ◦ 𝑔 is the set of all 𝑥 in the domain of 𝑔 such that 𝑔(𝑥) is in the domain of 𝑓.
In other words, (𝑓 ◦ 𝑔)(𝑥) is defined whenever both 𝑔(𝑥) and 𝑓(𝑔(𝑥)) are defined.
Example: Composition of Functions
Let 𝑓(𝑥) = 𝑥2 and 𝑔(𝑥) = 𝑥 – 3.

(a) Find the functions 𝑓 ◦ 𝑔 and 𝑔 ◦ 𝑓 and their domains.

(b) Find (𝑓 ◦ 𝑔)(5) and (𝑔 ◦ 𝑓 )(7).


Solution:
(a) We have:
(𝑓 ∘ 𝑔)(𝑥) = 𝑓(𝑔(𝑥)) = 𝑓(𝑥 − 3) = (𝑥 − 3)2
and
𝑔∘𝑓 𝑥 =𝑔 𝑓 𝑥 = 𝑔 𝑥 2 = 𝑥 2 − 3.

The domains of both f ◦ g and g ◦ f are ℝ.


(b) We have:
(𝑓 ◦ 𝑔)(5) = 𝑓(𝑔(5)) = 𝑓(2) = 22 = 4
(𝑔 ◦ 𝑓 )(7) = 𝑔(𝑓(7)) = 𝑔(49) = 49 – 3 = 46

You might also like