On the dependency between principal components: Application to determine the rank of a matrix in an evolutionary process