Mercurial > hg > ishara
view arrows/dsp/apowspec.m @ 61:eff6bddf82e3 tip
Finally implemented perceptual brightness thing.
author | samer |
---|---|
date | Sun, 11 Oct 2015 10:20:42 +0100 |
parents | 672052bd81f8 |
children |
line wrap: on
line source
% apowspec - Arrow to compute power spectra % % apowspec :: % [[N]] ~'analysis window' % -> arrow( {[[N]]}, {[[dftbins(N)]]}, empty). % % apowspec :: % [[M]] ~'analysis window', % N ~'size for FFT' % -> arrow( {[[M]]}, {[[dftbins(N)]]}, empty). function [o,fx]=apowspec(window,N) W=spdiag(window); if nargin<2, N=length(window); end fx=(0:dftbins(N)-1)/N; o=arr(@ps); function y=ps(x) y=powspec(W*x,N); end end