Compositions of Functions, Even and Odd, and Increasing and Decreasing

This section covers:

Note that Compositions of Exponential and Logarithmic Functions can be found here.

Now that we know what a function is from the Algebraic Functions section, let’s talk about some cool things that we can do with them, and talk about more advanced types of functions.   All these types of things are found in “real life” computations that go on every day!

Let’s first review what a function is.  A function is defined as a relation between two things where there is only one “answer” for every “question”.  In a function, the x is the “question” and the y or f(x) is the answer.  So if we have a function Function, if our x was 2, our f(x) would be f(2)  Also,  f(x - 1) So with functions, just remember, for the “x on the left, plug this value into every “x on the right.

Adding, Subtracting, Multiplying, and Dividing Functions

Functions, like numbers, can actually be added, subtracted, multiplied and even divided.  These operations are pretty obvious, but I will give examples anyway.

Let’s think of a situation where two functions would be added:

Let’s say yesterday you went to your favorite cosmetics store and used your $5 off coupon.  Then you went to your favorite shoe store and used your 25% off coupon.  What is the function for the total number of dollars you spent yesterday, given you bought items that regularly cost $80 at each store?   (Disregard tax).  (I know – makeup is really expensive these days!)

Lipstick and Shoes

So we have two functions here: one for what you spent at the cosmetic store (given the regular price of the items), and one for what you spent at the shoe store (given the regular price of the items).  You might want to put some “fake” numbers in to convince yourself that these are the correct functions.

Composition of Functions with Shopping

Let’s get the total amount you spent two ways: first adding the amount you spent separately at each store, and then combining (adding) the functions and getting the total amount you spent at both stores.

We said that you bought items at each store that regularly cost $80 (There’s a lot you can buy at cosmetics stores these days!).  Look how we get the same amount that we spent by first evaluating the functions separately (plugging numbers in) and then adding the amounts, and second by adding the functions and then evaluating that combined function:

Adding Two Functions Table

So below are the rules on how the adding, subtracting, multiplying and dividing functions work.   I know the notation on the left looks really funny (and we saw this in the example above); it just means that the sum/difference/product/quotient of two functions is defined as when you just take the right hand side (what they are defined as) and add/subtract/multiply/divide them together.  Makes sense, right?

Let’s use two different functions, both of which are binomials:

Functions to Add Divide Multiply Divide

Adding Subtracting Multiplying Dividing Functions

See – not too bad, right?  I know we haven’t learned about the quotient of two functions yet;  we will talk about that in the Rational Functions section.  This particular function that we got from dividing functions can’t be simplified, but we’ll see later that some of them can.

Note that the multiplication operation on functions is not to be confused with the composition of functions, which looks likeComposition of Functions.  We will go over this later here.

Increasing, Decreasing and Constant Functions

You might be asked to tell what parts of a function are increasing, decreasing, or constant.

This really isn’t too difficult, but you have to be careful to look where the y or f(x) is increasing, decreasing, or remaining constant, but the answer will be in an interval of the x.  The answer will always with soft brackets, since the exact point where the function changes direction is neither increasing, decreasing, nor remaining constant.

So let’s look at an example:

Increasing Decreasing Constant Functions

See how we are looking at the y (up and down) to see where the function is increasing, decreasing, or constant, but write down the x (back and forth)?

Also, see how the function is either increasing, decreasing, or constant for its whole domain (except for the “turning” points)?

Also, note in the example above that there is a local maximum at point (3, 2) since this is the highest point in the section of the graph where the “hill” is?   A local minimum would similarly be the lowest point in a section of a graph where there is a “valley”.    This graph would have no absolute minimums or absolute maximums (the absolute lowest and highest points on the graph), since the range of the graph is Negative Infinity to Infinity.

Even and Odd Functions

There are actually three different types of functions: even, odd, or neither.  Most functions are neither, but you’ll need to know how to identify the even and odd functions, both graphically and algebraically.   One reason the engineers out there need to know if functions are even or odd is that they can do less computations if they know functions have certain traits.

Even Functions

