Laplace mechanism in Differential Privacy From The Algorithmic Foundations of Diﬀerential Privacy
It wrote that :



But from this pdf



I am confused which one is right, or I misunderstand.

In second method, after I compute Pr[v], and then what to do?

I am not sure how to implement the Laplace mechanism.
These two formulas are the same thing. The second formula is the probability density function of the Laplace distribution centered on 0 ($\mu=0$) — although rather than $Pr[v]$, the second PDF should probably have used a notation like $f(v)$ to make it clear that this is a probability density function and not the probability of returning exactly $v$.
If the question about &quot;how to implement the Laplace mechanism&quot; was referring to something you want to do in practice, then you probably don't want to do it yourself; but you want to use an implementation safe against floating-point attacks. Here's an example of open-source software you can use (disclaimer: I'm part of the team behind that library).