Doubt around Covariance definition Given the general definition of Covariance between two random variables $x$ and $y$:
\begin{equation*}
\text{Cov}(x,y)=\frac{1}{n}\sum_{i=1}^n(x_i-\bar{x})(y_i-\bar{y})
\end{equation*}
Does the above definition implicitly assume that every bivariate observation $(x_i,y_i)$ has the same relative frequency, namely equal to $\frac{1}{n}$?
I would expect that for bivariate observations with different relative frequency, the above definition (given that the value set of component random variable $x$ has $r$ values while that of $y$ has $s$ values) would become equal to:
\begin{equation}
\text{Cov}(x,y)=\sum_{i=1}^r\sum_{j=1}^sf_{x,y}(x_i,y_i)(x_i-\bar{x})(y_i-\bar{y})
\end{equation}
with $f_{x,y}(x_i,y_i)$ denotes the relative frequency of the pair $(x_i, y_i)$.
Is my reasoning correct or am I wrong? Why?

Use of the Roman alphabet rather than Greek implies that we are talking about sample observations rather than the population. In a sample, each observation does in fact have the same relative frequency (if the same pair of values appears more than once, they will still be different observations, and each of those observations appears once). However, if the mean is being estimated by $\bar x$ rather than being known, then $\frac 1{N-1}$ rather than $\frac 1 N$ is used.
For the population covariance, the formula is $\int \int p(x,y)(x-\mu_x)(y-\mu_y)dxdy$, which for a discrete distribution reduces to $\sum \sum p(x,y)(x-\mu_x)(y-\mu_y)$
