What’s that Sound?

Overview

  • From consumer products to automobiles, understanding the sounds the components produce is vital. How do we uncover their nature? Enter modal simulation! It helps us explore natural vibration frequencies, which translate into the sounds we hear when these components vibrate.
  • Here is the twist: Impacting these components at different spots generates unique sounds because it excites varying vibration modes.
  • In this blog, we show how you can easily simulate the vibration of components and convert them into sound profiles using Intact.Simulation for Rhino Grasshopper.
  • Download the workflow and try it out for yourself!

Case Study

Prybar Vibration

The first action in home remodeling projects is demolition by way of hammer and prybar.  Without hearing protection, the resonant clang of the prybar after the hammer’s impact can be deafening.  But what is the nature of this sound?  Modal simulation can give us some insight.

Free-free modal simulation computes the natural vibration frequencies of a shape in the absence of restraints.  When these frequencies are in the audio range, they correlate with the sound we hear when the shape’s vibratory motion is coupled to the surrounding air (and carried to the ear).  Using an accurate geometric model of the shape and a good representation of the material properties we can approximate the sound output following an impact at different locations.

Figure 1 shows a CAD model for a fairly common prybar used for light demolition tasks.  The bar is shaped such that it may be struck at a range of locations; among the most common: perpendicular to the bar at the heel to drive the claw under the head of a nail, lengthwise along the bar at the heel to drive the head under a nail, or perpendicular to the bar at the neck to assist nail pulling.  Impact at any of these locations will excite vibrations in the bar and thus drive sound into the ear.

Figure 1: CAD Model of a hardened steel prybar and expected impact locations.
Figure 2: Mode shape for the first non-rigid mode of vibration.  Frequency: 209.5 Hz.  Annotations describe how impact at different locations affects the contribution from a given frequency component.

Does the bar sound the same irrespective of impact location?  Typically, no.  The vibration modes with anti-nodes close to the impact location will be relatively more excited, while vibration modes with nodes close to impact will be relatively unexcited.  The final sound will be a mix of the natural frequencies with the amplitude of each frequency component determined by the impact location.  This is illustrated in Figure 2.

Modal Simulation Using Intact.Simulation

Using Intact.Simulation for Grasshopper we can perform modal simulation to determine the natural frequencies of vibration.  The first 9 non-rigid modes are shown in Figure 3. Based on these frequencies, we can create .wav files that approximate the sound of impacting the bar at different locations. The amplitude of each frequency component is determined by using an Intact.Simulation sampling block to query the mode shape’s normalized displacement at a point on the bar where impact occurs, see Figure 4.  Obviously, this approach ignores the damping effect of grasping the bar, the coupling among the different modes, the damping properties of the material, and a slew of other effects, but the end result does contain the essential components of the sound heard after impact.

Figure 3: Mode shapes 7-15 for non-rigid vibration modes.  Frequencies: 209.5 Hz, 502.3 Hz, 658.5 Hz, 816.1 Hz, 1165.6 Hz, 1332.4 Hz, 1777.4 Hz, 1814 Hz, 2208.8 Hz.  Note that all modes have anti-nodes at the head of the bar.  Slipping off the head of a nail during extraction will excite all of the modes of vibration.
Figure 4: Inset of Grasshopper network showing modal simulation setup and sampling mode displacement fields at a point on the boundary.

Converting Vibration into Sound with Custom Script in Rhino Grasshopper

Modal simulation alone gives the mode shapes and frequencies. We need to convert this information into a sequence of numbers that represent samples of the resulting audio signal in the form of a .wav file. Figure 5 contains a screenshot of the C# script used to create the .wav file.  After a series of preliminary steps to set up the .wav header, the modal frequencies from simulation are used as the frequency components in the sum of cosine functions, see Figure 6.  The weights of each component come from the dot product of the surface normal at the impact location and the displacement vector of the mode shape at that same spot.  These weighted cosines are then sampled at a rate corresponding to 44kHz – the sample frequency of the .wav file we’ll produce.

Figure 5: C# script to construct .wav file from superposition of weighted component signals sampled at 44kHz.
Figure 7: Illustration of first 6 non-rigid modal frequencies scaled by their relative displacements at a sample point.  The output audio .wav file contains the sum of these individual components sampled at a rate of 44000 Hz.

Impact location at tip of bar (above) and resulting sound (below). Note from Figure 3 that all mode shapes contain strong anti-nodes at this location and the resulting sound includes more high frequency components.

Impact location at the heel of the bar (above) and resulting sound (below). Notice from Figure 3 that only one low-frequency mode has a significant anti-node close to this impact location and is readily apparent in the audio.

Impact location under the heel of the bar (above) and resulting sound (below). Compared to the heel impact location, this location is closer to a few slightly higher frequency anti-nodes.

Try the Grasshopper Workflow for Generating Sound from Vibration Simulation on your component

Here is the full workflow to first do a vibration simulation and then convert the simulation results into sound files.

You can easily apply the workflow to any component. Just change the geometry, material properties, and the sample point. For example, we applied the same workflow to a tuning fork.

If you have any questions or want to learn more, write to us at info@intact-solutions.com.

Edit: Workflow updated to work with Rhino 8.