All package functions

These are the functions exposed when using import aubellhop.

AUBELLHOP: Python interface for the Bellhop underwater acoustic propagation models.

This toolbox uses the Bellhop acoustic propagation model. For this model to work, the complete aubellhop package must be built and installed and bellhop.exe should be in your PATH.

Copyright (c) 2025-, Will Robertson Copyright (c) 2018-2025, Mandar Chitre

This file was originally part of arlpy, released under Simplified BSD License. It has been relicensed in this repository to be compatible with the Bellhop licence (GPL).

aubellhop.main.read_ssp(fname: str, depths: list[float] | ndarray[tuple[Any, ...], dtype[float64]] | DataFrame | None = None) ndarray[tuple[Any, ...], dtype[float64]] | DataFrame[source]

Read a 2D sound speed profile (.ssp) file used by BELLHOP.

This function reads BELLHOP’s .ssp files which contain range-dependent sound speed profiles. The file format is: - Line 1: Number of range profiles (NPROFILES) - Line 2: Range coordinates in km (space-separated) - Line 3+: Sound speed values, one line per depth point across all ranges

Parameters:

fname (str) – Path to .ssp file (with or without .ssp extension)

Returns:

For single-profile files: numpy array with [depth, soundspeed] pairs; for multi-profile files: pandas DataFrame with range-dependent sound speed data

Return type:

numpy.ndarray or pandas.DataFrame

Notes

Return format:

  • Single-profile files (1 range): Returns a 2D numpy array with [depth, soundspeed] pairs, compatible with the Environment() soundspeed parameter.

  • Multi-profile files (>1 ranges): Returns a pandas DataFrame where:

    • Columns: Range coordinates (in meters, converted from km in file)

    • Index: Depth indices (0, 1, 2, … for each depth level in the file)

    • Values: Sound speeds (m/s)

    This DataFrame can be directly assigned to the Environment() soundspeed parameter for range-dependent acoustic modeling.

Note on depths: For multi-profile files, depth indices are used (0, 1, 2, …) since the actual depth coordinates come from the associated BELLHOP .env file. Users can modify the DataFrame index if actual depth values are known.

Examples

>>> import aubellhop as bh
>>> # Single-profile file
>>> ssp1 = bh.read_ssp("single_profile.ssp")  # Returns numpy array
>>> env = bh.Environment()
>>> env["soundspeed"] = ssp1
>>>
>>> # Multi-profile file
>>> ssp2 = bh.read_ssp("tests/MunkB_geo_rot/MunkB_geo_rot.ssp")  # Returns DataFrame
>>> env = bh.Environment()
>>> env["soundspeed"] = ssp2  # Range-dependent sound speed

File format example:

30
-50 -5 -1 -.8 -.75 -.6 -.4 -.2 0 0.2 0.4 0.6 0.8 1.0 1.2 1.4 1.6 1.8 2.0 2.2 2.4 2.6 2.8 3.0 3.2 3.4 3.6 3.8 4.0 10.0
1500 1500 1548.52 1530.29 1526.69 1517.78 1509.49 1504.30 1501.38 1500.14 1500.12 1501.02 1502.57 1504.62 1507.02 1509.69 1512.55 1515.56 1518.67 1521.85 1525.10 1528.38 1531.70 1535.04 1538.39 1541.76 1545.14 1548.52 1551.91 1551.91
1500 1500 1548.52 1530.29 1526.69 1517.78 1509.49 1504.30 1501.38 1500.14 1500.12 1501.02 1502.57 1504.62 1507.02 1509.69 1512.55 1515.56 1518.67 1521.85 1525.10 1528.38 1531.70 1535.04 1538.39 1541.76 1545.14 1548.52 1551.91 1551.91
aubellhop.main.read_ssp_3d(fname: str) dict[str, ndarray][source]

Read a 3D sound speed profile (.ssp) file used by BELLHOP3D and return a 3D Numpy array.

This function reads BELLHOP’s .ssp files which contain range-dependent sound speed profiles. The file format is: - Line 1: Nx: Number of coordinates in the range (x) direction - Line 2: Range coordinates in km (space-separated) - Line 3: Ny: Number of coordinates in the crossrange (y) direction - Line 4: Crossrange coordinates in km (space-separated) - Line 5: Nz: Number of coordinates in the depth (z) direction - Line 6: Depth coordinates in km (space-separated) - Line 7+: Sound speed values, one line per crossrange and depth across all ranges

(i.e., each line has Nx number of values and there are Ny*Nz lines)

aubellhop.main.read_ati(fname: str) tuple[ndarray[tuple[Any, ...], dtype[float64]], str][source]

Read an altimetry file used by Bellhop.

aubellhop.main.read_bty(fname: str) tuple[ndarray[tuple[Any, ...], dtype[float64]], str][source]

Read a bathymetry file used by Bellhop.

aubellhop.main.read_sbp(fname: str) ndarray[tuple[Any, ...], dtype[float64]][source]

Read an source beam patterm (.sbp) file used by BELLHOP.

The file format is: - Line 1: Number of points - Line 2+: Angle (deg) and power (dB) pairs

Parameters:

fname (str) – Path to .sbp file (with or without extension)

Returns:

Numpy array with [angle, power] pairs

Return type:

numpy.ndarray

aubellhop.main.read_trc(fname: str) ndarray[tuple[Any, ...], dtype[float64]][source]

Read a TRC file and return array of reflection coefficients.

See equivalent read_brc function for documentation.

aubellhop.main.read_brc(fname: str) ndarray[tuple[Any, ...], dtype[float64]][source]

Read a BRC file and return array of reflection coefficients.

This function reads BELLHOP’s .brc files which define the reflection coefficient data. The file format is: - Line 1: Number of points - Line 2+: THETA(j) RMAG(j) RPHASE(j)

Where: - THETA(): Angle (degrees) - RMAG(): Magnitude of reflection coefficient - RPHASE(): Phase of reflection coefficient (degrees)

Parameters:

fname (str) – Path to .brc/.trc file (extension required)

Returns:

Numpy array with [theta, rmag, rphase] triplets compatible with Environment()

Return type:

numpy.ndarray

Notes

The returned array can be assigned to env[“bottom_reflection_coefficient”]. The equivalent read_trc() data would be assigned to env[“surface_reflection_coefficient”].

File format example

3
0.0   1.00  180.0
45.0  0.95  175.0
90.0  0.90  170.0

Example

>>> import aubellhop as bh
>>> import aubellhop.readers as bhr
>>> brc = bhr.read_refl_coeff("tests/MunkB_geo_rot/MunkB_geo_rot.brc")
>>> env = bh.Environment()
>>> env["bottom_reflection_coefficient"] = brc
>>> arrivals = bh.calculate_arrivals(env)
aubellhop.main.read_rays(fname: str, **kwargs) DataFrame[source]

Read Bellhop rays file and parse data into a high level data structure

aubellhop.main.read_arrivals(fname: str) DataFrame[source]

Read Bellhop arrivals file and parse data into a high level data structure

