Before revision:   The solution for optimizing power allocation  is also provided  . Numerical results are provided to demonstrate substantial performance gain of the jointly optimal solution over some suboptimal alternatives.
After revision:  The solution for optimizing power allocation is also provided , as well as an asymptotically optimal solution for AF relaying . Numerical results are provided to demonstrate substantial performance gain of the jointly optimal solution over some suboptimal alternatives.