Generates a Hamming Window.
GHAMMING(N, spacing, alpha, "sym")
N 
 
An integer, the number of points to generate.  
spacing 
 
A real, the spacing (delta x) between points.  
alpha 
 
Optional. A real, the scaling parameter. Defaults to 0.54.  
"sym" 
 
Optional. A string, the symmetry flag.

A series.
ghamming(100,.01)
generates a 100point symmetric Hamming window using the following formula:
where α is the default value 0.54, n is the n^{th} point (1 <= n <= N) and N is 100, the number of points. The spacing between samples is set to 0.01.
ghamming(100,.01, "periodic")
generates a 100point periodic Hamming window using the following formula:
where α is the default value 0.54, n is the n^{th} point (1 <= n <= N) and N is 100, the number of points. The spacing between samples is set to 0.01.
A Hamming Window with α = 0.5 is identical to a HANNING Window.
The "sym" flag controls the window symmetry as follows:
"Symmetric" sets the last point to be the same value as the first point. For an N point symmetric window, a N1 point periodic window is effectively created and the N^{th} point is set to the same value as the first point.
"Periodic" or "iso" creates a periodic window function useful in spectrum analysis applications. "Periodic" or "iso" conforms to the ISO 184311 standard for windowing functions.
The Hamming, Hanning, Flattop and Blackman windows are part of the family of cosine window functions. The ISO 184311 standard periodic form of these windowing functions are defined by:
where K is the number of window
coefficients and N is the length
of the window. The symmetric
form of the window can be constructed by setting N to
For the default Hamming window:
Use HAMMING to automatically create and multiply a Hamming window with a series. For example:
hamming(W1)
multiplies Window 1 with a Hamming window of the same length and spacing as the series in W1.
Blackman, Hamming, Hanning and Kaiser Windows are useful in creating FIR filters and in preprocessing series for FFT calculations.
Oppenheim and Schafer.
Digital Signal Processing
Prentice Hall, 1975
Digital Signal Processing Committee
Programs for Digital Signal Processing
I.E.E.E. Press, 1979