[ http://issues.apache.org/jira/browse/LUCENE-706?page=comments#action_12446948 ] Grant Ingersoll commented on LUCENE-706: ----------------------------------------
Just to double check the math: >From the Website: "DocDelta determines both the document number and the frequency. In particular, DocDelta/2 is the difference between this document number and the previous document number (or zero when this is the first document in a TermFreqs). When DocDelta is odd, the frequency is one. When DocDelta is even, the frequency is read as another VInt." So, 15 is the correct start since 15 /2 as an int is 7 and the frequency is one. Then the difference between doc 7 and 11 is 4, so the next value should be 8 (since DocDelta/2 = 11 - 7, which is even, meaning the frequency is the next VInt, in this case 3, so I would concur. > Index File Format - Example for frequency file .frq is wrong > ------------------------------------------------------------ > > Key: LUCENE-706 > URL: http://issues.apache.org/jira/browse/LUCENE-706 > Project: Lucene - Java > Issue Type: Improvement > Components: Website > Environment: not applicable > Reporter: Doron Cohen > Assigned To: Doron Cohen > Priority: Trivial > Attachments: file-format-frq-example.patch > > > Reported by Johan Stuyts - > http://www.nabble.com/Possible-documentation-error--p7012445.html - > Frequency file example says: > For example, the TermFreqs for a term which occurs once in document > seven and three times in document eleven would be the following sequence of > VInts: > 15, 22, 3 > It should be: > For example, the TermFreqs for a term which occurs once in document > seven and three times in document eleven would be the following sequence of > VInts: > 15, 8, 3 -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]