概述
function [proj,scale,translation,freq,phase]=gas(signal_r,N,a_base,j_min,j_max,u_base,p_min,v_base,k_min,w_base,i_min,i_max);
%% this subroutine program(子程序)is to select in the dictionary the best atom suited the signal or the residual of the signal
% INPUT
% the signal_r: the signal or the residual of the signal to be decomposed
% the N: the length of the signal or of the residual of the signal or the length of the atoms
% parameters :the parameter to construct the dictionary , it has much influence on the speed of the decomposition
% a_base=2;
% j_min=0;
% j_max=log2(N);
% OUTPUT
% proj:the projection of the signal or the residual of the signal on the best atom
% scale:the scale of the best atom(s in the formula)
% translation:the translation of the best atom(u in the formula)
% freq:the freq of the best atom(v in the formula)
% phase:the phase of the best atom(w in the formula)
% proj_trans:to determine which projection is biggest
proj_trans=0;
proj=0;
% size_dic is one parameter to show the size of the over-complete dictionary used
size_dic=0;
% [hy,hx]=meshgrid(0:32-1,0:32-1);
% m=32;n=32;
for j=j_min:j_max
for p=p_min:N*2^(-j+1)
for k=k_min:2^(j+1)
for i=i_min:i_max
size_dic=size_dic+1;
s=a_base^j;
u=p*s*u_base;
v=k*(1/s)*v_base;
w=i*w_base;
t=0:N-1;
t=(t-u)/s;
g=(1/sqrt(s))*exp(-pi*t.*t).*cos(v*t+w);
g=g/sqrt(sum(g.*g));
proj_trans=sum(signal_r.*g);
if abs(proj_trans)>abs(proj)
proj=proj_trans;
scale=s;
translation=u;
freq=v;
phase=w;
end
end
end
end
end
disp('the size of the dictionary='),disp(size_dic); % size_dic: the size of the dictionary
end
%%%%%%%%%%%%%%%%%%%%%%%% end %%%%%%%%%%%%%%%%%%%%%%%%%%%%%
错误使用 gas
输入参数太多。
一直这么提示?这是为什么呢?
最后
以上就是高大月饼为你收集整理的matlab错误使用 输入参数过多,错误使用 gas 输入参数太多。的全部内容,希望文章能够帮你解决matlab错误使用 输入参数过多,错误使用 gas 输入参数太多。所遇到的程序开发问题。
如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。
发表评论 取消回复