# Influence of the Quality of Consumer Headphones in the Perception of Spatial Audio
## 2 Headphones Measurements and Virtual Headphone Simulation
### Headphones Frequency Response Simulation  
The seven headphones under study were simulated to be reproduced with the reference headphones ((a)-REF-Sennheiser HD800). The simulation of each headphone was done by filtering with its frequency response, but compensating the effect of the reference headphone using its inverted frequency response. Equation (1) shows the process for the simulation, where \(H_{l}(\omega)\) is the measured response of the headphone to simulate, \(H_{HD800}(\omega)\) is the measured response of the reference headphone and \(H_{i\_corrected}(\omega)\) is the response of the simulated headphone, which is applied to the corresponding stimulus.  
\[H_{i\_corrected}(\omega)=\frac{H_{i}(\omega)}{H_{HD800}(\omega)} \tag{1}\]  
These virtual headphone equalizations include not only the magnitude response, but also the phase of the headphone measured. Although it is generally accepted that phase does not seem to affect the perceived accuracy of the simulations [12], especially if the stimuli material is a typical music program, it can be noticed with pink noise stimuli. All of the impulse responses of the headphones measured, the correction of the reference headphone and its application convolving with the stimulus, respect and keep the original phases. Moreover, accurate phase processing guaranties that our filtering will not alter in any way the Interaural Time Difference (ITD) between left and right transducers.  
Figure 2: Frequency response of the headphones used in the study. Solid curve, left channel; dashed curve, right channel. (**a**) REF, Reference headphone; (**b–h**) headphones under study. (**b**) HQop, High Quality open headphone; (**c**) MQcl, Medium Quality closed headphone; (**d**) BDso, Big Diaphrag semi-open headphone; (**e**) LCmul, Low Cost multimedia headphone; (**f**) AirL, Airline headphone; (**g**) Woh, Wireless open headphone; (**h**) LCmul2, Low Cost multimedia headphone 2.  
The filter implementation of Equation (1) was carried out in MATLAB (Matrix Laboratory, R2015a, MathWorks Inc., Natick, MA, USA, 2015) in the time domain, using Equation (2); where \(h_{i\_corrected}[n]\) is the response for the simulation of the virtual headphone, \(h_{i}[n]\) is the impulse response of the headphone to simulate and \(h_{HD800}^{I}[n]\) is the inverted impulse response of the reference headphone.  
\[h_{i\_corrected}[n]=h_{i}[n]*h_{HD800}^{I}[n] \tag{2}\]  
To obtain \(h_{HD800}^{I}[n]\), we firstly recorded the impulse response of the reference headphone \(h_{HD800}\) with 2205 sample points (50 ms, fs = 44,100 Hz). Secondly, the Fast Fourier Transform (FFT) of the response was computed, with zero padding up to a size of 4096, which guaranties a spectral resolution of 10 Hz. This is low enough to see details of the frequency response. Thirdly, the resulting FFT was inverted, taking into account a boost limitation of +15 dB. This limitation was included to avoid an excess of boost at a couple of very narrow notches of the \(h_{HD800}\) response (see Figure 2a), assuring that final signals are inside the reproducible dynamic margin and free from artifacts. Lastly, the inverted and limited response was then used to properly compute the inverse FFT and next Hamming windowed to obtain the \(h_{HD800}^{I}[n]\). This process guaranties the avoidance of undesirable effects, such as circular convolution or others.  
Finally, the different headphones were simulated applying the simulation filter \(h_{i\_corrected}[n]\) to the sound materials for each test, obtaining the different stimuli. This was the procedure used for Tests 2 (Section 4) and 4 (Section 6).