Skip to content

Instantly share code, notes, and snippets.

@jniemann66
Created April 25, 2017 13:03
Show Gist options
  • Save jniemann66/bf0d467a1da31043af203077cc955cda to your computer and use it in GitHub Desktop.
Save jniemann66/bf0d467a1da31043af203077cc955cda to your computer and use it in GitHub Desktop.
FIR Blueing Filter
# FIR filter coefficients for FIR to turn white noise into blue (3dB / octave increase)
# pretty good approximation (can probably safely truncate latter coeffs for shorter FIR)
b = np.array([
0.65574456 , -0.38378737 , -0.053818095 , -0.024852204 ,
-0.019328524 , -0.016130449 , -0.013568251 , -0.011437699 ,
-0.0096596723 , -0.0081750885 , -0.0069352004 , -0.0058993955 ,
-0.0050338087 , -0.0043101989 , -0.0037050145 , -0.0031986151 ,
-0.0027746217 , -0.0024193749 , -0.0021214835 , -0.0018714476 ,
-0.0016613448 , -0.0014845678 , -0.0013356065 , -0.0012098652 ,
-0.0011035114 , -0.0010133485 , -0.00093671048, -0.00087137371,
-0.00081548354, -0.00076749295, -0.00072611154
])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment