Matlab code for the figures and the examples used in G. Bacci, L. Sanguinetti, and M. Luise, "Understanding game theory via wireless power control,' submitted to IEEE Signal Process. Mag., Oct. 2014.