Prove that sample covariance matrix is positive definite Consider the $p \times p$ sample covariance matrix:
$$\mathbf{S} = \frac{1}{n-1} \cdot \mathbf{Y}_\mathbf{c}^\text{T} \mathbf{Y}_\mathbf{c}
\quad \quad \quad
\mathbf{Y}_\mathbf{c} = \mathbf{C} \mathbf{Y},$$
where $\mathbf{C} = \mathbf{I}-\frac{1}{n} \mathbf{1} \mathbf{1}^\text{T}$ is the $n \times n$ centering matrix and
$\mathbf{Y}$ is an $n \times p$ matrix.  How can it be proved that if the variables are continuos, not linearly related and $n-1> p$ then the sample covariance matrix is ​​positive definite?
The following clue is found in Ranchera's book:

 A: First, let's simplify the equation for your sample covariance matrix.  Using the fact that the centering matrix is symmetric and idempotent you get the $p \times p$ form:
$$\begin{align}
\mathbf{S} 
&= \frac{1}{n-1} \cdot \mathbf{Y}_\mathbf{c}^\text{T} \mathbf{Y}_\mathbf{c} \\[6pt]
&= \frac{1}{n-1} \cdot (\mathbf{C} \mathbf{Y})^\text{T} (\mathbf{C} \mathbf{Y}) \\[6pt]
&= \frac{1}{n-1} \cdot \mathbf{Y}^\text{T} \mathbf{C}^\text{T} \mathbf{C} \mathbf{Y} \\[6pt]
&= \frac{1}{n-1} \cdot \mathbf{Y}^\text{T} \mathbf{C} \mathbf{Y}. \\[6pt]
\end{align}$$
This is a simple quadratic form in $\mathbf{Y}$.  I will show that this matrix is non-negative definite (or "positive semi-definite" if you prefer) but it is not always positive definite.  To do this, consider an arbitrary non-zero column vector $\mathbf{z} \in \mathbb{R}^p - \{ \mathbf{0} \}$ and let $\mathbf{a} = \mathbf{Y} \mathbf{z} \in \mathbb{R}^n$ be the resulting column vector.  Since the centering matrix is non-negative definite (it has one eigenvalue equal to zero and the rest are equal to one) you have:
$$\begin{align}
\mathbf{z}^\text{T} \mathbf{S} \mathbf{z}
&= \frac{1}{n-1} \cdot \mathbf{z}^\text{T} \mathbf{Y}^\text{T} \mathbf{C} \mathbf{Y} \mathbf{z} \\[6pt]
&= \frac{1}{n-1} \cdot (\mathbf{Y} \mathbf{z})^\text{T} \mathbf{C} \mathbf{Y} \mathbf{z} \\[6pt]
&= \frac{1}{n-1} \cdot \mathbf{a}^\text{T} \mathbf{C} \mathbf{a} 
\geqslant 0. \\[6pt]
\end{align}$$
This shows that $\mathbf{S}$ is non-negative definite.  However, it is not always positive definite.  To see this, take any $\mathbf{z} \neq \mathbf{0}$ giving $\mathbf{a} = \mathbf{Y} \mathbf{z} \propto \mathbf{1}$ and substitute into the quadratic form to get $\mathbf{z}^\text{T} \mathbf{S} \mathbf{z} = 0$.

Update: This update is based on the additional information you have added in your edit to the question and your comments.  In order to get a positive definite sample variance matrix you need $\mathbf{a}^\text{T} \mathbf{C} \mathbf{a} 
> 0$.  If $n-1>p$ and all $n$ rows of $\mathbf{Y}$ are linearly independent then $\mathbf{Y} \mathbf{z} \propto \mathbf{1}$ implies $\mathbf{z} = \mathbf{0}$.  The contrapositive implication is that $\mathbf{a}^\text{T} \mathbf{C} \mathbf{a} 
> 0$ for all $\mathbf{z} \neq 0$, which establishes that the sample covariance matrix is positive definite.  Presumably this is what you are looking for.
