# expand function as power series of another function

Suppose I have a well-known function $$f(x)$$ and I want to know if this function can be expanded into power series of another function $$g(x)$$, like $$f(x)=\sum_n a_n g^n(x)$$, where $$a_n$$ is the coefficient of $$n$$-th power of $$g(x)$$. How should I do this using Mathematica?

• How about f[x_] = Sin[x]; g[x_] = 3 + x^(1/2); sol = First@Solve[g[x] == y, x]  yiels {x -> 9 - 6 y + y^2}  and Series[f[x /. sol], {y, 0, 2}]  yields SeriesData[y, 0, { Sin[9], (-6) Cos[9], Cos[9] - 18 Sin[9]}, 0, 3, 1]  . – Akku14 Oct 16 '20 at 19:12
• Thanks a lot! It works! – lol Oct 16 '20 at 22:12
• For searching purposes: what is being sought here is sometimes referred to as a Bürmann series. – J. M.'s ennui Jan 27 at 12:18

Series[f[InverseFunction[g][y]],{y,0,10}]