An octave is a 2:1 ratio between frequencies, so 880 hz is one octave above 440 hz. A perfect fifth is a 3:2 ratio between frequencies, so 660 hz is a perfect fifth above 440.
In the modern western system of music, twelve perfect fifths is harmonically equal to seven octaves. In other words,
(2/1)7 == (3/2)12
Unfortunately, we know this is mathematically untrue.
Furthermore, three major thirds is harmonically equal to one octave:
(2/1) == (5/4)3
This also is mathematically untrue.
Regardless of what key the song is in, a certain interval is always the same exact ratio. A major third in the key of F is the same as a major third in the key of Bb. This is good for instruments like the guitar and piano, which aren't made or tuned for a single immovable key. Contrast that with harmonicas, for examples, each of which is made for only a certain key.
Therefore the first comparison should be 7 octaves which is (2/1)^7 = 128, versus 12 perfect fifths which is (3/2)^12 = 531441/4096 = 129+3057/4096 = 129.746337890625.
Similarly for thirds, you're comparing one octave (2/1) = 1 with 3 thirds (5/4)^3 = 125/128 = 1.953125.
As you can see, the ratios are close, but not quite right. Hence the problem.
Someday HTML will support TeX and we'll never have this problem again. ;)