Birthday paradox for adjacent dates: exact probability I've seen a lot of questions on here that answer the birthday paradox, e.g. the probability $n$ people in a room share the same birthday, where a year is 365 days. So I won't rehash the proof that the formula is
$$p(n) = 364/365 * 363/365 * ... * (365-(n-1)) / 365$$
But I was wondering about the exact probability $p(n)$ that two people either share the same birthday or have a birthday one day apart.
I was able to figure things roughly. Each day you choose most likely wipes out two other days, so my initial guess q(n) was
$$q(n) =~ 362/365 * 359/365 * ... * (365-3(n-1)) / 365$$
The problem with this is that person $A$ may have a birthday on January 3, and if person B has one on January 1, then the 2nd term of $q(n) is 360/365 and not 359/365.
Now if we just want to see the number of people to make p(n) be about .5, this won't matter much. I can do a bit of hand waving to show that if $Z$ is the number such that $p(Z) < .5 < p(Z-1)$, then $Z'$ so that $q(Z') < .5 < q(Z'-1)$ is roughly $Z'/sqrt(3)$.
So if we write the formula for $q'(n)$ as
$$q'(n) = \prod_{i=0}^n r(n)$$
where $r(n)$ is the probability that person $n$ is the first one with an adjacent birthday to the previous $n-1$, there are a few observations.
$r(n)$ must be close to $\frac{368-3n}{365}$ and it clearly must be more than $\frac{369-2n}{365}$ because, except for December 31, each date takes out the next day...or there's been a date ahead of it that takes out the next and previous days. 
For the purposes of finding $Z'$, $r(n)$ seems much closer to $\frac{368-3n}{365}$ as the possibility of day X being 2 apart from any of days $1...X-1$ overlap at step $Z'$ is quite low for the purposes of finding the halfway point, less than $\frac{3Z'-3}{365}$, in fact.
But in the general case, the estimation doesn't work so well, and I am wondering about an exact value. Because I got lost in the calculations. Any help? Thanks!

Defining events:
