what is function of [ ] in this code
1 visualización (últimos 30 días)
Mostrar comentarios más antiguos
Here is the code
h1336=[];
L=50;
fs=8000;
fb=1336;
h1336 = (2/L)*cos(2*pi*fb*(0:L-1)/fs);
[H,F] = freqz(h1336,1,[],fs);
What does this bracket [ ] do in freqz command
0 comentarios
Respuesta aceptada
Wayne King
el 21 de Oct. de 2011
It says "use the default value for the input N, the number of frequency points".
in freqz() that is 512.
So
[H,F] = freqz(h1336,1,[],fs);
is the same as:
[H,F] = freqz(h1336,1,512,fs);
Más respuestas (1)
Walter Roberson
el 21 de Oct. de 2011
If you do not specify the integer n, or you specify it as the empty vector [], the frequency response is calculated using the default value of 512 samples.
0 comentarios
Ver también
Categorías
Más información sobre Multirate Signal Processing en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!