Room Acoustics Module
The room acoustics module contains several functions to calculate the reverberation time in spaces.
Functions
mean_alpha
Calculate mean of absorption coefficients.
| PARAMETER | DESCRIPTION |
|---|---|
alphas
|
Absorption coefficients \(\alpha\).
|
surfaces
|
Surfaces \(S\).
|
| RETURNS | DESCRIPTION |
|---|---|
|
Mean absorption coefficient \(\alpha_{m}\). |
Source code in acoustic_toolbox/room.py
nrc
Calculate Noise Reduction Coefficient (NRC) from four absorption coefficient values (250, 500, 1000 and 2000 Hz).
| PARAMETER | DESCRIPTION |
|---|---|
alphas
|
Absorption coefficients \(\alpha\).
|
| RETURNS | DESCRIPTION |
|---|---|
|
NRC |
Source code in acoustic_toolbox/room.py
t60_sabine
t60_sabine(
surfaces: NDArray[float64],
alpha: NDArray[float64],
volume: float,
c: float = SOUNDSPEED,
)
Reverberation time according to Sabine.
Sabine's formula for the reverberation time is: $$ T_{60} = \frac{24 \ln(10)}{c} \frac{V}{S\alpha} $$
| PARAMETER | DESCRIPTION |
|---|---|
surfaces
|
Surface of the room \(S\). NumPy array that contains different surfaces. |
alpha
|
Absorption coefficient of the room \(\alpha\).
Contains absorption coefficients of |
volume
|
Volume of the room \(V\).
TYPE:
|
c
|
Speed of sound \(c\).
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
|
Reverberation time \(T_{60}\) |
Source code in acoustic_toolbox/room.py
t60_eyring
t60_eyring(
surfaces: NDArray[float64],
alpha: NDArray[float64],
volume: float,
c: float = SOUNDSPEED,
)
Reverberation time according to Eyring.
Eyring's formula for the reverberation time is: $$ T_{60} = \frac{24 \ln{10} V}{c \left( 4 mV - S \ln{\left( 1 - \alpha \right)} \right)} $$
| PARAMETER | DESCRIPTION |
|---|---|
surfaces
|
Surfaces \(S\). |
alpha
|
Mean absorption coefficient \(\alpha\) or by frequency bands |
volume
|
Volume of the room \(V\).
TYPE:
|
c
|
Speed of sound \(c\).
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
|
Reverberation time \(T_{60}\) |
Source code in acoustic_toolbox/room.py
t60_millington
t60_millington(
surfaces: NDArray[float64],
alpha: NDArray[float64],
volume: float,
c: float = SOUNDSPEED,
)
Reverberation time according to Millington.
| PARAMETER | DESCRIPTION |
|---|---|
surfaces
|
Surfaces \(S\). |
alpha
|
Mean absorption coefficient \(\alpha\) or by frequency bands |
volume
|
Volume of the room \(V\).
TYPE:
|
c
|
Speed of sound \(c\).
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
|
Reverberation time \(T_{60}\) |
Source code in acoustic_toolbox/room.py
t60_fitzroy
t60_fitzroy(
surfaces: NDArray[float64],
alpha: NDArray[float64],
volume: float,
c: float = SOUNDSPEED,
)
Reverberation time according to Fitzroy.
| PARAMETER | DESCRIPTION |
|---|---|
surfaces
|
Surfaces \(S\). |
alpha
|
Mean absorption coefficient \(\alpha\) or by frequency bands |
volume
|
Volume of the room \(V\).
TYPE:
|
c
|
Speed of sound \(c\).
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
|
Reverberation time \(T_{60}\) |
Source code in acoustic_toolbox/room.py
t60_arau
t60_arau(
Sx: float,
Sy: float,
Sz: float,
alpha: tuple[float, float, float],
volume: float,
c: float = SOUNDSPEED,
)
Reverberation time according to Arau.
For more details, please see http://www.arauacustica.com/files/publicaciones/pdf_esp_7.pdf
| PARAMETER | DESCRIPTION |
|---|---|
Sx
|
Total surface perpendicular to x-axis (yz-plane) \(S_{x}\).
TYPE:
|
Sy
|
Total surface perpendicular to y-axis (xz-plane) \(S_{y}\).
TYPE:
|
Sz
|
Total surface perpendicular to z-axis (xy-plane) \(S_{z}\).
TYPE:
|
alpha
|
Absorption coefficients \(\mathbf{\alpha} = \left[ \alpha_x, \alpha_y, \alpha_z \right]\) |
volume
|
Volume of the room \(V\).
TYPE:
|
c
|
Speed of sound \(c\).
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
|
Reverberation time \(T_{60}\) |
Source code in acoustic_toolbox/room.py
t60_impulse
Reverberation time from a WAV impulse response.
| PARAMETER | DESCRIPTION |
|---|---|
file_name
|
name of the WAV file containing the impulse response.
TYPE:
|
bands
|
Octave or third bands as NumPy array. |
rt
|
Reverberation time estimator. It accepts
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
NDArray[float64]
|
Reverberation time \(T_{60}\) |
Source code in acoustic_toolbox/room.py
clarity
Clarity \(C_i\) determined from an impulse response.
| PARAMETER | DESCRIPTION |
|---|---|
time
|
Time in miliseconds (e.g.: 50, 80).
TYPE:
|
signal
|
Impulse response.
|
fs
|
Sample frequency.
TYPE:
|
bands
|
Bands of calculation (optional). Only support standard octave and third-octave bands. |
| RETURNS | DESCRIPTION |
|---|---|
NDArray[float64]
|
Clarity \(C_i\) |
Source code in acoustic_toolbox/room.py
c50_from_file
Clarity for 50 miliseconds \(C_{50}\) from a file.
| PARAMETER | DESCRIPTION |
|---|---|
file_name
|
File name (only WAV is supported).
TYPE:
|
bands
|
Bands of calculation (optional). Only support standard octave and third-octave bands. |
| RETURNS | DESCRIPTION |
|---|---|
NDArray[float64]
|
Clarity \(C_{50}\) |
Source code in acoustic_toolbox/room.py
c80_from_file
Clarity for 80 miliseconds \(C_{80}\) from a file.
| PARAMETER | DESCRIPTION |
|---|---|
file_name
|
File name (only WAV is supported).
TYPE:
|
bands
|
Bands of calculation (optional). Only support standard octave and third-octave bands.
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
|
Clarity \(C_{80}\) |
Source code in acoustic_toolbox/room.py
:::