Stretched and compressed tuning

Tunings do not necessarily need equaves to be tuned to their exact ratios, and in some cases, equaves (most often octaves) are best stretched or compressed. In stretched tuning, two notes an equivalence apart, whose fundamental frequencies theoretically have an exact ratio, are tuned slightly farther apart (a stretched equivalence). In compressed tuning, also known as narrowed tuning, two notes an equivalence apart, whose fundamental frequencies theoretically have an exact ratio, are tuned slightly closer together (a compressed or narrowed equivalence).
The most common goal of stretching or compressing the octave is to improve the intonation of some intervals, such as harmonics, without sacrificing the melodic shape or harmonic structure of the tuning system. For example, 19edo approximates ratios of 3, 5, 7, and 13 well, but tunes all of these harmonics flat, so it benefits from octave stretching. 27edo approximates ratios of 3, 5, 7, and 13 well, but tunes these harmonics sharp, so it benefits from octave compression.
Inharmonicity compensation for string instruments
In general, stretched tunings detune intervals in the same way as compressed tunings do, so for instance a 5 ¢ compressed octave should sound as out-of-tune as a 5 ¢ stretched octave. On mechanoacoustic instruments, in particular string instruments, that is not true, as the overtones of the strings tend slighly sharp from their ideal natural harmonics and do not exactly line up with the harmonic series (especially on spinet pianos with their rather short strings). Because the octave is the most significant partial on the strings, by stretching the octaves we can better match our tuning systems with the timbre.
The significance of the match is a point of debate. For some, the match but shifts the problem from the timbre to the tuning systems, so no stretch or less stretch than the timbre will be alright. However, with compressed-octave tunings, the discrepancy between our compressed octave and the timbre octave will be larger. For that reason, compressed-octave tunings tend to sound more out of tune, with some going so far to say that octave compression should be avoided no matter what other reasons there may be going for them.