array_wah

MATLAB tool for evaluating microphone array configurations via 3D localisation metrics. Generates error heatmaps and statistical insights to guide array design in acoustic research.

https://github.com/raviumadi/array_wah

Science Score: 67.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
    Found 13 DOI reference(s) in README
  • Academic publication links
    Links to: biorxiv.org, zenodo.org
  • Committers with academic emails
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (11.0%) to scientific vocabulary

Keywords

bat-call-localisation bioacoustics echolocation field-experiments matlab microphone-array tdoa
Last synced: 6 months ago · JSON representation ·

Repository

MATLAB tool for evaluating microphone array configurations via 3D localisation metrics. Generates error heatmaps and statistical insights to guide array design in acoustic research.

Basic Info
  • Host: GitHub
  • Owner: raviumadi
  • License: other
  • Language: MATLAB
  • Default Branch: main
  • Homepage:
  • Size: 3.01 MB
Statistics
  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • Open Issues: 0
  • Releases: 1
Topics
bat-call-localisation bioacoustics echolocation field-experiments matlab microphone-array tdoa
Created 9 months ago · Last pushed 8 months ago
Metadata Files
Readme License Citation

README.md

Array WAH: Widefield Acoustics Heuristic for 3D Localisation of Bat Calls

Author: Ravi Umadi Affiliation: Technical University of Munich License: CC BY-NC-SA 4.0

DOI

Cite This Toolkit

This toolkit was developed for the manuscript:
Widefield Acoustics Heuristic: Advancing Microphone Array Design for Accurate Spatial Tracking of Echolocating Bats
Preprint: https://doi.org/10.1101/2025.06.03.657701

If you use this toolkit, please also cite:

Ravi Umadi. (2025). raviumadi/Array_WAH: First Release (V1.0.0). Zenodo.
https://doi.org/10.5281/zenodo.15691372


Overview

Array WAH is a MATLAB-based simulation and analysis toolkit designed for designing, simulating, and benchmarking 3D microphone array geometries for precise acoustic localisation of ultrasonic bat calls.

It supports:

  • Virtual bat call simulation
  • Frequency-dependent propagation
  • Time Difference of Arrival (TDOA) multilateration
  • 3D grid sweep error mapping
  • Statistical and visual analyses of localisation performance

The toolkit supports multiple array geometries, including:

  • Tetrahedron
  • Planar Square
  • Pyramid
  • Octahedron
  • Custom Geometry

Theory and Approach

Array WAH models the entire localisation chain:

1. Call Generation

Simulated bat calls are generated using two biologically relevant signal types:

• Frequency-Modulated (FM) Sweeps

FM calls are created as quadratic down-sweeps from a starting frequency f0 to an ending frequency f1 over a duration d. These mimic broadband echolocation signals produced by many insectivorous bats.

Key features:

  • Quadratic chirp generation using MATLAB’s chirp() function.
  • Hanning window applied to taper onset and offset, minimising spectral leakage.
  • A spectral shaping filter (optional) is included in the code for more naturalistic bandwidth control.
  • An optional Doppler shift is applied by resampling the chirp to simulate relative motion between the bat and the microphone.
  • Zero-padding is added before and after the signal based on a user-specified tail percentage of the call duration.

• Constant-Frequency (CF) Calls

CF calls are generated as pure tones at a single frequency f1 over the duration d, typically used to simulate calls of species like horseshoe bats (Rhinolophus) or Hipposideros.

Features:

  • Sinusoidal tone generation at a fixed frequency f1.
  • Hanning window applied to prevent sharp transitions.
  • Doppler resampling is supported for simulating motion.
  • Zero-padding is added on both sides as with FM calls.

• Doppler Shift Support

Both FM and CF calls optionally include a Doppler-induced time scaling, simulating the compression or dilation of the waveform due to relative radial motion between the emitter and the microphones. This is controlled via the velocity parameter.

2. Signal Propagation

Signals experience frequency-dependent atmospheric attenuation and geometric spreading. Delays are applied using fractional delay filters.

3. Microphone Reception

Each mic receives a scaled and delayed version of the original call, according to its distance and orientation relative to the source.

4. TDoA Estimation

Cross-correlation is used to estimate relative time delays between each mic and a reference.

5. Localisation (Multilateration)

Using the TDoA vector, nonlinear least squares is used to estimate the 3D source position via multilateration.

6. Grid Sweep & Error Mapping

