This paper considers a two-way relay network in which two source nodes exchange messages during two time slots with the help of a half-duplex amplify-and-forward relay node. Closed form expressions of source and relay node powers are obtained by solving an optimization problem which aims to minimize system total power by constraining source nodes' received signal-to-noise ratios (SNR). Furthermore, the variation of optimum powers for different channel variance scenarios is investigated. For comparison, the distribution in the total power consumption by allocating optimum powers versus equal powers is shown by numerical results. Furthermore, the outage performances of optimum power allocation (OPA) and equal power allocation (EPA) schemes are simulated. Numerical and simulation results show that the OPA scheme outperforms the EPA in all scenarios.