主要内容

Get Started with Simscape Acoustics

R2026b

Simscape™ Acoustics provides basic acoustic domain blocks for building lumped-parameter models. It includes components such as tubes and enclosures, and it can model effects such as thermal and viscous losses. It also includes models of complete electro-mechanical-acoustic sensors and transducers such as microphones, earbuds, and loudspeakers.

Introduction to the Acoustic Domain

Simscape blocks operate in one of several predefined physical domains, such as the electrical domain, thermal domain, or mechanical translational domain. Simscape defines these foundational domains and provides the Foundation Block Libraries (Simscape).

Simscape Acoustics adds the acoustic domain for blocks that model physical systems involving air pressure and velocity. Like other Simscape domains, the acoustic domain defines Across and Through variables and parameters that define the physical properties of the acoustic medium. All models must be connected to a Solver Configuration (Simscape) block. For more information on constructing physical models in Simscape, see Essential Steps for Constructing a Physical Model (Simscape).

Domain Variables and Parameters

The table shows the variables and parameters that characterize the acoustic domain.

Physical propertyUnitsSimscape roleDefinition
Acoustic pressurePaAcross variableTime-varying deviation of pressure from the ambient barometric pressure. Acoustic pressure is the primary quantity perceived as sound.
Volume velocitym3/sThrough variableVolumetric flow rate through a cross-sectional area caused by acoustic motion.
Acoustic densitykg/m3ParameterStatic density of the acoustic medium.
Speed of soundm/sParameterVelocity at which small pressure disturbances propagate through a medium.
Ambient barometric pressurePaParameterStatic atmospheric pressure that exists in the absence of acoustic disturbances.
Specific heatJ/kg/KParameterAmount of heat energy required to raise the temperature of a unit mass of a substance by one Kelvin while at constant pressure.
Ratio of specific heatsUnitlessParameterRatio of specific heat at constant pressure to specific heat at constant volume.
Viscositym2/sParameterRate at which momentum diffuses through the acoustic medium.
Thermal conductivityW/m/KParameterMeasure of the ability of the acoustic medium to conduct heat.

To view the complete domain source file, at the MATLAB® Command Window, type:

open([matlabroot '/toolbox/simscapeacoustics/+acoustic/acoustic.ssc'])
The abbreviated acoustic domain declaration is shown here, with comments omitted for readability.
domain acoustic
% Acoustic Domain

% Copyright 2025-2026 The MathWorks, Inc.

  parameters
    Rho       = { 1.21,   'kg/m^3' }; % density of acoustic medium
    c         = { 343.,   'm/s' };    % sound speed in medium
    P_ambient = { 101325.,'Pa'};      % Ambient barometric pressure
    Cp        = {1.01e3, 'J/kg/K'};   % Specific heat at constant pressure
    Gamma     = {1.4,     '1'};       % Ratio of specific heats  
    Nu        = {15.68e-6, 'm^2/s'};  % Viscosity
    Kappa     = {0.0257,  'W/m/K'};   % Thermal conductivity
  end

  variables
    p = { 0 , 'Pa' }; % Pressure
  end

  variables(Balancing = true)
    u = { 0 , 'm^3/s'}; % Volume velocity
  end

end
You can change the properties of the acoustic medium in a circuit by connecting an Acoustic Properties block to the model.

Basic Acoustic Elements

Lumped-element models of acoustic systems are often modeled analogously to electrical systems. The foundational elements of acoustic models are the acoustic compliance, inertance, and resistance. Simscape Acoustics provides blocks that model these elements. More complex blocks in the library, such as those modeling transmission lines, radiation impedances, and acoustic enclosures, are built by combining these basic elements.

Acoustic Compliance

Acoustic Compliance block icon.

The Acoustic Compliance block simulates acoustic compliance in a lumped-element model. Acoustic compliance represents the ability of the medium to be compressed when subjected to a change in acoustic pressure. Compliance in the acoustic domain is analogous to capacitance in the electrical domain.

Acoustic compliance is often used to model cavities and enclosures. A sealed cavity of air acts like a spring. When volume velocity pushes air into the cavity, the pressure increases as the air compresses. When the pressure is released, the stored energy drives the air back out.

Acoustic Inertance

Acoustic Inertance block icon.

The Acoustic Inertance block simulates acoustic inertance in a lumped-element model. Acoustic inertance represents the inertia of mass in the acoustic medium. Inertance in the acoustic domain is analogous to inductance in the electrical domain.

Acoustic inertance is often used in models of air columns or small openings. Air in an opening cannot change velocity instantaneously because of the mass of the air. Pressure must be applied to accelerate the air mass.

Acoustic Resistance

Acoustic Resistance block icon.

The Acoustic Resistance block simulates acoustic resistance in a lumped-element model. Acoustic resistance represents the conversion of acoustic energy into heat and other losses. Resistance in the acoustic domain is analogous to electrical resistance.

Acoustic resistance is often used in models of small openings and radiation impedances. When pressure moves through a narrow passage or along a boundary, viscous friction and thermal effects dissipate acoustic energy. Radiation of sound into free space can also be modeled as resistance because acoustic energy dissipates from the local system.

Connecting and Measuring Acoustic Models

Acoustic Reference

Acoustic Reference block icon.

All Simscape domains have a domain reference where the Across variable is equal to zero, analogous to an electrical ground. Simscape Acoustics includes the Acoustic Reference block for the acoustic domain. Any Simscape model with acoustic blocks must be connected to an Acoustic Reference block. Some blocks, such as the Simple Acoustic Enclosure, have an internal Acoustic Reference block and ground the acoustic system that they are connected to.

Acoustic Sensors

Pressure Sensor block icon.

When building a physical model in Simscape, it is useful to monitor the behavior of the Across and Through variables. Simscape Acoustics provides the Pressure Sensor block (analogous to an electrical voltmeter) and the Volume Velocity Sensor block (analogous to an electrical ammeter) to monitor acoustic pressure and volume velocity, respectively.

Volume Velocity Sensor block icon.

Place a Pressure Sensor block in parallel with the acoustic elements you want to measure across. Place a Volume Velocity Sensor block in series with acoustic elements you want to measure through. The sensor blocks output measurements as physical signals.

Far-field Pressure Sensor block icon.

In acoustic models, changes in pressure are often measured at a distance from the physical system. For example, you might design a loudspeaker model and want to measure the change in pressure at a fixed distance from the speaker cone. Simscape Acoustics provides the Far-Field Pressure Sensor block, which scales the acoustic pressure as a function of distance and air density for far-field monitoring of acoustic pressure.

For more information on connecting physical signals to Simulink® blocks, see Connecting Simscape Diagrams to Simulink Sources and Scopes (Simscape).

Interaction with Simscape Foundational Domains

Mechanical to Acoustic Converter block icon.

You can use Simscape Acoustics blocks to build systems that span domains. The library provides several transformer blocks, including the Mechanical to Acoustic Converter block, which converts between mechanical force and acoustic pressure. Mechanical to Acoustic Converter is used throughout Simscape Acoustics in blocks that model loudspeakers and microphones.

MEMS Speaker Electromechanical Converter block icon.

The library also provides the MEMS Speaker Electromechanical Converter block, which converts between electrical energy and mechanical energy in the form of translational motion. This block models piezoelectric transduction, commonly used in micro-electromechanical systems (MEMS) speakers and microphones.

Next Steps

For an example of a simple acoustic system built using the basic acoustic elements, see Model a Helmholtz Resonator in Simscape Acoustics.

See Also

| | | | (Simscape)

Topics