# Operations with Functions

How to solve composite functions problems: examples and their solutions.

## Example 1

(*g* ∘ *f*)(*x*) = *g*(*f*(*x*)).

It means put the output of *f*(*x*)

into *g*(*x*) as an input.

To solve the composition,

solve it from the inside.

(*g* ∘ *f*)(3) = *g*(*f*(3)) = *g*(6) = 31

See the meaning of the solution.

To find (*g* ∘ *f*)(3) = 31:

Put 3 into *f*(*x*): *f*(3) = 6.

Put 6 into *g*(*x*): *g*(6) = 31.

Function

## Example 2

Put *f*(*x*) = 2*x* into *g*(*x*):

(*g* ∘ *f*)(*x*) = *g*(*f*(*x*))

= *g*(2*x*)

= (2*x*)^{2} - (2*x*) + 1

See the meaning of the solution.

To find (*g* ∘ *f*)(*x*) = 4*x*^{2} - 2*x* + 1:

Put *x* into *f*(*x*):*f*(*x*) = 2*x*.

Put 2*x* into *g*(*x*):*g*(2*x*) = (2*x*)^{2} - (2*x*) + 1

= 4*x*^{2} - 2*x* + 1

## Example 3

Put *g*(*x*) = *x*^{2} - *x* + 1 into *f*(*x*):

(*f* ∘ *g*)(*x*) = *f*(*g*(*x*))

= *f*(*x*^{2} - *x* + 1)

= 2(*x*^{2} - *x* + 1)

You can see that

(*g* ∘ *f*)(*x*) and (*f* ∘ *g*)(*x*) are different.

(See the previous example.)

See the meaning of the solution.

To find (*f* ∘ *g*)(*x*) = 2*x*^{2} - 2*x* + 2:

Put *x* into *g*(*x*):*g*(*x*) = *x*^{2} - *x* + 1.

Put *x*^{2} - *x* + 1 into *f*(*x*):*f*(*x*^{2} - *x* + 1) = 2(*x*^{2} - *x* + 1)

= 2*x*^{2} - 2*x* + 2