声学楼论坛技术交流区基础理论室 → 1/3oct smoothing 是什么意思,怎样实现


  共有14566人关注过本帖树形打印复制链接

主题:1/3oct smoothing 是什么意思,怎样实现

帅哥哟,离线,有人找我吗?
cauc509
  1楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:论坛游民 帖子:17 积分:180 威望:0 精华:0 注册:2006-7-27 20:17:18
1/3oct smoothing 是什么意思,怎样实现  发帖心情 Post By:2008-1-18 21:23:56 [只看该作者]

大家好,我是一个新人,在使用很多电声检测仪器的时候,对测出的频响、THD曲线都可以做一个后处理,用户可选择1/3or 1/6oct等平滑处理,这点我不是很理解,不知道有人可以告诉我吗?谢谢

我现在的理解就是是不是在规定的oct内做均值运算,见笑的想法,请大家指正:)


 回到顶部
帅哥哟,离线,有人找我吗?
ALI-SKY
  2楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信 SPL
等级:新手上路 帖子:79 积分:617 威望:0 精华:0 注册:2007-11-1 20:02:40
  发帖心情 Post By:2008-1-18 22:17:05 [只看该作者]

是指三分之一倍频和六分之一倍频,三分之一比六分之一更平滑;



       查找问题---挖地三尺
     解决问题--釜底抽薪
     避免问题--未雨绸缪
    
 回到顶部
帅哥哟,离线,有人找我吗?
cauc509
  3楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:论坛游民 帖子:17 积分:180 威望:0 精华:0 注册:2006-7-27 20:17:18
  发帖心情 Post By:2008-1-18 22:25:34 [只看该作者]

恩,这个我知道,但是我想知道的是具体做了怎样的处理?

 回到顶部
帅哥哟,离线,有人找我吗?
晴朗
  4楼 | QQ | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:黑侠 帖子:382 积分:3396 威望:0 精华:0 注册:2007-9-29 11:19:45
  发帖心情 Post By:2008-1-18 23:37:23 [只看该作者]

图片点击可在新窗口打开查看


You make your own luck.
 回到顶部
帅哥哟,离线,有人找我吗?
一个老兵
  5楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:新手上路 帖子:3518 积分:31704 威望:5 精华:20 注册:2005-10-31 11:40:50
  发帖心情 Post By:2008-1-19 1:10:40 [只看该作者]

http://www.community.chester.pa.us/files/technote/smooth.pdf?PHPSESSID=4033e68965cd4a568760bc17f2f59750
能浏览吗?

 回到顶部
帅哥哟,离线,有人找我吗?
一个老兵
  6楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:新手上路 帖子:3518 积分:31704 威望:5 精华:20 注册:2005-10-31 11:40:50
  发帖心情 Post By:2008-1-19 1:30:50 [只看该作者]

下段供参考吧,注意中间的smooth的一段.

我想,你想一想就能理解的.

我的理解是在那段频带内(1/3或1/6倍频程)的数据求平均,

具体的算法要查那些仪器和测试系统的相关资料.

原则上就是你已经查到的那些算法中的某一种.

过去手算的时侯,就是求算术平均值.

-----------


Convolution

 

In the real world it would be nice to do Fourier transform filtering; however, it takes a lot of computing power to do a FFT.  If one is working offline (e.g. turning and audio file into an mpeg encoded file) the time taken for Fourier processing does not really matter.  For signals that must be processed in real time (e.g. live audio) the computing overhead required to calculate an FFT do the filtering operation and then convert back with an IFFT becomes impractical either because the process cannot be done fast enough or because the computing power is too expensive.  It turns out that there is a way of designing a filter in the Fourier domain and then implementing that filter digitally in the time domain. The process of using the filters time domain version involves a mathematical process called convolution.  I’ll explain convolution in class, then we will do this little exercise to appreciate what a convolution does to simple wave forms.

 

1. To see what convolution does enter a square pulse signal, x, consisting of 10 0’s 10 1’s and 10 0’s. Like this.

>> x=[0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0]

Plot this signal. What do you expect when you convolve this signal with itself? You should be able to figure out what the result will look like.  Now try to form the convolution in practice using MATLAB’s conv function.

>> xx=conv(x,x);

Plot xx the result of convolving x with itself.  Is it what you predicted?

Now try a different function—the triangle

