code: public double score(int termFreq, int docLen, double avgDocLen, int titleTermFreq, int titleLen, double avgTitleLen, int anchorTermFreq, int anchorLen, double avgAnchorLen, long N, long n) {
          if (termFreq <= 0) return 0.0;
  
          double tf = wBody * termFreq / (1.0 + bBody * (docLen / avgDocLen - 1.0));
          
          if (titleTermFreq > 0) {
          	tf += wTitle * titleTermFreq / (1.0 + bTitle * (titleLen / avgTitleLen - 1.0));
          }
          
          if (anchorTermFreq > 0) {
          	tf += wAnchor * anchorTermFreq / (1.0 + bAnchor * (anchorLen / avgAnchorLen - 1.0));
          }
          
          tf = tf / (kf + tf);
          double idf = Math.log((N - n + 0.5) / (n + 0.5));
  
          return (tf + delta) * idf;
      }
docs: Returns a relevance score between a term and a document based on a corpus.
  @param termFreq normalized term frequency of searching term in the document to rank.
  @param N the number of documents in the corpus.
  @param n the number of documents containing the given term in the corpus;