1 Introduction

A duopoly is a standard problem in economics, politics, and marketing that considers the competition between two (dominant) players over a market, for example, see [10]. Illustrative examples of real-life duopolies are Airbus/Boeing in the market of large commercial airplanes, Republican/Democratic parties in the American politics.

Traditional research on competitive games between marketers assumes a homogeneous population of consumers [6, 7]. Unlike these works, we propose a marketing resource allocation based on the influence power that each individual has over the (physical or digital) social network. Basically, we consider that the advertising is done in two steps: the first is done by the marketer that allocate her resources to sway some individuals/agents on her opinion and the second is done by the agents of the social network who influence each other. Consequently, each marketer has to target appropriate influential agents in the network in order to optimize her revenue. Since the focus of the paper is on the resource allocation of the marketer, the second step is modeled by a simple opinion dynamics model introduced in [4].

In this paper we consider the challenging problem that requires to minimize the distance between average of opinions and a desired value using a given control/marketing budget over a social network split in two groups. Basically, this social network with contrarian population represents a model for real cases such as supporters of competing teams, parties, etc. On top of this assumption on the network structure we also assume that the maximal marketing influence cannot instantaneously make the opinion of one individual to be equal with the desired value.

In the literature on viral marketing, the idea that members of a social network influence each other’s purchasing decisions have been studied, with the goal being to select the best set of people to market to such that the overall profit is maximized by propagation of influence through the network [5]. This problem has since received much attention, including both empirical and theoretical results [1], but these results often consider a single entity influencing the network.

In this paper, we consider two competing marketers who want to use their marketing budget in order to sway on their side as many individuals of the network as possible. Thus, the natural framework to exploit is that of game theory and a reasonable solution concept (for arguments see e.g., [8]) for analyzing such a competition situation is the Nash equilibrium (NE). In [9], the authors consider multiple influential entities competing to control the opinion of consumers under a game theoretical setting. However, this work assumes an undirected graph and a voter model for opinion dynamics resulting in strategies that are independent of the node centrality (i.e., agent influence power). On the other hand, the recently published work [11] considers a similar competition with opinion dynamics over a directed graph but with no budget constraints and by considering the average agents’ opinion instead of the final one; these two differences change the problem significantly.

Notation. Let \(\mathbb {R}^{}_{}:=(-\infty ,\infty )\) and \(\mathbb {R}_{\ge 0}:=[0,\infty )\). We use \(I_{n}\) for the identity matrix, \(\mathbf {1}_{n}\) for the column vector of 1 and \(\mathbf {0}_{n}\) for the column vector of 0, \(n \in \mathbb {N}\). In the sequel, the symbol ||.|| corresponds to the norm2 and \(x^{\top }\) stands for the transpose of x, \(x \in \mathbb {R}^{n}\).

2 Problem Statement

We consider a social network populated by agents belonging to the set \(\mathcal {V}:= \{1,2,\dots ,n\}\). The parameters \(a_{i,j}\) characterize the influence of agent j on agent i, \(i \ne j\) and \(i,j \in \mathcal {V}\). The opinions of agent i at time step k is denoted by \(x_i(k)\) and evolves according to

$$\begin{aligned} x_i(k+1) =x_i(k) + \delta \,\, \left( \sum _{j \in \mathcal {V}} a_{i,j} (x_j(k)-x_i(k)) \right) \,\,, \end{aligned}$$
(1)

due to their interaction with other agents in the social network. In our problem, we consider the case where these agents are also influenced by the marketing/advertising of two marketers. The desired opinion of Marketer m is \(d_m \in \mathbb {R} \), \(m \in \{1,2\}\). As a result of these interactions, the opinion dynamics for x(k), the collective vector of all opinions is given by

$$\begin{aligned} x(k+1)= D x(k) + B_{1}u_1(k) + B_{2}u_2(k), \end{aligned}$$
(2)

where \(D = I_{n} - \delta L \) is the row stochastic matrix defining the internal dynamics of the network with \(L\in \mathbb {R}^{n\times n}\) being the Laplacian matrix associated with adjacency \(a_{i,j}\), \(B_{m}\) denotes the manner in which the Marketers influence the agents and \(u_{m}\) is the action of Marketers m on the agents. We concentrate on two influence models:

  1. 1.

    Uniform broadcasting (UB) with \(B_m = (1,1,\dots ,1)^\top \) which implies that all agents in the network receive the same control. This influence model corresponds to traditional advertising/marketing done on television or radio where the control is applied uniformly on all agents.

  2. 2.

    Targeted advertising (TA) with \(B_m = I_n\) which implies that the advertising control can be designed for each individual in the network. This model corresponds to modern social media marketing as done by companies like Facebook or Google.

