Complex functions I need help solving this problem:
For $z$ a complex number, let $g(z) = \frac{1 + 2z }{1 + z}$. Find a function $h_1(z)$ such that $h_1(g(z)) = z$ and another (possibly the same) $h_2(z)$ such that $g(h_2(z)) = z$. Use Maple to simplify yout expressions.
Any ideas?
 A: Denote $w=\frac{1+2z}{1+z}$. Now isolate $z$: 
$$(1+z)w=1+2z\Rightarrow z(w-2)=1-w\Rightarrow z=\frac{1-w}{w-2}$$
Now denote $h_1(w)=h_2(w)=\frac{1-w}{w-2}$. This is called finding the inverse.
Compute $g(h_2(z))$ and $h_1(g(z))$.
A: Basically, invert the matrix:
$\begin{pmatrix} 1 & 2 \\ 1 & 1\end{pmatrix}$.
(You can check that composition of these rational functions straightly corresponds to 2x2 matrix multiplication.)
A: If $f(z)= \frac{az+b}{cz+d} ,  ad-bc \not= 0$, then $f^{-1}(z)=\frac{dz-b}{-cz+a}$.
A: Because you got instruction to do (at least some of) it in Maple...
restart:

g := s -> (1+2*s)/(1+s);     # g is an operator (ie. function)

                             1 + 2 s
                        s -> -------
                              1 + s 

g(z);                        # g(z) is an expression

                            1 + 2 z
                            -------
                             1 + z 

isolate(g(z)=t, z);          # isolate g(z) for z

                                -1 + t
                          z = - ------
                                -2 + t

rhs(%);                      # an expression

                              -1 + t
                            - ------
                              -2 + t

h1:=unapply(%, t);           # h1 is also an operator

                               -1 + t
                        t -> - ------
                               -2 + t

h1(g(z));                    # composition of operators (functions)

                                1 + 2 z
                           -1 + -------
                                 1 + z 
                          - ------------
                                1 + 2 z
                           -2 + -------
                                 1 + z 

simplify(%);                 # you've shown h1(g(z))=z

                               z

g(h1(z));                    # composition of operators

                             2 (-1 + z)
                         1 - ----------
                               -2 + z  
                         --------------
                               -1 + z  
                           1 - ------  
                               -2 + z  

simplify(%);                 # h1 serves as desired h2, as well

                               z

