f(x) = ax + b
g(x) = c$x^2$ + dx
So here's what I have:
$f ◦ g = a(cx^2 + dx) + b = acx^2 + adx + b$
$g ◦ f = c(ax + b)^2 + d(ax + b) = ca^2x^2 + 2acxb + b^2c + dax + db$
$g ◦ f = f ◦ g$
$ca^2x^2 + 2acxb + b^2c + dax + db = acx^2 + adx + b$
$ca^2x^2 + 2acxb + b^2c + db = acx^2 + b$
I'm stuck here and not sure what to do next. Did I go down the wrong path? Is there something I could simplify further?
The algebra in your substitution was not correct. $f\circ g$ is right, but $g\circ f(x)=a^2cx^2+(2abc+ad)x+b^2c+bd$. When you set the two equal to each other and compare the coefficients of $x^2,x,1$, you get the equations $a^2c=ac$, $2abc=0$, $b^2c+bd=b$.
This gives you three cases, depending on whether $a=0$ or $b=0$ or $c=0$, and you should be able to find the proper restrictions on $a,b,c,d$ in these cases.
When $a=1,b=0$, $f$ is the identity function, so equality holds whatever $c,d$ are. This shows that the condition $b+d=1$ doesn't always hold. Also note there are combined cases like $a=b=0$, where $c,d$ can be anything, or $b=c=0$, where $a,d$ can be anything.