Let \(\mathbf {u}_m \) denote the sequence of control actions applied by Marketer m. We define the infinite horizon cost for Marketer m as

$$\begin{aligned} J_m(\mathbf {u}_1,\mathbf {u}_2) := \sum _{k=0}^\infty \alpha ^k \left( ||x(k) - d_m \mathbf {1}_{n}||^2 + u_m(k)^T R_m u_m(k) \right) , \end{aligned}$$
(3)

where \(\alpha \in (0,1)\) is a discount factor which is often related to inflation rates/interest rates in economic literature. We assume that the revenue generated by the firm associated to Marketer m at time k depends on the market share captured by the firm. As the distance between the opinions of agents in the social network and the desired opinion \(d_{m}\) decreases, the revenue increases. Alternately, we say that the loss incurred by not capturing the entire market is characterized by \(\sum _{i \in \mathcal {V}}||x_{i}(k) - d_{m}||^2\). On the other hand, advertising to agent i incurs a cost which we take to be \(u_m^T R_m u_m\). The term \(R_{m}\) is like the price for advertisements.

3 Analysis

Unlike standard control theory problems, in our framework, we have two competing marketers who attempt to bring \(x_i(k)\) to a desired opinion \(d_m \in \mathbb {R}\) with \(d_1 \ne d_2\). If \(d_1=d_2\), the problem can be seen as a distributed optimal control problem. However, when \(d_1 \ne d_2\), each marketer has its own objective resulting in a non-cooperative game. Due to the cost function depending on x(k) and its dynamics, we have a dynamic game [2].

The problem we consider corresponds to a difference-game as introduced in [2]. However, since these games are hard to analyse in the most general case, we make the following assumption.

Assumption 1

We assume that each marketer applies a static state feedback strategy,

$$\begin{aligned} u_m(k) = G_m (d_{m}\mathbf {1}_{n} -x(k)) - M_m, \end{aligned}$$
(4)

where \(G_m \in \mathbb {R}^{n \times n}\) is a fixed feedback gain and \(M_m\in \mathbb {R}^{n}\) is an offset applied to balance the opposing marketer resulting in the strategy given by \(K_m:= \begin{pmatrix} G_1&M_1 \end{pmatrix} \in \mathbb {R}^{n \times n+1}\).

We can redefine the cost \(J_m\) in terms of the static feedback strategy \(K_m\) as

$$\begin{aligned} J_m(K_1,K_2): = \sum _{k=0}^\infty \alpha ^k \left( ||x(k) - d_m \mathbf {1}_{n}||^2 + u_m(k)^T R_m u_m(k) \right) , \end{aligned}$$
(5)

where x(k) follows (2) and \(u_m(k)\) is given by (4).

Under Assumption 1, we can reformulate the dynamic game with actions \(\mathbf {u}_m\) as a static one-shot game with the action space of each player corresponding to being the control gain and offset. Formally, we define the game \(\mathcal {G}\) in strategic form as follows

$$\begin{aligned} \mathcal {G} := \left( \{1,2\}, \{ \mathcal {K}_1,\mathcal {K}_2 \}, \{ J_1,J_2 \} \right) , \end{aligned}$$
(6)

where:

  1. 1.

    \(\{1,2\}\) is the set of players or Marketers;

  2. 2.

    \(\mathcal {K}_m\) is the set of pure actions for player m, specifically, we have \(K_m = \begin{pmatrix} G_1&M_1 \end{pmatrix} \in \mathcal {K}_m= \mathbb {R}^{n\times (n+1)} \);

  3. 3.

    \(J_m(K_1,K_2)\) as defined in (5) is the cost function for player m;

A natural solution concept for a game is that of the Nash equilibrium. For convenience, we use \(-m\) to denote the other player, i.e. \(3-m\) for all \(m \in \{1,2\}\). A pure Nash equilibrium (NE) is defined for the game \(\mathcal {G}\) as follows.

Definition 1

We say that \((K_1^*,K_2^*)\) form a NE of the game \(\mathcal {G}\) if and only if

