Finding optimal strategies for influencing social networks in two player games