Class BandData

java.lang.Object
noiseBandMonitor.BandData

public class BandData extends Object
Class to create a set of octave or third octave bands using base-two exact steps according to the standard ANSI S1.11-2004.

Each band had a mid frequency, a band number and a name.

Author:
Doug Gillespie
  • Method Details Link icon

    • calcCentreFreq Link icon

      public static double calcCentreFreq(int bandNumber)
    • calcCentreFreq Link icon

      public static double calcCentreFreq(int bandNumber, BandType bandType, double fNom)
      Get a frequency for the centre of a ANSI standard band. Band 30 is 1000Hz, and numbers are then 1/3 octaves either side of this. This means that we don't quite hit decadal values which is a possibility for parts of the standard.
      Parameters:
      bandNumber -
      Returns:
    • getLowBandNumber Link icon

      public static int getLowBandNumber(double frequency)
      Get the highest band number which has a centre frequency below the given frequency in Hz.
      Parameters:
      frequency - Frequency in Hz
      Returns:
      Band number (30 = 1000 Hz).
    • getHighBandNumber Link icon

      public static int getHighBandNumber(double frequency)
      Get the lowest band number which has a centre frequency above the given frequency in Hz.
      Parameters:
      frequency - Frequency in Hz
      Returns:
      Band number (30 = 1000 Hz).
    • getBandHalfWidth Link icon

      public static double getBandHalfWidth(BandType bandType)
      Half width of a band = sqrt of the distance between band centres.
      Parameters:
      bandType -
      Returns:
    • getBandNumbers Link icon

      public int[] getBandNumbers()
      Returns:
      the bandNumbers
    • getBandCentres Link icon

      public double[] getBandCentres()
      Returns:
      the bandCentres
    • getBandHiEdges Link icon

      public double[] getBandHiEdges()
      Returns:
      the bandHiEdges
    • getBandLoEdges Link icon

      public double[] getBandLoEdges()
      Returns:
      the bandLoEdges
    • getBandNames Link icon

      public String[] getBandNames()
      Returns:
      the bandNames