Free rider problem in game theory Suppose a town is building a bridge, and it costs $B$.
There are $n$ villagers.

Each village's valuation of the bridge is private information, $v_i$.

It is common knowledge that this valuation is drawn from a uniform distribution $[0,1]$. $B\in[0,1]$.

Villager can only submit $0$ or $B$.

If one villager submits $B$, then the bridge is built and every other villager pays their submission.

If no bridge is built, everyone gets $0$.

How do I construct an expected payoff a village $i$?

What I got down to is having 2 scenarios: $v_i&gt;B$ and $v_i\leq B$.

But in each case, I have two possible payoffs. For the former case,


  if every other player submits $0$, $i$ should submit B, because $v_i-B&gt;0$.
  if someone pays $B$, $i$ should submit 0, because she gets $v_i$.


You get a similar type of for the other scenario.

But how would I incorporate this into expected payoff of $i$ and how should I go about constructing a social welfare function?

I feel like this is just a variation of all-payout auction with discrete action space for each $i$.
Let $b_i\in\{0,B\}$ be $i$'s strategy. Then $i$'s payoff depends on the strategy profile $(b_i,b_{-i})$, where $b_{-i}=(b_j)_{j\ne i}$. 

\begin{equation}
u_i(b_i,b_{-i})=
\begin{cases}
v_i&amp;\text{if $b_i=0$ and $b_j=B$ for some $j\ne i$}\\
0&amp; \text{if $b_i=0$ and $b_j=0$ for all $j\ne i$}\\
v_i-B&amp;\text{if $b_i=B$}
\end{cases}
\end{equation}

Thus, $b_i=B$ is a best response if 
\begin{equation}
u_i(B,b_{-i})\ge u_i(0,b_{-i})
\quad\Leftrightarrow\quad 
v_i-B\ge (1-\Pr(b_j=0,\;\forall j\ne i))v_i.\tag{1}
\end{equation}

Since the game is ex ante symmetric, we could further assume that every $i$ adopts a threshold strategy, i.e. 
\begin{equation}
b_i=\begin{cases}
0&amp;\text{if $v_i\le\overline v$}\\
B&amp;\text{if $v_i&gt;\overline v$}
\end{cases}\tag{2}
\end{equation}
where $\overline v$ is some common threshold value. Then, the probability in $(1)$ can be written as 
\begin{equation}
\Pr(b_j=0,\;\forall j\ne i)=\Pr(v_j\le \overline v,\;\forall j\ne i)=(\overline v)^{n-1},\tag{3}
\end{equation}
where the last equality is obtained from the assumption that $v_j$'s are i.i.d. and $v_j\sim U[0,1]$. 

Consolidating $(1)$ to $(3)$, we can solve for the cutoff value $\overline v=B^{1/n}$.