Understanding definition of gerbe over a stack I am reading Differentiable Stacks and Gerbes by Kai Behrend and Ping Xu.
They define gerbe over a stack as follows.

Let $\mathfrak{X}$ be a differentiable stack. An $\mathfrak{S}$-stack $\mathfrak{R}$ endowed with a morphism $F:\mathfrak{R}\rightarrow \mathfrak{X}$ is called a gerbe over $\mathfrak{X}$ if both  $\mathfrak{R}\rightarrow \mathfrak{X}$ and $\mathfrak{R}\rightarrow \mathfrak{R}\times_{\mathfrak{X}}\mathfrak{R}$ are epimorphisms.

I am having trouble realizing the map $\mathfrak{R}\rightarrow \mathfrak{R}\times_{\mathfrak{X}}\mathfrak{R}$. Some people call this diagonal map with out even mentioning the map explicitly.
I will recall the definition of $2$-fibered product 

Let $$\pi_X:X\rightarrow \mathcal{C}, \pi_Y:Y\rightarrow
 \mathcal{C},\pi_Z:Z\rightarrow \mathcal{C}$$ be categories fibered in
  groupoids and  $$f:Y\rightarrow X, g:Z\rightarrow X$$ be morphisms of
  categories fibered in groupoids.
The $2$-fibered product $Z\times_XY$ is the category whose objects are
  given by  $$(Z\times_XY)_0=\{(y,z,\alpha)\in Y_0\times Z_0 \times X_1
 : \pi_Y(y)=\pi_Z(z), \alpha:f(y)\rightarrow g(z)\}.$$ 
  $$\text{Hom}_{Z\times_X Y}((y,z,\alpha),(y',z',\alpha'))=
 \left\{(u:y\rightarrow y',v:z\rightarrow z') |\alpha'\circ
 f(u)=g(v)\circ \alpha \right\}$$

Is the map $\mathfrak{R}\rightarrow \mathfrak{R}\times_{\mathfrak{X}}\mathfrak{R}$  is just given by 


*

*$\mathfrak{R}_0\rightarrow (\mathfrak{R}\times_{\mathfrak{X}}\mathfrak{R})_0$ with $y\mapsto (y,y,id:F(y)\rightarrow F(y))$.

*$\mathfrak{R}_1\rightarrow (\mathfrak{R}\times_{\mathfrak{X}}\mathfrak{R})_1$ with $(y\xrightarrow{\tau}z)\mapsto (y\xrightarrow{\tau} z,y\xrightarrow{\tau}z)$??


I am not very sure if I understand this correctly. Can some one please confirm this? What does this map and the original map $F:\mathfrak{R}\rightarrow \mathfrak{X}$ being epimorphism signifies?
 A: If R→X is an epimorphism, then each fiber F_x is nonempty. Then if R→R ×_X R is an epimorphism, this means that π_0(F_x) is a point (otherwise π_0(F_x)→π_0(F_x) × π_0(F_x) cannot be an epimorphism), i.e., F_x is (noncanonically) equivalent to the stack BG for some smooth group G. But a gerbe over X is precisely a fiber bundle whose typical fiber is noncanonically equivalent to BG.
A: I am trying to write down what does it mean to say those two maps $\mathcal{D}\rightarrow \mathcal{C}$ and $\mathcal{D}\rightarrow \mathcal{D}\times_{\mathcal{C}}\mathcal{D}$ to be epimorphisms.
I am not very comfortable to use the definition of epimorphism as in  Differentiable Stacks and Gerbes. 
I use the definition of epimorphism as in  Principal actions of stacky Lie groupoids. I am hoping they are equivalent.

A morphism $F: \mathcal{X}\rightarrow \mathcal{Y}$ of categories fibered in groupoids is said to be an epimorphism if, given a manifold $U$, the restriction functor $\mathcal{X}_U\rightarrow \mathcal{Y}_U$ is almost essentially surjective i.e., given $y\in \mathcal{Y}_U$, there exists an open cover $\{U_\alpha\rightarrow U\}$ such that,   there exists $x_\alpha\in \mathcal{X}_{U_\alpha}$ and isomorphisms $F(x_\alpha)\rightarrow y|_{U_\alpha}$ in $\mathcal{Y}_{U_{\alpha}}$.

Let $U$ be a smooth manifold. As $F:\mathfrak{R}\rightarrow \mathfrak{X}$ is an epimorphism, the functor $\mathfrak{R}(U)\rightarrow \mathfrak{X}(U)$ is almost essentially surjective. For simplicity, I assume it is essentially surjetcive i.e., given $x\in \mathfrak{X}(U)$ there exists $r\in \mathfrak{R}(U)$ such that there is an isomorphism $F(r)\rightarrow x$.
Is this what you(@inkspot) mean when you say locally surjective on objects??
As $G:\mathfrak{R}\rightarrow \mathfrak{R}\times _{\mathfrak{X}}\mathfrak{R}$ is an epimorphism, the functor $\mathfrak{R}(U)\rightarrow (\mathfrak{R}\times _{\mathfrak{X}}\mathfrak{R})(U)$ is almost essentially surjective. For simplicity, I assume it is essentially surjective i.e., given an element $(y,z,\alpha)\in (\mathfrak{R}\times _{\mathfrak{X}}\mathfrak{R})(U)$ there exists $x\in \mathfrak{R}(U)$ and an isomorphism $G(x)\rightarrow (y,z,\alpha)$. Here, $\alpha:F(y)\rightarrow F(z)$.
Now, what does it have anything to do with "locally surjective on morphisms"??
Let $a\rightarrow b$ be an arrow in $\mathfrak{X}(U)$. As we have seen above, there is an isomorphism $F(y)\rightarrow a$ and an isomorphism $F(z)\rightarrow b$ where $y,z\in \mathfrak{R}(U)$.
Considering the composition $F(y)\rightarrow a\rightarrow b\rightarrow F(z)$  gives $\alpha:F(y)\rightarrow F(z)$ giving an element $(y,z,\alpha)\in (\mathfrak{R}\times_{\mathfrak{X}}\mathfrak{R})(U)$.
For this, there exists $x\in \mathfrak{R}(U)$ and an isomorphism $G(x)\rightarrow (y,z,\alpha)$. As mentioned in question, $G(x)=(x,x,id:F(x)\rightarrow F(x))$.
Thus, we have an isomorphsim $(y,z,\alpha:F(y)\rightarrow F(z))\rightarrow (x,x,id:F(x)\rightarrow F(x))$. This means, there exists $u:x\rightarrow y, v:x\rightarrow z$ such that $\alpha\circ F(u)=F(v)\circ id$ i.e., $\alpha\circ F(u)=F(v)$.
To write down explicitly, it means the map
$$a\rightarrow F(y)\rightarrow F(x)\rightarrow F(z)\rightarrow b$$
is same as that of the map $a\rightarrow b$ we started with i.e., 
$\phi=\tau\circ F(v\circ u^{-1})\circ \tau'$
Ignoring $\tau, \tau'$ this says any arrow $a\rightarrow b$ is of the form $F(\eta)$ for some arrow $\eta$ in $\mathfrak{R}(U)$.
Is this what you(@inkspot) mean when you say locally surjective on morphisms??

Overall, Is this definition of gerbe over stack mean given a manifold
  $U$ the restriction functor $\mathcal{D}(U)\rightarrow
 \mathcal{C}(U)$ has following properties
  
  
*
  
*given an object $x\in \mathfrak{X}(U)$ there is an open cover $\{U_\alpha\rightarrow U\}$ such that there exists $y_\alpha\in  \mathfrak{R}(U_\alpha)$ and   isomorphisms
  $F(y_\alpha)\rightarrow x|_{U_\alpha}$ for each index $\alpha$.
  
*given an arrow $\phi:a\rightarrow b$ in $\mathfrak{X}(U)$  there is an open cover $\{U_\alpha\rightarrow U\}$ such that there exists an arrow $\tau_\alpha:p_\alpha\rightarrow q_\alpha$ (after
  identifying $F(p_\alpha)$ with $a_\alpha$ and $F(q_\alpha)$ with
  $b_\alpha$) such that $F(\tau_\alpha)=\phi_\alpha$ for each index
  $\alpha$.
  