>> p=[0 0 0 0 1 2 3 4 5 4 3 2 1 0 0 0 0]

>>pp=conv(p,p);

Plot it. Pretty, no?

 

2. It is not necessary to convolve a function only with itself. In the next example we will use convolution to reduce the noise in a signal. First let’s create a noisy signal. Create a sine wave

>> t=0:0.001:1;

>> w=2*pi*3;

>> y=sin(w*t);

Plot it. It is nice and “clean”. What is the sampling rate in my example? Does the plot make sense in terms of number of waves in the 1 second time window?

Now we create noise using the rand function.

>> for k=1:max(size(t))

noise(k)=rand*0.2;

end

>>

Next we add the noise to the original signal

>>yn=y+noise;

Plot the array of signal plus noise yn. Hold that plot!

The smoothing function that we will use is based on binomial coefficients obtained from Pascal’s triangle.  Again some class explanation is necessary to understand how to create these coefficients and (more importantly) why they are useful for smoothing.

Create the binomial smoothing function

>> binom=(1/64)*[1 6 15 20 15 6 1]

Why do we multiply by (1/64)?

Smooth the signal by convolving the noisy signal yn with the smoothing function.

yfilt=conv(binom,yn);

Plot the filtered yfilt on top of the signal plus noise yn. Smoother, no? Try applying the filter again. Plot. Even more smooth, no? [This text sound like it was written by Pepe le Pew!]  Why does the plot seem to shift to the right with each smoothing?

 

3. Now for the real deal—creating a filter in the time domain by specifying the filter in the frequency domain and doing an inverse Fourier transform. Our aim is to create a low pass filter that has a cutoff of 500 Hz.  We will test this filter by creating complex tone with a bunch of harmonics some of which go beyond the pass band.

 

Step 1—creating the filter in the frequency domain.  Our sampling rate will be our old favorite 22050. In the frequency domain our ideal low pass filter has the first 500 Hz equal to 1 and all the rest equal to 0. We call the frequency domain filter profile H. This profile is referred to as the transfer function of the filter.

>> H=zeros(1,22051);

>> H(1:500)=1;

>> H(22051-500:22051)=1;

Step2—turn this profile in frequency into a time domain filter function. The time domain signal is called the impulse response.

>> filt=ifft(H);

Now convert this impulse response so that it is correctly displayed in time and then plot it. OK I know some explanation is needed on the fftshift idea…

>>filt=fftshift(filt);

>>plot(real(filt))

Look carefully at the impulse response.  First, it goes on across all time values.  In reality it goes on in time from negative infinity to positive infinity. Such filter behavior is called an Infinite Impulse Response (IIR). Clearly such infinite behavior will be a bitch to deal with in practice. Luckily the signal drops off in each direction so that we can truncate the filter and only use a small section. Although this point is not clear from our analysis, the impulse goes on from times that precede t=0. Such behavior is called acausal. It implies that filtering starts before any signal is present. To create our truncated signal, h, we want 500 points on either side of the central maximum.

>>h=real(filt(10526:11526));

 

