Suppose I have two special functions $f_1$ and $f_2$. Is there an algorithm which can tell me whether there exists elementary $g$ such that $f_1 = g\circ f_2$? Furthermore, is there any possibility to construct $g$ when it exists?
Elementary to me means something like, a function constructed from a finite number of function compositions of rational functions, exponentials and logarithms, trig functions and their inverses. Special means non-elementary. If it's necessary to give different definitions to these ones to answer my question, then please go ahead and redefine.