math_audio_bem/core/
constants.rs

1//! Physical and integration constants
2//!
3//! This module provides physical constants and re-exports PhysicsParams.
4
5pub use super::types::PhysicsParams;
6
7use std::f64::consts::PI;
8
9/// Pi (3.14159...)
10pub const PI_CONST: f64 = PI;
11
12/// 4π
13pub const PI4: f64 = 4.0 * PI;
14
15/// 2π
16pub const PI2: f64 = 2.0 * PI;
17
18/// Number of spatial dimensions
19pub const NDIM: usize = 3;
20
21/// Maximum nodes per element
22pub const NNODPE: usize = 4;
23
24/// Small epsilon for numerical comparisons
25pub const EPSY: f64 = 1.0e-14;
26
27/// Default speed of sound in air (m/s) at 20°C
28pub const DEFAULT_SPEED_OF_SOUND: f64 = 343.0;
29
30/// Default air density (kg/m³) at 20°C
31pub const DEFAULT_DENSITY: f64 = 1.21;
32
33/// Maximum number of subelements for singular integration
34pub const MSBE: usize = 220;