aspsim.room.directional.differential_cardioid_microphone

aspsim.room.directional.differential_cardioid_microphone(signal_main, signal_secondary, microphone_distance, filter_order, c, samplerate, filter_below=None)

Constructs a cardioid microphone response from two omnidirectional microphones

The two omnidirectional microphones must be separated by a distance of microphone_distance. The strongest response is in the direction of the main microphone from the secondary, and the null is in the opposite direction.

Parameters:
  • signal_main (ndarray of shape (num_mics, num_samples)) – the signal from the main microphone

  • signal_secondary (ndarray of shape (num_mics, num_samples)) – the signal from the secondary microphone

  • microphone_distance (float) – the distance between the microphones

  • filter_order (int) – the order of the filter. The filter will have 2*filter_order + 1 taps.

  • c (float) – the speed of sound.

  • samplerate (int) – the sampling rate of the signals.

  • filter_below (float or None) – if not None, filters out the frequencies below this frequency, given in Hertz. The differential microphone is problematic at low frequencies, and this can be used to avoid this.

Returns:

cardioid_signal – the signal from the cardioid microphone

Return type:

ndarray of shape (num_mics, num_samples)

References

[benestyStudy2013] J. Benesty and J. Chen, Study and design of differential microphone arrays, vol. 6. in Springer Topics in Signal Processing, vol. 6. Springer, 2013.