computing the quartet distance between general trees
computing the quartet distance between general trees
computing the quartet distance between general trees
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
7.1. THE ALGORITHM 43choice of indices.jnlimkFigure 7.6: Illustrates <strong>the</strong> choice of entries in Eq. (7.7).Once again, each possible pair of directed edges needs processing. And once again,since a regular undirected butterfly <strong>quartet</strong> is subject of two claims, each <strong>quartet</strong> is encounteredboth when dealing with e and when dealing with ē. Again, ē is some oppositelydirected edge, namely <strong>the</strong> one that claims <strong>the</strong> same <strong>quartet</strong> as e.The total result of counting different butterflies should be divided by four, as opposedto <strong>the</strong> shared butterflies. While similarity is identified by observing <strong>the</strong> same two leavesbehind <strong>the</strong> edge in both T and T ′ , difference is identified by requiring that <strong>the</strong> pairsof leaves behind <strong>the</strong> edges should be different. The consequence is, that if <strong>the</strong> edge pair(e,e ′ ) is identifying a different butterfly <strong>quartet</strong>, <strong>the</strong> pair (e,ē ′ ) does also and so does (ē,e ′ )and (ē,ē ′ ). Thus, one single <strong>quartet</strong> is counted as different four times and consequently<strong>the</strong> result should be divided by four.Contribution 7.2 It is evident that <strong>the</strong> use of directed edge claiming introduces <strong>the</strong> needfor dividing <strong>the</strong> total count by some factor. However, <strong>the</strong> article states that different butterfliesare counted twice, just like shared butterflies, and that <strong>the</strong> result should <strong>the</strong>reforebe divided by two.After implementing <strong>the</strong> diff B (T,T ′ ) algorithm I observed that <strong>the</strong> result was, “forsome reason”, consistently double of what I expected. After thorough verification thatmy implementation was correct, this led to fur<strong>the</strong>r investigations of <strong>the</strong> correctness of <strong>the</strong>article. I realized that <strong>the</strong> reasoning should be different and that <strong>the</strong> result should bedivided by four, as explained in <strong>the</strong> text.