Even functions are those that are symmetrical about the y axis, meaning that they are exactly the same to the right of the y axis as they are to the left.  This means if you drew a function on a piece of paper and folded that paper where the y axis is, the two sides of the function would match exactly.  (You will go over all this symmetry stuff in Geometry).  One of the most “famous” examples of an even function is y = x squared

I know this sounds really complicated but this means if (x,  y) is a point on the function (graph), then so is (–xy).  But the most important way to see if a function is even is to see algebraically if Even Function   We’ll see examples soon!

Odd Functions

Odd functions are those that are symmetrical about the origin (0, 0), meaning that if (x,  y) is a point on the function (graph), then so is (–x,  –y).    Think of odd functions as having the “pinwheel” effect (if you’ve heard of a pinwheel); if you put a pin through the origin and rotated the function around half-way, you’d see the same function.  One of the most “famous” examples of an even function is y = x cubed

Pinwheel

But the most important way to see if a function is odd is to see algebraically if Odd Function

“Neither” Functions

Any function that isn’t odd or even, is (you guessed it!) neither!

Here are some examples with some simple functions:

Even Odd Neither Functions Graphs

Here are more examples where we’ll determine the type of function (even, odd, or neither) algebraically.   Make sure to be really careful with the signs, especially with the even and odd exponents.

Even Odd Functions Algebraically HINT: when dealing with polynomials, note that the even functions have all zero or even exponents terms – don’t forget that the exponent of a constant, like 8, is 0, since 8 is the same as 8 x to the zero, or (8)(1).   Odd functions have all odd exponents terms (note that x has an exponent of 1).  Functions that are neither even or odd have a combination of even exponents and odd exponents terms.  Note that this works on polynomials only; for example, it does not necessarily work with a function that is a quotient of two polynomials.

Compositions of Functions (Composite Functions)

Compositions of functions can be confusing and a lot of people freak out with them, but they really aren’t that bad if you learn a few tricks.

Composition of functions is just combining 2 or more functions, but evaluating them in a certain order.  It’s almost like one is inside the other – you always work with one first, and then the other.  That’s all it is!

Shopping

Let’s start out with an example (shopping, of course!).  Let’s say you found two coupons for your favorite clothing store: one that is a 20% discount, and another one that is $10 off.  The store allows you to use both of them, in any order.  You need to figure out which way is the better deal.

Let’s first define the two functions.  Make sure you understand how they work with “real” numbers with each discount, for example if you bought $100 worth of clothes (you’d spend $80 with first discount, $90 with second).  Of course, if you could only use one of the discounts, the amount you save depends on how much you spend, but you are allowed to use both.

Composition of Functions with Shopping 2

Let’s look at what happens when we apply the discounts in different orders, if we were to buy $100 worth of clothes.  For now, look at first two columns only:

Compositions of Functions Table

Now let’s look at the last column.   Composition of functions are either written F of G of X  or Composition of Functions.  The trick with compositions of functions is that we always work from the inside out  with F of G of X or right to left withComposition of Functions.  You look at what the inside (or rightmost) function first and then that’s the “new x that we use to replace every x in the outside (or leftmost) function.

Another way to look at it is the output of the inner function becomes the input of the outer function.

So, in the example above, if we take the $10 off first and then take 20% off, we have to use the inside function g(x)  “x – 10” and put it in the outside function f(x) as the “new x” and put this everywhere on the right of the f(x) function.  Don’t worry if you don’t get this at first; it’s a difficult concept!

So it’d be better to take the 20% off first (which makes sense, since we’re taking the 20% off of a higher number).

Compositions Algebraically

So let’s do more examples of getting compositions of functions algebraically.  Let’s use the two functions:

Composition of Functions Algebraically

Compositions of Functions Table Examples

Compositions Graphically

Sometimes you’ll be asked to work with compositions of functions graphically, both “forwards” and “backwards”.   You can do this without even knowing what the functions are!

Let’s first do a “real life” example:

Babysitting

Let’s say you took a very part-time babysitting job (at $12/job) to satisfy your cravings for going to the movies (at $10 per movie).   How much money you make for the month depends on how many babysitting jobs you get that month F of x and how many movies you go to depends on how much money you have that month g of x  So do you see how many movies you go to depends on how many babysitting jobs you have that month G of f of x  (Remember, we work with inside functions first.)

Let’s show this graphically:

Compositions Graphically

So let’s say we took 5 babysitting jobs last month.  That translates into $60 of babysitting money that month (see graph to left).  That output of $60 then is used as the input into the graph at the right.   The output of the new graph is 6.  So we could go to 6 movies that month.

To see this algebraically, Babysitting Example Algebraically

Here are more examples, with more complicated graphs:

Composition of Functions Problems Graphically
I know this can be really confusing, but if you go through it a few times, it gets easier!

Decomposition of Functions

Sometimes we have to decompose functions or “pull them apart”.  I like to think of this like performing surgery on them – opening them up and seeing what the pieces are!

Note that there may be more than one way to decompose functions, and some functions can’t even really be decomposed!  But you should get problems that make it pretty straightforward.

The best way to show this is with an example.  Let’s say we have the following functions:

Functions to Compose and Decompose

Compose Function

Now, let’s first figure out what f of g of h of k is (compose the function).  I know this looks really difficult, but if we just take one step at time, it’s not too bad.   To “build” the function, we need to start from the inside; normally, we would simplify by multiplying out and combining like terms, but we’ll be lazy for now ;).

Building up Functions

Decompose Function

Now, let’s say we were given Function to Decompose (notice that I didn’t simplify totally, because this would be too crazy difficult!).

Let’s go the opposite way, or “decompose” the function: look at the last operation done, and that will be on the outside of the composed function.

So the last thing we did was add 3 (f(x)), before that, we took the square and subtracted 4 (g(x)), and even before that, we doubled (h(x)) “5x + 8” (k(x)) to get “10x + 16”.

When we decompose, the function on the outside (or the left) is the last thing we do.  Since we performed the functions above in the following order:  k(x) first, followed by h(x), then g(x), and finally f(x), we have to write the composition in the opposite order.  So Decompose Function  Tricky!

Let’s try another one;  decompose Another Function to Decompose.  Let’s look at the functions again:

Functions to Compose and Decompose

The last thing we did was square something and subtract 4 (g(x)), before that, we took something and multiplied it by 5 and then added 8 to it (k(x)), before that, we added 3 to something (f(x)), and then before that multiplied x by 2 (h(x)).   Again, since we work from the inside out, we have to start with the last thing we did and go forward: J of x

These are like fun puzzles (sorry – the nerd in me is coming out)!

Domains of Composites Algebraically

Sometimes in Advanced Algebra or even Pre-Calculus you’ll be asked to find the domains of compositions of functions, both graphically and algebraically.   This isn’t totally intuitive, but if you learn a few rules, it’s really not bad at all.

Let’s first review the case where you have to worry about domains; we looked at it here in the Algebraic Functions section.

Again, we know so far that domain is restricted if:  it is indicated that way in the problem, and/or there is a variable in the denominator and that denominator could be 0 and/or there is a variable underneath an even radical sign, and that radicand (underneath the radical sign) could be negative.

The best way to show how to get the domain of a composite is to jump right in and do a problem.  Suppose 3x - 1 and  Root x - 2.  Let’s find the compositiong of f of x compositesand it’s domain.

To get the composition, we put the inner function as the “new x” in the outer function, so Another Composite.

It’s interesting to note that we can’t just look at the composite function to get the domain of the composition of functions; unfortunately, it’s a little trickier than this.   We first need to see what values x can be for the inside function, since x goes directly into that function.

Next, since the output (the range) of the inside function goes into the input (the domain) of the outside function, we have to make sure that the inside function works for the outside domain.   But we still need to solve for x to get this restriction.

Then we have to put these two restrictions together to get the domain of the composite.  Since all this is very confusing, I like to just remember the following “trick”:

Domain of Composite  =  The Intersection of {the Domain of the Inner Function} and {Restricting the Inner Function to the Outer Domain}.  Another way to write this is the Domain of the Composite is: Domain of Inner Intersect Outer Domain.

