H of x should equal 3000x, since Athena makes $3000 a month, 2000 plus 1000.
So now we know, we can find Athena's total income after x months using our function h here. H of x equals 3000x. So let's think a bit more abstractly about this. What do we do to our two original functions f and g to end up with this final function h. Did we add them together? Multiply them together? Subtract them, or divide them?
We added them, so this first choice is correct. The total salary, which is what h of x represents is just the sum of the two salaries from the individual jobs, f and g. 2000x plus 1000x, gives us 3000x.
For each equation we have here, we just need to substitute in the expression we have for each of the functions, and then combine like terms. When we do this, we end up with for part a, the addition 3x cubed minus x squared, and for part b, where we have f of x minus g of x, we end up with x cubed minus 3x squared.
Function addition and subtraction happen all the time. For each of these examples down here, please tell me whether you'd be more likely to add or subtract the functions that involved. First we have calculating profit, or p of x, for money earned, which is r of x, and money spent, c of x. Second, we have calculating change in population, or q of t, from the number of births, b of t and the number of deaths, d of t. And finally, calculating the total production of two factories, f of x, from their individual productions, which we will call g of x and h of x.
We will need to subtract functions, for the first two examples, and add them to the last one.
Now we've looked at addition and subtraction of functions, but what about multiplication and division? Let's say that we have f of x equals x plus 1. And g of x equals 2x minus 5? What then would f of x times g of x be? Please simplify your answer.
Hopefully, this gave you a nice little review of polynomial multiplication. I'm sure that you remembered exactly how to distribute correctly. When we multiply f of x times g of x, or, in other words, x plus 1 times 2x minus 5, we end up with 2x squared minus 3x minus 5.
Multiplication of expressions was something we focused on, pretty early on in the course. But, division didn't come up until much more recently. Let's say this time, that f of x is equal to 2x cubed, plus 12x squared, minus 8x, minus over g of x? Make sure, as before, to simplify your answer.
If we divide f of x by g of x, we're dividing 2x cubed plus 12x squared minus squared plus 8x plus 12.
So you may have noticed that I haven't actually taught you much of anything new yet. All this is really just a new notation for manipulating different kinds of expressions. However, this new notation gives us an important way to think about functions. Just like variables can be added, subtracted, multiplied and divided, so can functions. In fact, there's an even shorter, easier way of representing things like f of x plus g of x, or any of the other things I have written down here. Let me show you. And, this is all it is. If we want to add two functions, f and g, and of course they're dealing with the same variable, which in this case is x. Then we just write in parentheses, f plus g, showing that they're one combined function when we add them together like this. So we have f plus g of x. Similarly, for subtraction, we can have f minus g of x. For multiplication we just multiply f and g together inside the first parentheses, and for division, we do the same thing with dividing. If we have the functions f of x equals x, and g of x equals x squared minus x, then please tell me what we get for each of these combined functions down here.
So here are the expressions we get when we combine our functions, f of x and g of x, in these different ways. G minus f of x, gives us x squared minus 2x. F plus g of x, gives us x squared. Fg of x, which remember, is the same thing as f times g of x, gives us, x cubed, minus x squared. And, last but not least, g, over f of x, gives x minus 1.
It's been cool to see how we can combine functions mathematically, but what do the results of these combinations really mean? Well, to understand the relationship between the original functions and combined functions, I think we should make some graphs. Starting with something simple sounds like a good idea. Here I've drawn the graphs of f of x equals 2x plus 1, and g of x equals do you think is a graph of this new function?
Adding f and g would produce this graph, the middle one. Since g is just a positive constant function, y equals 3. When we add it to the function f, it's going to raise every point on this line, up by 3 units.
So let's look at what's actually happening here to our two curves on this coordinate plane, to create this black line over here. What I've drawn right now, is a bunch of lines going from the x axis up to our curve. Or our line, rather, f of x. What happens graphically when we want to add 3 to the length of each of these lines, is that we're shifting them up. So that they start, instead, at the line, y equals 3. If we connect these lines now, we end up with a curve that looks just like our black line. Over there. So this line is identical to the reddish one, just with every single point translated up 3 units. This is exactly what we were talking about with transformations in the last lesson. Working with the same two functions as the last quiz, what if we want to subtract one of these functions from the other? One of these three graphs represents f minus g of x, and another one of them is g minus f of x. Which one is which? In this top row of bubbles, please select f minus g. And in the bottom row, please pick which one is g minus f. I wanted to keep the functions written here for you. I'd recommend thinking about this graphically, but if you need to work with the equations of the functions, and combine them mathematically first, before you pick the graphs, that's also totally fine.
This first graph represents f minus g of x, and this last graph represents g minus f of x. For f minus g here, we see something very similar to what happened when we added f and g together. Since we're just subtracting a constant function from this linear one, we end up with the same exact graph as f. We can see that this line is parallel to this one, except this one is shifted down three units. G minus f is a bit more complicated. In this case, we're subtracting our linear function from our constant one. This means that the resulting graph isn't just going to be a shift of f. Instead, for each value of x. [INAUDIBLE]. We measure from the x axis to the line of f. Then, we look at the graph of g. And we move it down by the positive distances between the x axis and f, shown by these lines right here. And up by those distances between the x axis and the part of f that lay below it. We're adding this positive distance because we were subtracting a negative one before. If we connect the tops of all these lines together, we can see that we will end up with a graph that looks just like this one, to the far right. What's interesting, is that now our slope is negative. It's not positive or zero, like either of our two original functions.
Let's look at two different functions now, but still nothing too complicated. I like these two. Here we have p of x, equals x plus 4. And q of x, equals negative 2x minus 5. So here are three graphs. Which one represents p plus q, which one is p minus q, and which one shows q minus p? Now to figure this out, think about how much each line should be moved up or down at each x value, based on the value of the other function at that same position. Another way, of course, to figure this question out, will be to use the equations right here, of p and q, to figure out the equations of the other lines. Then you can use those to pick the graphs.
Since we've been adding and subtracting functions so much, this time why don't we multiply. I'd like us to keep using the same functions we've been working with, p and q. Instead of jumping right into graphing though, why don't we start by filling out a table. For each value of x I've listed here, please tell me the value of each of these functions. We have p of x in this column, q of x in this column, and pq of x in this column. Remember that for every value of x, the value of this function is just the product of p and q.
Here is a filled out version of our table. I simply plugged in each value of x, into either of our two functions over here, to fill out these first two columns. Then to fill out the last column pq of x. I just multiplied the two numbers in the cells adjacent to it together. Negative one times five is negative five. Zero times three is zero, and so on and so forth.
Thinking about the numbers we have in our lovely chart over here. And about what kind of functions p and q are, linear ones. What kind of curve do you think pq of x is? Is it a vertical line, a horizontal line, a straight line with a nonzero slope, a parabola or a cubic curve?
Pq of x is a parabola. Thinking about the graphs of p and q, this makes sense. Since they are both linear functions, if we multiply two linear expressions together, we get a quadratic one, which produces a parabola. We can also see this in the table, the curve starts down low at negative 5, comes up, and then drops back down again. Let's look at its actual graph.
Here, once again, are our graphs of p and q. And then here is the graph pq. What a nice parabola. Now that we have our graph, what is the equation of this parabola? Please write the rest of it's equation in this box.
To get the equation for pq, we just need to multiply p and q together. So we have x plus 4 times negative 2x minus 5. I would prefer to simplify this, so lets do that. That leaves us with negative 2x squared minus 13x minus 20.
Just to round things out, how about we divide p and q. In fact, lets get two different functions out of this. First I'd like you to find p over q of x, and then I'd like you to find q over p of x.
P over q of x, is x plus 4, over negative 2x minus 5. And q over p of x, is negative 2x minus 5, over x plus 4.
The functions both p over q, and q over p, are both rational functions. Please figure out where their vertical and horizontal asymptotes are, and then pick, which of these three graphs represents each one.
From the function p over q, we can see from the denominator that the vertical asymptote is x equals negative 5 half's. The horizontal asymptote from our leading coefficients, is y equals negative 1 half. The graph that has these asymptotes is graph C right here. Moving on to our second function, q over p of x, the vertical asymptote is x equals negative 4. The horizontal asymptote is y equals negative 2, and that means that this goes with graph B.
Everything so far has been fairly similar to things that you've already seen. We have just produced different polynomial functions and rational functions through combining functions in different ways. But, now I think we should do something totally new. Way back when we first started talking about functions I showed you a little visual. I think it looked like this. It was a function machine that takes an input and spits out an output. For example, we could write a function that relates the number of wiper sets that Grant has sold, let's call it N, to the amount of money he makes in the end, his revenue, which we'll find using the function R. So, for example, if people spend $15 on a wiper set, Then R of N will equal 15N. We can see that this function machine is taking in N as its input, and spitting out R of N or 15N as its output. Now, if Grant is trying to increase his revenue, or increase R, then he obviously wants to increase the number of wiper sets that he sells. So how does he do that? Well, as we saw before, the number of wiper sets that he sells, N, is a function of the amount of money that he spends on advertising, which I'll call d. Both revenue and money spent on advertising are going to be measured in dollars. So now we have that R is a function of N and N is a function of d. So how are R and N and d all related to one another? We should be able to then draw a function diagram that represents this relationship. Which one of these diagrams do you think is correct? Don't worry at all if this seems tricky. This is definitely pushing the boundaries of our understanding of functions.
This diagram is correct. It initially takes d N as it's input and then gives N of d as an output. Then N of d acts as the input for the second machine, which spits out R of N of d. That's pretty cool. I know this notation probably looks kind of funny right now but we'll learn all about it, in the next few videos.
Grant has figured out that the function that relates N to d, is N of d equals 4 times the square root of d. Remembering what N and d stand for, how many wiper sets will Grant sell if he spends $100 on advertising?
He will sell 40 wiper sets. All we have to do is find N of 100, since d stands for a dollar spent on advertising. That will just give us 4 times the square root of 100, or 4 times 10.
Using the result of the last quiz, in our function R of N, how much revenue will Grant make if he spends $100 on advertising? Don't forget the result we just came up with.
We just saw that if Grant spends $100 in advertising, he'll make 40 glasses wiper sets. To figure out his revenue, once he sells all of these. We just need to plug in 40 for n into the function, r of n. R of 40 equals 15 times 40, which gives us a revenue of $600.
What if instead Grant spends $400 in advertising? How much revenue will he make then?
This time we have to start from scratch. Plugging in 400 for d, in our equation N of d, 4 times the square root of 400 gives us 80, so it looks like he's going to make 80 glass swipers. Now, this output access the input to our second function for R. R of 80 is just 15 times 80, that gives us 1200, which means that Grant will make $1,200 in revenue.
What we've used here is called a Composite Function. R is a function of N, but N is a function of d. So it ends up that R is actually a function of d. That's really awesome. We'll come back to see example with the revenue and numbers in a bit, but first let's talk about composite functions in general. To do this, I think we need a fresh set of functions, so how about these two, f of x equals x squared and g of x equals x minus one. When we talk about composition of functions, this means that we're combining two functions in a special way. We take the results, the output, of one function, and substitute that in, as the input of the other function. For example, if I want to find f of g of x, I would plug in the function g of x Everywhere I see a x in f. So in the case of these functions, the output of g of x is x minus one. So that's going to be the input of f. That means that f of g of x is really just f of x minus one. So what expression do we get to complete this comoposite function?
We just need to plug in x minus 1 in place of x, in the function f of x. That gives us the quantity, x minus 1 squared.
There's a slightly different notation that's often used for composite functions. Instead of writing f of g of x. We can write this, which we read as f composed with g of x. These two notations mean exactly the same thing. Since we already found f of g of x, or in other words F composed with G. Can you tell me what G composed with F is? In other words, I'm asking you what g of f of x is for these two functions?
By now you've seen a few different examples of composite functions. And for one pair of functions we found both, f composed with g, and g composed with f. What I'm wondering is if order matters. Does it matter if f is the outer function and g is the inner function, or vice versa? In other words is the output of these two composite functions the same. Well we're going to test that for a bunch of different pairs of functions. In the first column over here, we have what I'm going to call function one. And over here function two. For each pair, please find f of g and then g of f. And then pick whether or not they're the same. Now I know that for some of these it doesn't actually look like we're doing any math. These bottom three functions are all modeling real life situations. But we can still think of them as functions. They all produce a certain outcome and I'm wondering if the order we do these actions in, changes the final outcome of the situation. So, f of g, for this first case here, where f is putting on left shoe, and g is putting on your right shoe, would mean putting on your right shoe and then putting on your left shoe. Whereas g of f, would be putting on your left shoe, and then putting on your right shoe. So again, just consider if the order we apply either of these functions in, affects the end situation.
As we've talked about many times before, domain just means allowable inputs. It's a set of values that you can plug in for the independent variable into your function. For example, with these functions we've been dealing with recently, the domain of f of x is all the real numbers. We can plug in any real number for x. And get a real number out from the function. Now, can you tell me what the domain of g of x, where g of x equals the square root of 4 minus x squared is? Please write this in interval notation.
So, what do you think the domain of f of g of x is? Well, you may be tempted to say all the real numbers since we found earlier that f composed of g equals negative x squared. But I'll tell you right now that all real numbers is not the Cartesian answer. Think about how we created f of g of x and you may come up with the answer. I'll give you a hint that you should probably consider the domain of the input and think about how that's going to affect the domain of our composite function. This is definitely a challenge problem so if you don't get it, no big deal.
So, we actually have two right answers in this case. One set of answers could be, f of x equals x plus 3, and g of x equals 1 over x squared. These two functions, when composed, will give us, f of g of x equals 1 over x squared plus 3, exactly what we're looking for. Our other option is this set, here we have f of x equals 1 over x plus 3, and g of x equals x squared. This shows us that there are different ways to dissect functions and write them instead as compositions of other functions.
M of s of n is just going to be 3 million minus 100000n.
Consider a new composite function M of s of n equals 3,000,000 minus 100,000n. How much money will grant have left after one year in business?
To make things come full circle, lets go back to the first composite function we worked with in this lesson. We started out with two equations, R(N) =15N, and, N(D)=4√d This first one shows the amount of money Grants brings in depending how many glasses per sets he sells and this second one, shows how the number of glass per sets sold depends on the amount of money Grant spends for advertising So, what is (R·N)(d)? or (R·N)(d)? Please write the expression right here.