Cosine Similarity Measure implemented with document weights