Because there is a discontinuity in polarization at the boundary of the dielectric disc, a bound surface charge appears, which is the source of the electric field inside and outside the disc.
We have for the electric field at the origin.
$$
\vec{E}=-\int \frac{\sigma^{\prime} d S}{4 \pi \varepsilon_{0} r^{3}} \vec{r}
$$
where $\vec{r}=$ radius vector to the origin from the element $d S$.
$\sigma^{\prime}=P_{n}=P \cos \theta$ on the curved surface
$\left(P_{n}=0\right.$ on the flat surface. $)$
Here $\theta=$ angle between $\vec{r}$ and $\vec{P}$ By symmetry, $\vec{E}$ will be parallel to $\vec{P}$. Thus
$$
E=-\int_{0}^{2 \pi} \frac{P \cos \theta R d \theta \cdot \cos \theta}{4 \pi \varepsilon_{0} R^{2}} \cdot d
$$
where, $\quad r=R$ if $d \ll R$.
So, $E=-\frac{P d}{4 \varepsilon_{0} R}$ and $\vec{E}=-\frac{\vec{P} d}{4 \varepsilon_{0} R}$