I am a new Mathematica user, and I apologize in advance if my question is too trivial. I could not find a solution to my problem in Mathematica tutorials, so I came here to ask.
I am trying to find the nash equilibrium in a duopoly setting where firms are profit maximizers.
Sales of firms are given as:
z1 = Piecewise[{{Min[x1, 1 - p1] ,
p1 < p2}, {Min[x1, Max[((1 - p1)/2), 1 - p1 - x2]],
p1 == p2}, {Min[x1, Max[0, 1 - p1 - x2]] , p1 > p2}}]
z2 = Piecewise[{{Min[x2, 1 - p2] ,
p2 < p1}, {Min[x2, Max[((1 - p2)/2), 1 - p2 - x1]],
p1 == p2}, {Min[x2, Max[0, 1 - p2 - x1]] , p2 > p1}}]
where p
=price, x
=capacity
Firm1
is trying to maximize profit1=p1*z1-x1^2
and has control over parameters x1 & p1.
Firm2
is trying to maximize profit2=p2*z2-x2^2
and has control over parameters x2 & p2.
As an initial step, I am interested in finding the maximum profit of each firm given capacities. So I want firm1 to maximize profit1 with respect to p1, and firm2 to maximize profit2 with respect to p2 simultaneously.
I tried computing
Solve[{D[profit1, p1] == 0, D[profit2, p2] == 0}, {p1, p2}]
but this method is not reliable since profits are piecewise functions. It does give a solution when capacities are symmetric, but returns null otherwise.
When I try using the Maximize
function (which I am not sure if I am using correctly) I get an error.
I tried computing
Solve[{Maximize[profit1, p1], Maximize[profit2, p2]}, {p1, p2}],
this gives the following error:
Can anybody help me on simultaneous maximization of these two different functions?