$$\begin{aligned} J_m(K_m,K_{-m}^*) \ge J_m(K_m^*,K_{-m}^*), \end{aligned}$$
(7)

for all \(K_m \in \mathcal {K}_m\) and for all \(m \in \{1,2\}\).

The NE is a suitable notion to study player interactions in a non-cooperative game when all players behave rationally and are capable of computing the best decisions to make for a given opponent strategy. However, this assumption on player behavior may not always hold and some players may behave differently or play simpler/naive strategies.

As a first step, we consider the case where player 2 is naive, i.e. it plays a given strategy \(K_2\). In the following, we compute the best response player m can do for a given strategy player \(K_{-m}\) played by \(-m\).

3.1 Best Response to a Given Opponent Strategy

Let \(\beta _m(K_{-m})\) denote the best response function defined as

$$\begin{aligned} \beta _m(K_{-m})= \arg \min _{K_m} J_m(K_m,K_{-m} ) . \end{aligned}$$
(8)

In general, the best response function is set valued as the \(\arg \min \) is not unique. However, the following proposition provides a unique best response and the method to find this value.

Proposition 1

The best response function is unique and can be evaluated as

$$\begin{aligned} \beta _{m}(K_{-m}) = \alpha (\tilde{B}_{m}^{\top }P_{m}\tilde{B}_{m}+R_m )^{-1}\tilde{B}_{m}^{\top }P_{m} \tilde{D}_{m}, \end{aligned}$$
(9)

where \(\tilde{D}_m=\begin{pmatrix} D-B_{-m}G_{-m} &{} B_{-m} (G_{-m} \mathbf {1}_{n}(d_{-m}-d_{m}) - M_{-m}) \\ \mathbf {0}_{n}^{\top } &{} 1 \end{pmatrix} \), \(\tilde{B}_{m}=\begin{pmatrix} B_{m}\\ \mathbf {0}_{n}^{\top }\\ \end{pmatrix}\) and \(P_m\) is the solution to the Algebraic Riccati equation

$$\begin{aligned} P_m = \tilde{D}_{m}^{\top }(\alpha P_{m} - \alpha ^{2}P_{m} \tilde{B}_{m}(\alpha \tilde{B}_{m}^{\top }P_{m}\tilde{B}_{m}+R_{m})^{-1}\tilde{B}_{m}^{\top }P_{m})\tilde{D}_{m}+Q_{m}, \end{aligned}$$
(10)

where \(Q_{m}=\begin{pmatrix} I_{n} &{} \mathbf {0}_{n}. \\ \mathbf {0}_{n}^{\top } &{} 1\\ \end{pmatrix}\)

Proof

Here, we search for \(u_{1}^*\) minimizing the cost \(J_1(u_1,u_2)\) supposing \(u_{2}\) is known. The reasoning is still the same to find \(u_{2}^*\) for \(u_1\) known. Under Assumption 1, we have

$$\begin{aligned} x(k+1)=D x(k) + B_{1}u_{1}(k) + B_{2}G_{2} (d_{2}\mathbf {1}_{n} -x(k)) - B_{2}M_{2}. \end{aligned}$$
(11)

Let \(e_{1}(k)=x(k)-d_{1}\mathbf {1}_{n}\) be the error for the desired opinion \(d_{1}\). The error dynamics is

$$\begin{aligned} \begin{aligned} e_{1}(k+1)&= (D-B_{2}G_{2})e_{1}(k) + B_{1} u_{1}(k) + B_{2} G_{2}\mathbf {1}_{n}( d_{2}-d_{1}) - B_{2} M_{2},\\ \end{aligned} \end{aligned}$$
(12)

where \(B_{2} G_{2}\mathbf {1}_{n}( d_{2}-d_{1}) - B_{2} M_{2}\) is a constant affine term. We modify (12) by including the affine term in the state variable and we use an algorithm from the Sect. 4.2 of Vol. II, 4th Ed. of [3], to solve (10). The modified system is

$$\begin{aligned} \begin{pmatrix} e_{1}(k+1)\\ 1\\ \end{pmatrix} = \tilde{D}_{1} \begin{pmatrix} e_{1}(k)\\ 1\\ \end{pmatrix} + \tilde{B}_{1} u_{1}, \end{aligned}$$
(13)