class aubellhop.main.Environment(name: str = 'bellhop/python default', _from_file: str | None = None, dimension: str = BHStrings.two_d, _dimension: int = 2, frequency: float = 25000.0, _num_media: int = 1, soundspeed: float | Any = 1500.0, soundspeed_interp: str = BHStrings.linear, _mesh_npts: int = 0, _depth_sigma: float = 0.0, _depth_max: float | None = None, _range_max: float | None = None, _bathymetry: str = BHStrings.flat, _altimetry: str = BHStrings.flat, _sbp_file: str = BHStrings.default, bottom_depth: float | Any = 25.0, bottom_interp: str = BHStrings.linear, _bottom_depth: float | None = None, bottom_soundspeed: float = 1500.0, _bottom_soundspeed_shear: float = 0.0, bottom_density: float = 1000.0, bottom_attenuation: float | None = None, _bottom_attenuation_shear: float | None = None, bottom_roughness: float = 0.0, bottom_beta: float | None = None, bottom_transition_freq: float | None = None, bottom_boundary_condition: str = BHStrings.acousto_elastic, bottom_reflection_coefficient: Any | None = None, bottom_grain_size: float | None = None, surface_depth: Any | None = None, surface_interp: str = BHStrings.linear, surface_boundary_condition: str = BHStrings.vacuum, surface_reflection_coefficient: Any | None = None, surface_soundspeed: float = 1500.0, _surface_soundspeed_shear: float = 0.0, surface_density: float = 1000.0, surface_attenuation: float | None = None, _surface_attenuation_shear: float | None = None, _surface_min: float | None = None, surface_min: float | None = None, source_type: str = BHStrings.default, source_range: float | Any = 0.0, source_cross_range: float | Any = 0.0, source_depth: float | Any = 5.0, source_ndepth: int | None = None, source_nrange: int | None = None, source_ncrossrange: int | None = None, source_directionality: Any | None = None, _source_num: int = 0, receiver_depth: float | Any = 10.0, receiver_range: float | Any = 1000.0, receiver_bearing: float | Any = 0.0, receiver_ndepth: int | None = None, receiver_nrange: int | None = None, receiver_nbearing: int | None = None, _receiver_num: int = 0, beam_type: str = BHStrings.default, beam_angle_min: float | None = None, beam_angle_max: float | None = None, beam_bearing_min: float | None = None, beam_bearing_max: float | None = None, beam_num: int = 0, beam_bearing_num: int = 0, single_beam_index: int | None = None, _single_beam: str = BHStrings.default, beam_width_type: str | None = None, beam_reflection_curvature_change: str | None = None, beam_reflection_shift: str | None = None, beam_epsilon_multipler: float | None = None, beam_range_loop: float | None = None, beam_images_num: int | None = None, beam_window: int | None = None, beam_component: str | None = None, simulation_depth: float | None = None, simulation_range: float | None = None, simulation_cross_range: float | None = None, simulation_depth_scale: float | None = None, simulation_range_scale: float | None = None, simulation_cross_range_scale: float | None = None, simulation_cross_range_min: float | None = None, step_size: float | None = 0.0, grid_type: str = BHStrings.default, task: str | None = None, interference_mode: str | None = None, volume_attenuation: str = BHStrings.none, attenuation_units: str = BHStrings.frequency_dependent, biological_layer_parameters: Any | None = None, _fg_salinity: float | None = None, _fg_temperature: float | None = None, _fg_pH: float | None = None, _fg_depth: float | None = None, comment_pad: int = 50)[source]

Dataclass for underwater acoustic environment configuration.

This class provides automatic validation of environment parameters, eliminating the need for manual checking of option validity.

These entries are either intended to be set or edited by the user, or with _ prefix are internal state read from a .env file or inferred by other data. Some others are ignored.

Parameters:

**kv (dict) – Keyword arguments for environment configuration.

Returns:

env – A new underwater environment dictionary.

Return type:

dict

Raises:

ValueError – If any parameter value is invalid according to BELLHOP constraints.

Example

To see all the parameters available and their default values:

>>> import aubellhop as bh
>>> env = bh.Environment()
>>> print(env)

The environment parameters may be changed by passing keyword arguments or modified later using dictionary notation:

>>> import aubellhop as bh
>>> env = bh.Environment(bottom_depth=40, soundspeed=1540)
>>> print(env)
>>> env.bottom_depth = 25
>>> env.bottom_soundspeed = 1800
>>> print(env)

The default environment has a constant sound speed. A depth dependent sound speed profile be provided as a Nx2 array of (depth, sound speed):

>>> import aubellhop as bh
>>> env = bh.Environment(bottom_depth=20,
>>>         soundspeed=[[0,1540], [5,1535], [10,1535], [20,1530]])

A range-and-depth dependent sound speed profile can be provided as a Pandas frame:

>>> import aubellhop as bh
>>> import pandas as pd
>>> ssp2 = pd.DataFrame({
>>>       0: [1540, 1530, 1532, 1533],     # profile at 0 m range
>>>     100: [1540, 1535, 1530, 1533],     # profile at 100 m range
>>>     200: [1530, 1520, 1522, 1525] },   # profile at 200 m range
>>>     index=[0, 10, 20, 30])             # depths of the profile entries in m
>>> env = bh.Environment(bottom_depth=20, soundspeed=ssp2)

The default environment has a constant water depth. A range dependent bathymetry can be provided as a Nx2 array of (range, water depth):

>>> import aubellhop as bh
>>> env = bh.Environment(bottom_depth=[[0,20], [300,10], [500,18], [1000,15]])
name: str = 'bellhop/python default'
_from_file: str | None = None
dimension: str = '2D'
_dimension: int = 2
frequency: float = 25000.0
_num_media: int = 1
soundspeed: float | Any = 1500.0
soundspeed_interp: str = 'linear'
_mesh_npts: int = 0
_depth_sigma: float = 0.0
_depth_max: float | None = None
_range_max: float | None = None
_bathymetry: str = 'flat'
_altimetry: str = 'flat'
_sbp_file: str = 'default'
bottom_depth: float | Any = 25.0
bottom_interp: str = 'linear'
_bottom_depth: float | None = None
bottom_soundspeed: float = 1500.0
_bottom_soundspeed_shear: float = 0.0
bottom_density: float = 1000.0
bottom_attenuation: float | None = None
_bottom_attenuation_shear: float | None = None
bottom_roughness: float = 0.0
bottom_beta: float | None = None
bottom_transition_freq: float | None = None
bottom_boundary_condition: str = 'acousto-elastic'
bottom_reflection_coefficient: Any | None = None
bottom_grain_size: float | None = None
surface_depth: Any | None = None
surface_interp: str = 'linear'
surface_boundary_condition: str = 'vacuum'
surface_reflection_coefficient: Any | None = None
surface_soundspeed: float = 1500.0
_surface_soundspeed_shear: float = 0.0
surface_density: float = 1000.0
surface_attenuation: float | None = None
_surface_attenuation_shear: float | None = None
_surface_min: float | None = None
surface_min: float | None = None
source_type: str = 'default'
source_range: float | Any = 0.0
source_cross_range: float | Any = 0.0
source_depth: float | Any = 5.0
source_ndepth: int | None = None
source_nrange: int | None = None
source_ncrossrange: int | None = None
source_directionality: Any | None = None
_source_num: int = 0
receiver_depth: float | Any = 10.0
receiver_range: float | Any = 1000.0
receiver_bearing: float | Any = 0.0
receiver_ndepth: int | None = None
receiver_nrange: int | None = None
receiver_nbearing: int | None = None
_receiver_num: int = 0
beam_type: str = 'default'
beam_angle_min: float | None = None
beam_angle_max: float | None = None
beam_bearing_min: float | None = None
beam_bearing_max: float | None = None
beam_num: int = 0
beam_bearing_num: int = 0
single_beam_index: int | None = None
_single_beam: str = 'default'
beam_width_type: str | None = None
beam_reflection_curvature_change: str | None = None
beam_reflection_shift: str | None = None
beam_epsilon_multipler: float | None = None
beam_range_loop: float | None = None
beam_images_num: int | None = None
beam_window: int | None = None
beam_component: str | None = None
simulation_depth: float | None = None
simulation_range: float | None = None
simulation_cross_range: float | None = None
simulation_depth_scale: float | None = None
simulation_range_scale: float | None = None
simulation_cross_range_scale: float | None = None
simulation_cross_range_min: float | None = None
step_size: float | None = 0.0
grid_type: str = 'default'
task: str | None = None
interference_mode: str | None = None
volume_attenuation: str = 'none'
attenuation_units: str = 'frequency dependent'
biological_layer_parameters: Any | None = None
_fg_salinity: float | None = None
_fg_temperature: float | None = None
_fg_pH: float | None = None
_fg_depth: float | None = None
comment_pad: int = 50
classmethod from_file(fname: str) Environment[source]

Create an Environment from an .env file.

classmethod from_dict(data: dict[str, Any]) Environment[source]

Create Environment from dictionary.

Unlike Environment(**data), unknown fields are ignored (with a warning message).

to_file(fname: str, task: str | None = None) str[source]

Write a complete .env file for specifying a Bellhop simulation.

This is the user-facing file writer. It infers the file basename and resolves the task from the environment unless overridden.

Parameters:
  • fname (str) – Filename or filename base for the .env file. If no extension is provided, .env is appended.

  • task (str, optional) – Task string which defines the computation to run (e.g. “rays”, “eigenrays”, “arrivals”, “coherent”, “incoherent”, “semicoherent”). If not provided, this is inferred from env.task or env.interference_mode.

Returns:

The filename base (no extension) of the written file.

Return type:

str

reset() Self[source]

Delete values for all user-facing parameters.

defaults() Self[source]

Applies default values if not already set.

to_dict() dict[str, Any][source]

Return a dictionary representation of the environment.

copy() Environment[source]

Return a shallow copy of the environment.

unwrap(*keys: str) list[Environment][source]

Return a list of Environment copies expanded over the given keys.

If multiple keys are provided, all combinations are produced. Each unwrapped Environment gets a unique .name derived from the parent name and the expanded field values.

set_fg_attenuation(salinity: float, temperature: float, pH: float, depth: float) Self[source]

Interface to set Francois-Garrison volume attenuation parameters.

check() Self[source]

Finalise environment parameters and perform assertion checks.

_finalise() Self[source]

Reviews the data within an environment and updates settings for consistency.

This function is run as the first step of .check().

_float_or_default(key: str, default: float) float[source]

Return the current value if not None, otherwise return and set a default.

_check_env_header() None[source]
_check_env_surface() None[source]
_check_env_depth() None[source]
_check_env_ssp() None[source]
_check_env_source() None[source]
_check_env_beam() None[source]
_abc_impl = <_abc._abc_data object>
class aubellhop.main.Models(*args: Any, **kwargs: Any)[source]

Registry for BellhopSimulator models.

This is a Utility Class which consists of only class methods and a global registry of defined models.

_models: list[BellhopSimulator] = [<aubellhop.bellhop.BellhopSimulator object>, <aubellhop.bellhop.BellhopSimulator object>]
classmethod init() None[source]

Create default 2D and 3D models.

classmethod reset() None[source]

Clear all models from the registry.

classmethod new(name: str, **kwargs: Any) BellhopSimulator[source]

Instantiate a new Bellhop model and add it to the registry.

Parameters:
  • name (str) – The (unique) name of the BellhopSimulator model

  • kwargs (Any) – Arguments to pass onto the BellhopSimulator constructor

Returns:

The defined model which was just added to the registry.

Return type:

BellhopSimulator

classmethod supported(env: Environment | None = None, task: str | None = None, dim: int | None = None) list[str][source]

List available models by name, maybe narrowed by env, task, and/or dimension.

classmethod get(name: str) BellhopSimulator[source]

Get a model by name.

Parameters:

name (str) – The name of the BellhopSimulator model

Returns:

The first model in the registry which matches the specified name.

Return type:

BellhopSimulator

classmethod select(env: Environment, task: str, model: str | None = None, debug: bool = False) BellhopSimulator[source]

Finds a model to use, or if a model is requested validate it.

Parameters:
  • env (dict) – The environment dictionary

  • task (str) – The task to be computed

  • model (str, optional) – Specified model to use

  • debug (bool, default=False) – Whether to print diagnostics

