For [tex]\( f(x) = 1 - x \)[/tex] and [tex]\( g(x) = 3x^2 + x + 5 \)[/tex], find the following functions:

a. [tex]\((f \circ g)(x)\)[/tex]

b. [tex]\((g \circ f)(x)\)[/tex]

c. [tex]\((f \circ g)(2)\)[/tex]

d. [tex]\((g \circ f)(2)\)[/tex]



Answer :

Of course! Let's go through each part of the question step-by-step.

Given functions:
[tex]\[ f(x) = 1 - x \][/tex]
[tex]\[ g(x) = 3x^2 + x + 5 \][/tex]

### a. [tex]\((f \circ g)(x)\)[/tex]
The notation [tex]\((f \circ g)(x)\)[/tex] means we need to apply the function [tex]\(g(x)\)[/tex] first and then apply the function [tex]\(f\)[/tex] to the result of [tex]\(g(x)\)[/tex].

1. Compute [tex]\(g(x)\)[/tex]:
[tex]\[ g(x) = 3x^2 + x + 5 \][/tex]

2. Apply [tex]\(f\)[/tex] to [tex]\(g(x)\)[/tex]:
[tex]\[ f(g(x)) = f(3x^2 + x + 5) \][/tex]

3. Substituting [tex]\(3x^2 + x + 5\)[/tex] into [tex]\(f\)[/tex]:
[tex]\[ f(3x^2 + x + 5) = 1 - (3x^2 + x + 5) \][/tex]

4. Simplify the expression:
[tex]\[ (f \circ g)(x) = 1 - 3x^2 - x - 5 = -3x^2 - x - 4 \][/tex]

Thus:
[tex]\[ (f \circ g)(x) = -3x^2 - x - 4 \][/tex]

### b. [tex]\((g \circ f)(x)\)[/tex]
The notation [tex]\((g \circ f)(x)\)[/tex] means we need to apply the function [tex]\(f(x)\)[/tex] first and then apply the function [tex]\(g\)[/tex] to the result of [tex]\(f(x)\)[/tex].

1. Compute [tex]\(f(x)\)[/tex]:
[tex]\[ f(x) = 1 - x \][/tex]

2. Apply [tex]\(g\)[/tex] to [tex]\(f(x)\)[/tex]:
[tex]\[ g(f(x)) = g(1 - x) \][/tex]

3. Substituting [tex]\(1 - x\)[/tex] into [tex]\(g\)[/tex]:
[tex]\[ g(1 - x) = 3(1 - x)^2 + (1 - x) + 5 \][/tex]

4. Expand and simplify the expression:
[tex]\[ g(1 - x) = 3(1 - 2x + x^2) + 1 - x + 5 = 3(1 - 2x + x^2) + 1 - x + 5 \][/tex]
[tex]\[ = 3 - 6x + 3x^2 + 1 - x + 5 \][/tex]
[tex]\[ = 3x^2 - 7x + 9 \][/tex]

Thus:
[tex]\[ (g \circ f)(x) = 3x^2 - 7x + 9 \][/tex]

### c. [tex]\((f \circ g)(2)\)[/tex]
To find [tex]\((f \circ g)(2)\)[/tex], we first need to compute [tex]\(g(2)\)[/tex] and then apply [tex]\(f\)[/tex] to the result.

1. Compute [tex]\(g(2)\)[/tex]:
[tex]\[ g(2) = 3(2^2) + 2 + 5 \][/tex]
[tex]\[ = 3(4) + 2 + 5 \][/tex]
[tex]\[ = 12 + 2 + 5 \][/tex]
[tex]\[ = 19 \][/tex]

2. Apply [tex]\(f\)[/tex] to 19:
[tex]\[ f(19) = 1 - 19 \][/tex]
[tex]\[ = -18 \][/tex]

Thus:
[tex]\[ (f \circ g)(2) = -18 \][/tex]

### d. [tex]\((g \circ f)(2)\)[/tex]
To find [tex]\((g \circ f)(2)\)[/tex], we first need to compute [tex]\(f(2)\)[/tex] and then apply [tex]\(g\)[/tex] to the result.

1. Compute [tex]\(f(2)\)[/tex]:
[tex]\[ f(2) = 1 - 2 \][/tex]
[tex]\[ = -1 \][/tex]

2. Apply [tex]\(g\)[/tex] to [tex]\(-1\)[/tex]:
[tex]\[ g(-1) = 3(-1)^2 + (-1) + 5 \][/tex]
[tex]\[ = 3(1) - 1 + 5 \][/tex]
[tex]\[ = 3 - 1 + 5 \][/tex]
[tex]\[ = 7 \][/tex]

Thus:
[tex]\[ (g \circ f)(2) = 7 \][/tex]

In summary:
a. [tex]\((f \circ g)(x) = -3x^2 - x - 4\)[/tex]

b. [tex]\((g \circ f)(x) = 3x^2 - 7x + 9\)[/tex]

c. [tex]\((f \circ g)(2) = -18\)[/tex]

d. [tex]\((g \circ f)(2) = 7\)[/tex]