Curiosity about why this is not a Function composition

Join the discussion
Ask a follow-up here, or get your own question answered by working scientists, mathematicians and engineers — people, not an autocomplete.
Real named experts · corrections over time · the nuance an AI answer skips
7 replies · 4K views
ecastro
Messages
249
Reaction score
8

Homework Statement


If ##f\left(x\right) = x^2 + 2x + 2##, find two functions ##g## for which ##\left(f \circ g\right)\left(x\right) = x^2 - 4x + 5##.

Homework Equations


If ##f\left(x\right) = x^2 + 2x + 2##, then ##\left(f \circ g\right)\left(x\right) = g\left(x\right)^2 + 2g\left(x\right) + 2##, so ##g\left(x\right)^2 + 2g\left(x\right) + 2 = x^2 - 4x + 5##

The Attempt at a Solution


By solving for ##g\left(x\right)##,
\begin{align*}
g\left(x\right)^2 + 2g\left(x\right) + 2 - 2&= x^2 - 4x + 5 - 2 \\
g\left(x\right)^2 + 2g\left(x\right) &= x^2 - 4x + 3 \\
g\left(x\right)\left[g\left(x\right) + 2\right] &= \left(x - 3\right)\left(x - 1\right)
\end{align*}

From here ##\left(x - 3\right)## is a solution, but ##\left(x - 1\right)## is not. Now, according to the answers provided, another function ##g## is ##1 - x##, which is the negative of ##x - 1##. How do you arrive at this solution?

I know that it is possible to let ##\left(x - 3\right)\left(x - 1\right) = -\left(x - 3\right)\left(1 - x\right)##, but what is the intuition behind it?
 
  • Like
Likes   Reactions: Leo Consoli
on Phys.org
Well, you have ##g(x) \left [ g(x) + 2 \right ] = (x - 3)(x - 1)## but you could flip the signs and also write ##g(x) \left [ g(x) + 2 \right ] = (3 - x)(1 - x)## and since ##(3 - x)## = ##(1 - x) + 2## you can then identify ##g(x)## with ##(1 - x)## and ##g(x) + 2## with ##(3 - x)##
 
  • Like
Likes   Reactions: SammyS, Leo Consoli and mfb
ecastro said:

Homework Statement


If ##f\left(x\right) = x^2 + 2x + 2##, find two functions ##g## for which ##\left(f \circ g\right)\left(x\right) = x^2 - 4x + 5##.

Homework Equations


If ##f\left(x\right) = x^2 + 2x + 2##, then ##\left(f \circ g\right)\left(x\right) = g\left(x\right)^2 + 2g\left(x\right) + 2##, so ##g\left(x\right)^2 + 2g\left(x\right) + 2 = x^2 - 4x + 5##

The Attempt at a Solution


By solving for ##g\left(x\right)##,
\begin{align*}
g\left(x\right)^2 + 2g\left(x\right) + 2 - \color{red}2 & = x^2 - 4x + 5 - \color{red}2 \\

\end{align*}
That's a good start.

Rather than subtracting 2, subtract 1. That gives the following.

## \left(g(x)\right)^2 + 2g\left(x\right) + 1 = x^2 - 4x + 4 ##​

The expression on each side of the equation is a perfect square.
 
Last edited:
  • Like
Likes   Reactions: Leo Consoli and mfb
RPinPA said:
Well, you have g(x)[g(x)+2]=(x−3)(x−1)g(x)[g(x)+2]=(x−3)(x−1)g(x) \left [ g(x) + 2 \right ] = (x - 3)(x - 1) but you could flip the signs and also write g(x)[g(x)+2]=(3−x)(1−x)g(x)[g(x)+2]=(3−x)(1−x)g(x) \left [ g(x) + 2 \right ] = (3 - x)(1 - x) and since (3−x)(3−x)(3 - x) = (1−x)+2(1−x)+2(1 - x) + 2 you can then identify g(x)g(x)g(x) with (1−x)(1−x)(1 - x) and g(x)+2g(x)+2g(x) + 2 with (3−x)

Is there any particular reason why we should flip signs?

SammyS said:
That's a good start.

Rather than subtracting 2, subtract 1. That gives the following.

## \left(g(x)\right)^2 + 2g\left(x\right) + 1 = x^2 - 4x + 4 ##​

The expression on each side of the equation is a perfect square.

Oh, I never thought of this. Thanks!
 
ecastro said:
Is there any particular reason why we should flip signs?

Because it gives another solution. It's just a thing to try, an equivalent equation with potentially a different solution. Which turns out to be the case.
 
Sorry if this is too far of an aside, but I always wondered how to determine the number of solution to functional equations, or a method that exhausts all solutions. What if we, e.g., have the equation f(x)^3 =Id, aka, find all f with fofof(x) =x (where o means function composition).
 
ecastro said:
Is there any particular reason why we should flip signs?
RPinPA said:
Because it gives another solution. It's just a thing to try, an equivalent equation with potentially a different solution. Which turns out to be the case.
To further answer OP's question:

Rather than saying "flip the signs", consider the following.

You can write ##\ (x-3)\ ## as ##\ -(-x+3)\ ##.

Similarly write ##\ (x-1)\ ## as ##\ -(-x+1)\ ##.

So, ##\ (x-3)(x-1) =(-(-x+3))(-(-x+1)) = (-x+3)(-x+1) \ ##.

To finish things off:
Write this as ##(-x+1)(-x+3) = ((-x+1))((-x+1)+2) \ ##.
Combine this with what you have done in the OP.
 
  • Like
Likes   Reactions: Leo Consoli
WWGD said:
Sorry if this is too far of an aside, but I always wondered how to determine the number of solution to functional equations, or a method that exhausts all solutions. What if we, e.g., have the equation f(x)^3 =Id, aka, find all f with fofof(x) =x (where o means function composition).
This is complicated and way beyond the scope of this thread if treated properly.
 
  • Like
Likes   Reactions: WWGD