Returns:

The first model in the list which satisfies the input parameters.

Return type:

BellhopSimulator

aubellhop.main.compute_from_file(model: str, fname: str, debug: bool = False) dict[str, Any][source]

Compute Bellhop model directly from existing .env file.

Parameters:
  • model (str) – Name of model to run that has been defined in the Models registry.

  • fname (str) – Filename of environment file (with or w/o extension).

  • debug (bool) – Whether to print diagnostics to the console.

Returns:

results – Dictionary of metadata and results.

Return type:

dict

Notes

The environment file is parsed simply to read the specified task; the bellhop executable is run on the original file “in place” in the filesystem. A copy of the parsed environment file is stored in the metadata.

aubellhop.main.compute(env: Environment | list[Environment], model: Any | None = None, task: Any | None = None, debug: bool = False, fname_base: str | None = None, overwrite: bool = False) dict[str, Any] | tuple[list[dict[str, Any]], DataFrame][source]

Compute Bellhop task(s) for given model(s) and environment(s).

Parameters:
  • env (dict or list of dict) – Environment definition (which includes the task specification)

  • model (str, optional) – Propagation model to use (None to auto-select)

  • task (str or list of str, optional) – Optional task or list of tasks (“arrivals”, etc.)

  • debug (bool, default=False) – Generate debug information for propagation model

  • fname_base (str, optional) – Base file name for Bellhop working files, default (None), creates a temporary file

  • overwrite (bool, default=False) – If True, remove any existing working/output files that share the same fname_base.

Returns:

  • dict – Single run result (and associated metadata) if only one computation is performed.

  • tuple of (list of dict, pandas.DataFrame) – List of results and an index DataFrame if multiple computations are performed.

Notes

If any of env, model, and/or task are lists then multiple runs are performed with a list of dictionary outputs returned. The ordering is based on loop iteration but might not be deterministic; use the index DataFrame to extract and filter the output logically.

Examples

Single task based on reading a complete .env file: >>> import aubellhop as bh >>> env = bh.Environment.from_file(”…”) >>> output = bh.compute(env) >>> assert output[‘task’] == “arrivals” >>> bh.plot_arrivals(output[‘results’])

Multiple tasks: >>> import aubellhop as bh >>> env = bh.Environment() >>> output, ind_df = bh.compute(env,task=[“arrivals”, “eigenrays”]) >>> bh.plot_arrivals(output[0][‘results’])

aubellhop.main.compute_rays(env: Environment, source_depth_ndx: int = 0, model: Any | None = None, debug: bool = False, fname_base: str | None = None, overwrite: bool = False) Any[source]

Compute rays from a given transmitter.

Parameters:
  • env (dict) – Environment definition

  • source_depth_ndx (int, default=0) – Transmitter depth index

  • model (str, optional) – Propagation model to use (None to auto-select)

  • debug (bool, default=False) – Generate debug information for propagation model

  • fname_base (str, optional) – Base file name for Bellhop working files, default (None), creates a temporary file

  • overwrite (bool, default=False) – If True, remove any existing working/output files that share the same fname_base.

Returns:

Ray paths

Return type:

pandas.DataFrame

Examples

>>> import aubellhop as bh
>>> env = bh.Environment()
>>> rays = bh.compute_rays(env)
>>> bh.plot_rays(rays, width=1000)
aubellhop.main.compute_eigenrays(env: Environment, source_depth_ndx: int = 0, receiver_depth_ndx: int = 0, receiver_range_ndx: int = 0, model: Any | None = None, debug: bool = False, fname_base: str | None = None, overwrite: bool = False) Any[source]

Compute eigenrays between a given transmitter and receiver.

