Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
How does the n index for a window with $0 \le |n| \le N/2$ e.g the Bohman window function, get implemented when having a specific window size?
if (n >= 0 && n <= N/2)
what happens with the passed in index e.g. 1000 of a 1024 window size ?
The window is defined as $-N/2 \le n \le N/2$ i.e. symmetric about $n=0$.
So, for a 1024 window size, $n=-512$ to $n=+511$ should give you the appropriate coefficients.
If you subtract N/2 from n in the equation, then your window will be centered at N/2, and n can range from 0 to N (e.g. larger than N/2).
Required, but never shown