erreor in matlab in the function freqz
이전 댓글 표시
Hello everyone,
i have an error in MATLAB that i can't have a solution,please help me if you can
this is the code MATLAB:
Nt=7;
N=(Nt-1)/2;
n=-N:1:N;
h=(1/3)*sinc(n/3);
[H,F] = freqz(h ,1 , 1024);
subplot(3,1,2),plot(abs(H)),title(' le gain');
subplot(3,1,3),plot(angle(H)),title('la phase');
and this is the error :

답변 (1개)
Star Strider
2020년 12월 23일
0 개 추천
The code works correctly when I run it, and indicates that it creates a lowpass filter with a passband of about
.
You actually did not post what the error message was, only that it appeared. What is the full error message (all the red text)?
댓글 수: 2
boutaina doudouche
2020년 12월 23일
Star Strider
2020년 12월 23일
There must be more to the error message than that.
In its absence, do you have your own funciton or variable named freqz?
To see if you do, run this from the Command Window or a script:
which freqz -all
The only result should be:
C:\Program Files\MATLAB\R2020b\toolbox\signal\signal\freqz.m
(or something simillar for your release).
If you get anything else, that is the problem and the solution is to re-name your function or variable.
카테고리
도움말 센터 및 File Exchange에서 Signal Processing Toolbox에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!