Parameters:
  • env (dict) – Environment definition

  • source_depth_ndx (int, default=0) – Transmitter depth index

  • receiver_depth_ndx (int, default=0) – Receiver depth index

  • receiver_range_ndx (int, default=0) – Receiver range index

  • model (str, optional) – Propagation model to use (None to auto-select)

  • debug (bool, default=False) – Generate debug information for propagation model

  • fname_base (str, optional) – Base file name for Bellhop working files, default (None), creates a temporary file

  • overwrite (bool, default=False) – If True, remove any existing working/output files that share the same fname_base.

Returns:

Eigenrays paths

Return type:

pandas.DataFrame

Examples

>>> import aubellhop as bh
>>> env = bh.Environment()
>>> rays = bh.compute_eigenrays(env)
>>> bh.plot_rays(rays, width=1000)
aubellhop.main.compute_arrivals(env: Environment, model: Any | None = None, debug: bool = False, fname_base: str | None = None, overwrite: bool = False) Any[source]

Compute arrivals between each transmitter and receiver.

Parameters:
  • env (dict) – Environment definition

  • model (str, optional) – Propagation model to use (None to auto-select)

  • debug (bool, default=False) – Generate debug information for propagation model

  • fname_base (str, optional) – Base file name for Bellhop working files, default (None), creates a temporary file

  • overwrite (bool, default=False) – If True, remove any existing working/output files that share the same fname_base.

Returns:

Arrival times and coefficients for all transmitter-receiver combinations

Return type:

pandas.DataFrame

Examples

>>> import aubellhop as bh
>>> env = bh.Environment()
>>> arrivals = bh.compute_arrivals(env)
>>> bh.plot_arrivals(arrivals)
aubellhop.main.compute_transmission_loss(env: Environment, source_depth_ndx: int = 0, mode: str | None = None, model: Any | None = None, debug: bool = False, fname_base: str | None = None, overwrite: bool = False) Any[source]

Compute transmission loss from a given transmitter to all receviers.

Parameters:
  • env (dict) – Environment definition

  • source_depth_ndx (int, default=0) – Transmitter depth index

  • mode (str, optional) – Coherent, incoherent or semicoherent

  • model (str, optional) – Propagation model to use (None to auto-select)

  • debug (bool, default=False) – Generate debug information for propagation model

  • fname_base (str, optional) – Base file name for Bellhop working files, default (None), creates a temporary file

  • overwrite (bool, default=False) – If True, remove any existing working/output files that share the same fname_base.

Returns:

Complex transmission loss at each receiver depth and range

Return type:

numpy.ndarray

Examples

>>> import aubellhop as bh
>>> env = bh.Environment()
>>> tloss = bh.compute_transmission_loss(env, mode="incoherent")
>>> bh.plot_transmission_loss(tloss, width=1000)
aubellhop.main.arrivals_to_impulse_response(arrivals: Any, fs: float, abs_time: bool = False) Any[source]

Convert arrival times and coefficients to an impulse response.

Parameters:
  • arrivals (pandas.DataFrame) – Arrivals times (s) and coefficients

  • fs (float) – Sampling rate (Hz)

  • abs_time (bool, default=False) – Absolute time (True) or relative time (False)

Returns:

Impulse response

Return type:

numpy.ndarray

Notes

If abs_time is set to True, the impulse response is placed such that the zero time corresponds to the time of transmission of signal.

Examples

>>> import aubellhop as bh
>>> env = bh.Environment()
>>> arrivals = bh.compute_arrivals(env)
>>> ir = bh.arrivals_to_impulse_response(arrivals, fs=192000)
aubellhop.main.demo() DataFrame[source]

Run a simple bellhop demonstration and write demo file.

This function: 1. Creates a simple underwater acoustic environment with default settings 2. Computes acoustic ray arrivals using bellhop 3. Prints a summary of the arrival results to the console 4. Writes a standalone bellhop_demo.py file to the current directory

Returns:

results – DataFrame containing the computed arrival results

Return type:

pandas.DataFrame

Example

>>> import aubellhop
>>> bellhop.demo()