About CAT arguments dimension are not consistent
5 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Hello, guys, i face a problem, please help me~
clear all;
clc;
[x Fs]=wavread('PhoneNumberA_2013.wav');
N=length(x);
x=[x 0];
K =round([697 770 852 941 1209 1336 1407]*N/8000);
y=zeros(1,N);
for k=1:7
v_1=0;
v_2=0;
v=0;
for i=1:N+1
v_2=v_1;
v_1=v;
v=2*cos(2*pi*k/N)*v_1-v_2+x(i);
end
y(K(k)) = v-exp(-j*2*pi*k/N)*v_1;
end
k=0:N-1;
stem(k,y)
The error information said Error using horzcat CAT arguments dimensions are not consistent. the specific error lies in x=[x 0]
I do not how to fix that, plz help me, thank you
1 Kommentar
Akzeptierte Antwort
Azzi Abdelmalek
am 20 Feb. 2013
Bearbeitet: Azzi Abdelmalek
am 20 Feb. 2013
If x is a column vector, you can t make an horizontal concatenation. Maybe you should do
x=[x;0]
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu DTMF finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!