where \( \tilde{D}_{1} =\begin{pmatrix} D-B_{2}G_{2} &{} \,B_{2} G_{2}\mathbf {1}_{n}( d_{2}-d_{1}) - B_{2} M_{2}\\ \mathbf {0}_{n}^{\top } &{} 1\\ \end{pmatrix}\) and \(\tilde{B}_{1}=\begin{pmatrix} B_{1}\\ \mathbf {0}_{n}^{\top }\\ \end{pmatrix}\).

Finally, the optimal control \(u_{1}^{*}\) depending on \(u_{2}\) is

(14)

which is consistent with Assumption 1. Thus, the the best response is \(\beta _{m}(K_{-m})= \begin{pmatrix} G_1&M_1 \end{pmatrix}\). The uniqueness of the solution comes from the uniqueness of the Riccati solution.

3.2 Nash Equilibrium

We propose the following iterative asynchronous best response algorithm to find a Nash equilibrium of the game \(\mathcal {G}\). While the convergence of the iterative best response dynamics, i.e., Algorithm 1 is not guaranteed for all game classes, our numerical tests show that this property holds as illustrated in the next section.

figure a

4 Numerical Illustration

In this section, we will study the performance of targeted advertising (TA) when compared to uniform broadcasting (UB). For all our numerical tests, we will consider the graph presented in Fig. 1. We take \(d_1=2\) and \(d_2=-2\). When player m is implementing TA, we take \(R_m \in \{I_n,2 I_n\}\), and \(R_m \in \{n,2n\}\) while implementing UB. We consider the following initial conditions

$$x_A = (1,2,-3,0,6,-5,4,3,-2,4)^{\top } \text{ and } x_B = (4,-2,-2,-3,2,0,2,-1,1,0)^{\top }. $$

As a first step, we consider the situation when both marketers apply the NE strategy, but when Marketer 1 applies TA and Marketer 2 UB. Since for UB, the control \(u_2\) is applied to all n agents, we take \(R_2=n\) and \(R_1=I_n\) to look at a symmetric situation in terms of the Marketer revenue and cost. If we take a graph where all agents have the same centrality, we notice that the opinions of all agents converge to 0 which lies at the middle of \(d_1\) and \(d_2\) due to the symmetry.

However, if we consider the graph as in Fig. 1 with \(x(0)=x_A\), the opinions evolve as seen in Fig. 2 with the average final opinion being closer to \(d_1\), the desired opinion of Marketer 1. This demonstrates the advantage of TA and Table 1 further illustrates how Marketer 1 prioritizes advertising the agents with a higher centrality (vector centrality associated to the Laplacian matrix).

Fig. 1.
figure 1

Directed graph of 10 agents.

Fig. 2.
figure 2

Opinion dynamics with \(R_{1}=I_{n}\) and \(R_{2}=n\).

Table 1. Centrality of each agent

In Fig. 3 and Fig. 4, we plot the evolution of average opinion when both Marketers apply TA or UB respectively. Interestingly, consensus is reached when TA is applied only when \(R_1=R_2\) and in this case all the opinions converge to 0 which lies halfway between \(d_1\) and \(d_2\). However, taking \(R_2= 2 R_2\) results in the opinions converging to

$$\lim _{t \rightarrow \infty } x(t)= (2.48;0.96;0.55;0.42;1.69;0.02;-0.86;0.2055;1.19;-0.14)^T.$$

We notice that for all \(R_m\), UB vs UB results in consensus. The corresponding costs are provided in Table 2.

Fig. 3.
figure 3

Opinion dynamics in the scenario TA

Fig. 4.
figure 4

Opinion dynamics in the scenario UB

Table 2. Costs depending on the scenario and the initial condition

5 Conclusion

In this work, we have studied the behavior of two competing firms/marketers that control the opinions of a set of consumers interacting over a social network. We consider a linear interaction model and quadratic costs for each firm related to the revenue earned and the amount they spent in order to control the network (via advertisements or other marketing strategies). As a first step, we find the optimal static state feedback control which must be applied by a marketer assuming that the other marketer applies a given strategy. Next, we provide an iterative algorithm, which we observe to converge to the Nash equilibrium after extensive numerical tests. We provide numerical examples which illustrate the advantage of viral marketing techniques (targeted advertising based on the social graph) when compared to traditional advertising strategies (uniform broadcast). Future work will focus on theoretically studying the existence and uniqueness of the Nash equilibrium of the game we have studied.