Subjects algebra

Find Gx

Step-by-step solutions with LaTeX - clean, fast, and student-friendly.

Use the AI math solver

1. **Stating the problem:** We are given two functions: $f(x) = x^2 + 2x + 5$ and $f(g(x)) = x^2 + 4$. We need to find the function $g(x)$.\n\n2. **Understanding the problem:** The expression $f(g(x))$ means we substitute $g(x)$ into the function $f$. So, wherever there is an $x$ in $f(x)$, we replace it with $g(x)$.\n\n3. **Write the composition explicitly:**\n$$f(g(x)) = (g(x))^2 + 2g(x) + 5$$\n\n4. **Set the composition equal to the given expression:**\n$$ (g(x))^2 + 2g(x) + 5 = x^2 + 4 $$\n\n5. **Rearrange the equation:**\n$$ (g(x))^2 + 2g(x) + 5 - x^2 - 4 = 0 $$\n$$ (g(x))^2 + 2g(x) + 1 - x^2 = 0 $$\n\n6. **Rewrite as a quadratic in $g(x)$:**\n$$ (g(x))^2 + 2g(x) + (1 - x^2) = 0 $$\n\n7. **Use the quadratic formula to solve for $g(x)$:**\nThe quadratic formula for $ax^2 + bx + c = 0$ is $x = \frac{-b \pm \sqrt{b^2 - 4ac}}{2a}$. Here, $a=1$, $b=2$, and $c=1 - x^2$.\n\n$$ g(x) = \frac{-2 \pm \sqrt{2^2 - 4 \cdot 1 \cdot (1 - x^2)}}{2} = \frac{-2 \pm \sqrt{4 - 4 + 4x^2}}{2} = \frac{-2 \pm \sqrt{4x^2}}{2} $$\n\n8. **Simplify the square root:**\n$$ \sqrt{4x^2} = 2|x| $$\n\n9. **Write the two possible solutions:**\n$$ g(x) = \frac{-2 + 2|x|}{2} = -1 + |x| $$\n$$ g(x) = \frac{-2 - 2|x|}{2} = -1 - |x| $$\n\n10. **Interpretation:** Both $g(x) = -1 + |x|$ and $g(x) = -1 - |x|$ satisfy the equation. Depending on the domain or additional conditions, either could be the solution.