Cosine Similarity but with weighting for vector indexes
Cosine similarity won't work very well because it's only based on whether the rank at position $i$ is the same in vector 1 and vector 2.
For instance the vectors [3,2,4,1,5] vs [2,3,5,1,4] will have very low similarity because 4 positions out of 5 are different, even though there are only two swaps between (2,3) and (4,5).
A much better way to measure the similarity between two rankings is Spearman Rank Correlation.
Note that (if I'm not mistaken) in this case you could also directly use Pearson correlation, since the numeric values are already ranks. Spearman just ranks the values before applying Pearson correlation. So normally the two will give you the same result.
Note also that this method won't give more weight to the top of the ranking than the bottom. I'm not aware of a measure which does this, other than defining a custom weighted measure.