The process is repeated over a 3D grid of source locations. Positional and angular errors are computed and saved.

7. Analysis and Visualisation

  • 3D scatter plots
  • Histograms and boxplots
  • Contour maps across elevation slices
  • Statistics

Folder Structure

Array_WAH/ │ ├── src/ # All class definitions │ ├──wah_analyzer.m │ ├──mic_array_configurator.m │ ├──BatCallLocaliser.m │ ├── configs/ # Saved mic array configurations (auto-generated) ├── results/ # Output CSVs and figures │ └── figures/ │ ├── simulate_batcall_localisation.m # Simulates calls and saves localisation results ├── demo_wah_analyzer.m # Loads CSVs and performs statistical analysis ├── demo_mic_array_configurator.m # Demo for mic_array_configurator ├── demo_test_single_point.m # Run a single point analysis for test mic configration and source location ├── effect_of_source_motion.m # Demonstrates source velocity effect on localisation accuracy of two call types. ├── startup.m # Adds src/ to path and checks dependencies ├── LICENSE └── README.md


Quickstart

1. Initialise

matlab run startup.m

This script:

  • Adds src/ to path
  • Verifies required toolboxes

2. Simulate Localisation Data

matlab run simulate_batcall_localisation.m

Generates TDOA-based localisation results over a 3D grid for each array config.

3. Run Analysis

matlab run demo_wah_analyzer.m

Loads results and:

  • Separates inliers/outliers
  • Generates visualisations
  • Performs ANOVA and Tukey tests

4. Visualise and Export Microphone Arrays

matlab run demo_mic_array_configurator.m


Test Run a Single Point

matlab run demo_test_single_point.m


📦 Dependencies

| Toolbox | Required | | --------------------------------------- | ------------------------------- | | Signal Processing Toolbox | ✅ | | Statistics and Machine Learning Toolbox | ✅ | | Curve Fitting Toolbox | ⚠️ Optional (for fitting trends) |

If any are missing, install via:

matlab matlab.addons.install('toolboxName.mltbx')


License

This project is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 license (CC BY-NC-SA 4.0).

✔️ Free to use and modify
❌ No commercial use
📝 Please attribute: "Ravi Umadi, Array WAH (2025)"


Acknowledgements

This project is part of my ongoing research and technological development into field-deployable, portable MCU-based multichannel microphone arrays. I thank my supervisor and colleagues at the Lehrstuhl für Zoologie at Weihenstephan.

Related Work

  • My work on BATSY4-Pro, codebase https://github.com/raviumadi/Embedded_Ultrasonics
  • The preprint of BATSY4-Pro Multichannel Ultrasound Field Recorder is now available at : 10.1101/2025.08.11.669530

Bug Reports / Feature Requests

Please open an issue or pull request on GitHub.

Owner

  • Name: Ravi Umadi
  • Login: raviumadi
  • Kind: user
  • Location: Munich

I work with sounds, signals and sense of echolocation.

Citation (CITATION.cff)

cff-version: 1.2.0
message: "If you use this toolkit, please cite it as below."
title: "Array_WAH: Widefield Acoustics Heuristic Toolkit"
version: "1.1.0"
doi: 10.5281/zenodo.15691371
date-released: 2025-08-21
authors:
  - family-names: Umadi
    given-names: Ravi
    orcid: https://orcid.org/0000-0003-3867-1769
repository-code: https://github.com/raviumadi/Array_WAH
license: Creative Commons Attribution-NonCommercial-ShareAlike 4.0
abstract: >
  This toolkit was developed for the manuscript:
  'Widefield Acoustics Heuristic: Advancing Microphone Array Design for Accurate Spatial Tracking of Echolocating Bats'.
  The preprint is available at https://doi.org/10.1101/2025.06.03.657701

GitHub Events

Total
  • Release event: 1
  • Push event: 7
  • Create event: 2
Last Year
  • Release event: 1
  • Push event: 7
  • Create event: 2

Committers

Last synced: 8 months ago

All Time
  • Total Commits: 14
  • Total Committers: 1
  • Avg Commits per committer: 14.0
  • Development Distribution Score (DDS): 0.0
Past Year
  • Commits: 14
  • Committers: 1
  • Avg Commits per committer: 14.0
  • Development Distribution Score (DDS): 0.0
Top Committers
Name Email Commits
ravisumadi 1****i 14

Issues and Pull Requests

Last synced: 6 months ago