# International Audio Laboratories Erlangen

## SMIR Generator

### Abstract

A method is proposed for simulating the sound pressure signals on a spherical microphone array in a reverberant enclosure. The method employs spherical harmonic decomposition (SHD) and takes into account scattering from a solid sphere. An analysis shows that the error in the decomposition can be made arbitrarily small given a sufficient number of spherical harmonics.

1. D. P. Jarrett, E. A. P. Habets, M. R. P. Thomas and P. A. Naylor, "Rigid sphere room impulse response simulation: algorithm and applications," Journal of the Acoustical Society of America, Volume 132, Issue 3, pp. 1462-1472, 2012.
2. D. P. Jarrett, E. A. P. Habets, M. R. P. Thomas and P. A. Naylor, "Simulating room impulse responses for spherical microphone arrays," Proc. of the IEEE International Conference on Acoustics, Speech, and Signal Processing (ICASSP 2011), Prague, Czech Republic, May 22-27, 2011.
3. J.B. Allen and D.A. Berkley, "Image method for efficiently simulating small-room acoustics," Journal Acoustic Society of America, 65(4), April 1979, p 943.

### Example

procFs = 8000;                      % Sampling frequency (Hz)
c = 343;                            % Sound velocity (m/s)
nsample = 512;                      % Length of desired RIR
N_harm = 40;                        % Maximum order of harmonics to use in SHD
K = 2;                              % Oversampling factor

L = [4 6 8];                        % Room dimensions (x,y,z) in m
sphLocation = [2 3.2 4];            % Receiver location (x,y,z) in m
s = [2.37 4.05 4.4];                % Source location(s) (x,y,z) in m
beta = [1 0.7 0.7 0.5 0.2 1];       % Room reflection coefficients [\beta_x_1
% \beta_x_2 \beta_y_1 \beta_y_2 \beta_z_1 \beta_z_2]
order = -1;                         % Reflection order (-1 is maximum reflection order)

sphType = 'rigid';                  % Type of sphere (open/rigid)

mic = [pi/4 pi; pi/2 pi];           % Microphone positions (azimuth, elevation)

[h, H, beta_hat] = smir_generator(c, procFs, sphLocation, s, L, beta, sphType, sphRadius,
mic, N_harm, nsample, K, order);
Figure: Sample room impulse response and room transfer function, obtained using the above parameters

### History

 1.0.20101017 (DJ) Initial version 1.1.20111212 (DJ) Performance improvements, added C++ function function (with MEX wrapper) for most computationally complex operations, added reflection order limit 1.2.20120925 (DJ) Added truncation of time domain RIRs when oversampling (K > 1) is used 2.0.20130830 (SB) Implemented main loop in C++ Added source directivity Added angle dependent reflection coefficient 2.1.20150713 (SB) Fixed default RIR length computation

(JD) Daniel Jarrett
(SD) Sebastian Braun