Step 3—lets test our filter. Create a complex tone of fundamental 200 Hz and a bunch of harmonics (I chose odd harmonics for no particularly good reason.

>> w=2*pi*200

>> y=sin(w*t)+sin(3*w*t)+sin(5*w*t)+sin(7*w*t)+sin(9*w*t)+sin(11*w*t);

Form the spectrum of our complex tone and plot it and hold that plot.

>> fy=fft(y);

>> plot(abs(fy(1:11025))

>>hold

 

Now we use our time domain representation of the filter, h, and apply it to our complex tone, y, to get our filtered signal, fsig.

>> fsig=conv(h,y);

Take the spectrum of fsig and plot it on top of the spectrum of our original signal (in red). Note that when I take the FFT I cut off the fist 500 and the last 500 elements of fsig.  Why?  How come fsig is longer than y?

>> ffsig=fft(fsig(500:22550));

>> plot(abs(ffsig(1:11025)),'r')

Has filtering taken place in the manner we expected? Did this process remove the higher harmonics? Which ones did it remove?

 

4. Final convolution exercise. The last filtering exercise was performed on a signal with a bunch of well spaced apart frequencies.  That example made the filter look pretty good. To appreciate that there are some limitations we now use our same filter from last time, h, applied to a continuous set of frequencies.  To get a continuous frequency distribution we use our old friend click.m to generate a short “click”. As we have seen in the past the click possesses a broad continuous range of frequencies. Choose s=0.0001 (I think?  We might experiment in class.  Run click. Plot the click, y, to remind yourself of the time signal we are using. Take an FFT of y and plot and hold it.

>> click

>> plot(y)

>> fy=fft(y);

>> plot(abs(fy(1:11025)));

>> hold

Now filter the click using our impulse response filter, h.

>>yfilt=conv(h,y);

Form the FFT of our filtered signal yfilt and plot it.

>> fyfilt=fft(yfilt(500:22550));

>> plot(abs(fy(1:11025)))

Zoom in to see if the cut-off is nice and clean.  Is it perfect? Why not?

 

5. Windowing.  Using the truncated time signal, h, (only 1000 time steps) instead of the full time signal, filt, (22050 time steps) leads to a frequency cut-off that has a bunch of little bumps beyond our desired cut-off frequency.  This problem is very common in time and spectrum manipulation. It occurs whenever the signal in either time or frequency is cut off suddenly.  Nature does not like that sharp, abrupt cut-off. For example, it is really not possible to synthesize a square wave that is perfectly square because it would require an infinite set of harmonic frequencies.  If you think back to the square wave exercise we did earlier we always had a square wave with wiggly shoulders because we only had a finite number of harmonics in our synthesis. In the case here we truncated the time signal, h, by just cutting it off—essentially we multiplied by a square time window 1000 time steps long.  Nature doesn’t like those square windows, and, as a consequence, we ended up with the bumps.   We can get rid of those ugly bumps by the use of a smooth window instead of the abrupt square window. Let’s make the smooth window—there are many and this one is called the Blackman window. Open a new m-file and type the following

function [w]=blackmanwind(M)

% Generate a Blackmann window length M

w = .42 - .5*cos(2*pi*(0:M-1)/(M-1)) + .08*cos(4*pi*(0:M-1)/(M-1));

 

Save this file as blackmanwind.m

 

Back in the Command window run

>> [w]=blackmanwind(1001);

This creates w the new, non-square window.  Plot it. Not square, eh!

Now multiply h by the Blackman window and plot it. See how the signal h2 tapers away smoothly to zero at the edges.

>> h2=h.*w;

>> plot(h2)

Now convolve our new time domain filter function h2 with the click signal y; form a spectrum and plot it.

>> convy2=conv(h2,y);

>> fconvy=fft(convy(500:22550);

Plot the bumpy signal from before and hold it.

>> plot(fyfilt);

>>hold

Now plot our Blackmann window spectrum in red.

>>plot(fconvy,’r’)

Examine the red curve compared to the blue—smoother, no?

 

Epilogue

Why are these time domain representations easier to use? Because they can be implemented on a signal as it passes through a digital signal processing (DSP) module. DSP’s have registers and buffers to hold a section of the signal and perform the time convolution as the signal passes through the device. This process is much easier and cheaper to implement compared to FFTs. Of course we just looked at one simple filter—the possibilities are enormous.

 

 

 

 

 

 

 


 回到顶部
帅哥哟,离线,有人找我吗?
晴朗
  7楼 | QQ | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:黑侠 帖子:382 积分:3396 威望:0 精华:0 注册:2007-9-29 11:19:45
  发帖心情 Post By:2008-1-19 10:20:48 [只看该作者]

没问题,可以看的


You make your own luck.
 回到顶部
帅哥哟,离线,有人找我吗?
晴朗
  8楼 | QQ | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:黑侠 帖子:382 积分:3396 威望:0 精华:0 注册:2007-9-29 11:19:45
  发帖心情 Post By:2008-1-19 10:25:43 [只看该作者]

以下是引用一个老兵在2008-01-19 01:10:40的发言:
http://www.community.chester.pa.us/files/technote/smooth.pdf?PHPSESSID=4033e68965cd4a568760bc17f2f59750
能浏览吗?

可以浏览的,谢谢



You make your own luck.
 回到顶部
帅哥哟,离线,有人找我吗?
一个老兵
  9楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:新手上路 帖子:3518 积分:31704 威望:5 精华:20 注册:2005-10-31 11:40:50
  发帖心情 Post By:2008-1-22 0:22:26 [只看该作者]

谢谢晴朗.

 回到顶部
帅哥哟,离线,有人找我吗?
一个老兵
  10楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:新手上路 帖子:3518 积分:31704 威望:5 精华:20 注册:2005-10-31 11:40:50
  发帖心情 Post By:2008-1-22 0:27:50 [只看该作者]

ALL-SKY:是指三分之一倍频和六分之一倍频,三分之一比六分之一更平滑;


-------

是这样,但是在扬声器频率曲线的表达中不应用三分之一平滑.


 回到顶部
帅哥哟,离线,有人找我吗?
Audio-ming
  11楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信 野兔帮--小野兔
等级:论坛游侠 帖子:23 积分:469 威望:0 精华:0 注册:2006-1-16 19:28:04
  发帖心情 Post By:2008-1-22 15:02:26 [只看该作者]

31段均衡器就是1/3oct 设计的 



我是一个小小的野兔子,但我一定会很快长大的!
 回到顶部
帅哥哟,离线,有人找我吗?
Audio-ming
  12楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信 野兔帮--小野兔
等级:论坛游侠 帖子:23 积分:469 威望:0 精华:0 注册:2006-1-16 19:28:04
  发帖心情 Post By:2008-1-22 15:03:31 [只看该作者]

又来灌水的!


我是一个小小的野兔子,但我一定会很快长大的!
 回到顶部
帅哥哟,离线,有人找我吗?
一个老兵
  13楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:新手上路 帖子:3518 积分:31704 威望:5 精华:20 注册:2005-10-31 11:40:50
  发帖心情 Post By:2008-1-27 6:23:13 [只看该作者]

仔细推推敲的话,

我的在第六楼的所写的平均的那段话并不是SMOOTH.

好在引文是正确的.

 回到顶部
帅哥哟,离线,有人找我吗?
一个老兵
  14楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:新手上路 帖子:3518 积分:31704 威望:5 精华:20 注册:2005-10-31 11:40:50
  发帖心情 Post By:2008-1-27 6:32:19 [只看该作者]

楼主的问题很好.

我还是那个看法:用计算机测试系统测完扬声器的频率响应曲线后,
请慎重使用平滑功能.

如果我是用户的话,
则会对扬声器测试结果要求提供测试条件和种种有关相关资料,
等建立了可以相互信任的关系后,可简化一些,
但是测试报告则还是要清楚.

啊,本段跑题了.

 回到顶部
客人(121.34.*.*)
  15楼


  发帖心情 Post By:2008-1-28 9:25:42 [只看该作者]

仔细考察一下SMOOTHING的结果,可发现各软件使用的算法不一样,可能这就是楼主要问问题的原因吧。

对于要自己编程进行数据处理的人来说,这个是很有趣的问题。

我就发现过MLSSA的冲击转阶跃响应的算法,和另外一个软件有不同的地方。


 回到顶部
客人(58.62.*.*)
  16楼


  发帖心情 Post By:2008-1-29 0:06:36 [只看该作者]

觉得要在测试报告里面写清楚是否采用了后处理手段以及采用处理手段的技术标准。

1/3oct 的平滑处理我的理解是依照傅立叶函数在测试设备中实现自动化运算的一种算术平均值还是几何平均值?


 回到顶部
帅哥哟,离线,有人找我吗?
石头说话
  17楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:新手上路 帖子:55 积分:598 威望:0 精华:0 注册:2006-6-19 18:05:11
  发帖心情 Post By:2008-1-29 8:32:56 [只看该作者]

学习中!



经验是向你们学的!
 回到顶部
帅哥哟,离线,有人找我吗?
henley_z
  18楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信 荒原困兽
等级:新手上路 帖子:401 积分:2571 威望:0 精华:0 注册:2008-1-29 11:06:14
  发帖心情 Post By:2008-3-3 15:25:10 [只看该作者]

learning


敦伦尽份   闲邪存诚
 回到顶部
客人(202.181.*.*)
  19楼


  发帖心情 Post By:2008-3-20 21:17:14 [只看该作者]

图片点击可在新窗口打开查看

 回到顶部
帅哥哟,离线,有人找我吗?
yz2666
  20楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:业余侠客 帖子:42 积分:414 威望:0 精华:0 注册:2008-8-10 3:26:29
  发帖心情 Post By:2009-3-28 16:46:08 [只看该作者]

引出来这么多东西。


 回到顶部
总数 27 1 2 下一页