Now I know this is really confusing, so let’s work the problem with 3x - 1 and Root x - 2 to find the domain of the composite g of f of x composites.

The domain of the inner function f(x) is x greater than or equal to 0, since that’s what’s given.   Now let’s put the inner function as the “new x” in the outer function and get the domain.  So we have to get the domain of g of 3x - 1.  So 3x - 3 greater than or equal to 0, since what’s underneath an even root has to be 0 or positive.  See how we had to solve for x again?

(We could have also seen that the domain of the outer is x greater than or equal to 2 because of the even radical, and then gotten the inner function (the “new x”) in the outer domain this way: 3x - 1 greater than or equal to 2 .)

Now we have to take the intersection or “and” (both have to work) of x greater than or equal to 0 and 1, which is x greater than or equal to 1.  (See that, for example, .5 doesn’t work, since it’s not both Greater Than or Equal 0 and Greater Than or Equal 1).  So the domain of Domain of g of f of x.  Whew – that was difficult!   These take a lot of practice!

Remember also that if either the domain of the inner or domain of outer (where you put the inner) is all real numbers (no restrictions), you don’t have to worry about that part of the intersection (see examples below).

Let’s do more examples.  For the following functions, find the composition and its domain:

Domain of Compositions Table

Let’s do one more that happens to involve a Rational Function, that we will learn about here in the Solving Rational Functions, including Asymptotes section.  To get the domain of the following composition, we will have to use a sign chart.

We’ve worked with sign charts here in the Quadratic Inequalities section, and they are a useful tool!

Sign Chart with Domain of Composite Function

Domains of Composites Graphically

We can determine the domains of composites graphically too, and this way is actually better to see what’s going on.  I call these the X-Y-X method (from the outside-in), since that is the sequence of events (look at X in the outside graph, then use it as a Y on the inside graph, then pick the X from the inside graph).

Here are some examples:

Domains of Composites Compositions Graphically

If we knew what these functions were algebraically (we’ll see how later!), we could use the DIF method.

I know this is really difficult, but follow these steps and you’ll be able to do any of the problems!

Applications of Compositions

Here are a couple more composites applications that you may see in your Algebra class:

Increasing Area Problem:

A rock is thrown in a pond, and the radius of the ripple circles increase at a rate of .5 inch per second.  Find an algebraic expression for the area of the ripple in terms of time t, and find the area after 20 seconds.

Solution:

For these types of problems, we want to start with the simplest (meaning most direct) function we can find in terms of time or t; this would be that the radius of the ripples increase at a rate of .5 inch per second.  We can write this as Radius in terms of Time.  Now we also now that the formula for the area of a circle based on its radius is Area of Circle.

Since the area is based on the radius which is based on the time, we can put the two functions together, with the inside function being the time function (remember that we work from the inside out with compositions).

We get  Area Composition Function.   For when t = 20 seconds (make sure units match, which they do since we are dealing with a rate of .5 inch per second!), we get Area Composition Function Solved.

Shadow Problem:

Amelia is walking away from a 20 feet high street lamp at a rate of 4 ft/sec.  If Amelia is 5’6″ tall, how long will she have walked (both in terms of time and distance) when her shadow is 7 feet long?

Solution:

This is a tough one; actually you’ll be doing some like this in Calculus.  Let’s draw a picture first, and we need to know a little bit about shadows and Geometry. 🙂

Shadow Word Problem


Learn these rules, and practice, practice, practice!


Click on Submit (the arrow to the right of the problem) to solve this problem. You can also type in more problems, or click on the 3 dots in the upper right hand corner to drill down for example problems.

If you click on “Tap to view steps”, you will go to the Mathway site, where you can register for the full version (steps included) of the software.  You can even get math worksheets.

You can also go to the Mathway site here, where you can register, or just use the software for free without the detailed solutions.  There is even a Mathway App for your mobile device.  Enjoy!

On to Inverses of Functions  – you are ready!!

One thought on “Compositions of Functions, Even and Odd, and Increasing and Decreasing

Leave a Reply

Your email address will not be published. Required fields are marked *