comparison scripts/signal/rectangle_sw.m @ 7125:f084ba47812b

[project @ 2007-11-08 02:29:23 by jwe]
author jwe
date Thu, 08 Nov 2007 02:29:24 +0000
parents a1dbe9d80eee
children fd0a3ac60b0e
comparison
equal deleted inserted replaced
7124:d07cb867891b 7125:f084ba47812b
25 25
26 ## Author: FL <Friedrich.Leisch@ci.tuwien.ac.at> 26 ## Author: FL <Friedrich.Leisch@ci.tuwien.ac.at>
27 ## Description: Rectangular spectral window 27 ## Description: Rectangular spectral window
28 28
29 function retval = rectangle_sw (n, b) 29 function retval = rectangle_sw (n, b)
30
31 if (nargin != 2)
32 print_usage ();
33 endif
30 34
31 retval = zeros (n, 1); 35 retval = zeros (n, 1);
32 retval(1) = 2 / b + 1; 36 retval(1) = 2 / b + 1;
33 37
34 l = (2:n)' - 1; 38 l = (2:n)' - 1;