window

package
v0.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 5, 2020 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bartlett

type Bartlett struct {
}

Bartlett is a Bartlett window maker. Bartlett window is very similar to triangular window. For more info, see https://en.wikipedia.org/wiki/Window_function#Triangular_window

func NewBartlett

func NewBartlett() *Bartlett

NewBartlett makes a new Bartlett window maker.

func (*Bartlett) Make

func (w *Bartlett) Make(size int) []float64

Make Bartlett window of a given size (number of samples).

type BartlettHann

type BartlettHann struct {
}

BartlettHann is a BartlettHann window maker. For more info, see https://en.wikipedia.org/wiki/Window_function#Bartlett-Hann_window

func NewBartlettHann

func NewBartlettHann() *BartlettHann

NewBartlettHann makes a new BartlettHann window maker.

func (*BartlettHann) Make

func (w *BartlettHann) Make(size int) []float64

Make BartlettHann window of a given size (number of samples).

type Blackman

type Blackman struct {
}

Blackman is a Blackman window maker. For more info, see https://en.wikipedia.org/wiki/Window_function#Blackman_window

func NewBlackman

func NewBlackman() *Blackman

NewBlackman makes a new Blackman window maker.

func (*Blackman) Make

func (w *Blackman) Make(size int) []float64

Make Blackman window of a given size (number of samples).

type BlackmanHarris

type BlackmanHarris struct {
}

BlackmanHarris is a BlackmanHarris window maker. For more info, see https://en.wikipedia.org/wiki/Window_function#Blackman-Harris_window

func NewBlackmanHarris

func NewBlackmanHarris() *BlackmanHarris

NewBlackmanHarris makes a new BlackmanHarris window maker.

func (*BlackmanHarris) Make

func (w *BlackmanHarris) Make(size int) []float64

Make BlackmanHarris window of a given size (number of samples).

type BlackmanNuttall

type BlackmanNuttall struct {
}

BlackmanNuttall is a BlackmanNuttall window maker. For more info, see https://en.wikipedia.org/wiki/Window_function#Blackman-Nuttall_window

func NewBlackmanNuttall

func NewBlackmanNuttall() *BlackmanNuttall

NewBlackmanNuttall makes a new BlackmanNuttall window maker.

func (*BlackmanNuttall) Make

func (w *BlackmanNuttall) Make(size int) []float64

Make BlackmanNuttall window of a given size (number of samples).

type Cosine

type Cosine struct {
}

Cosine is a Cosine window maker. For more info, see https://en.wikipedia.org/wiki/Window_function#Cosine_window

func NewCosine

func NewCosine() *Cosine

NewCosine makes a new Cosine window maker.

func (*Cosine) Make

func (w *Cosine) Make(size int) []float64

Make Cosine window of a given size (number of samples).

type FlatTop

type FlatTop struct {
}

FlatTop is a FlatTop window maker. A flat top window is a partially negative-valued window that has a flat top in the frequency domain. They are designed to have a broader bandwidth and so have a poorer frequency resolution, leading to low amplitude measurement error suitable for use in in spectrum analyzers for the measurement of amplitudes of sinusoidal frequency components For more info, see https://en.wikipedia.org/wiki/Window_function//Flat_top_window

func NewFlatTop

func NewFlatTop() *FlatTop

NewFlatTop makes a new FlatTop window maker.

func (*FlatTop) Make

func (w *FlatTop) Make(size int) []float64

Make FlatTop window of a given size (number of samples).

type Gaussian

type Gaussian struct {
	// contains filtered or unexported fields
}

Gaussian is a Gaussian window maker. For more info, see https://en.wikipedia.org/wiki/Window_function#Gaussian_windows

func NewGaussian

func NewGaussian(sigma float64) (*Gaussian, error)

NewGaussian makes a new Gaussian window maker. Sigma must be <= 0.5.

func (*Gaussian) Make

func (w *Gaussian) Make(size int) []float64

Make Gaussian window of a given size (number of samples).

type Hamming

type Hamming struct {
}

Hamming is a Hamming window maker. For more info, see https://en.wikipedia.org/wiki/Window_function#Hann_and_Hamming_windows

func NewHamming

func NewHamming() *Hamming

NewHamming makes a new Hamming window maker.

func (*Hamming) Make

func (w *Hamming) Make(size int) []float64

Make Hamming window of a given size (number of samples).

type Hann

type Hann struct {
}

Hann is a Hann window maker. For more info, see https://en.wikipedia.org/wiki/Window_function#Hann_and_Hamming_windows

func NewHann

func NewHann() *Hann

NewHann makes a new Hann window maker.

func (*Hann) Make

func (w *Hann) Make(size int) []float64

Make Hann window of a given size (number of samples).

type Lanczos

type Lanczos struct {
}

Lanczos is a Lanczos window maker. The Lanczos window is used in Lanczos resampling. For more info, see https://en.wikipedia.org/wiki/Window_function#Lanczos_window.

func NewLanczos

func NewLanczos() *Lanczos

NewLanczos makes a new Lanczos window maker.

func (*Lanczos) Make

func (w *Lanczos) Make(size int) []float64

Make Lanczos window of a given size (number of samples).

type Nuttall

type Nuttall struct {
}

Nuttall is a Nuttall window maker. For more info, see https://en.wikipedia.org/wiki/Window_function#Nuttall_window.2C_continuous_first_derivative.

func NewNuttall

func NewNuttall() *Nuttall

NewNuttall makes a new Nuttall window maker.

func (*Nuttall) Make

func (w *Nuttall) Make(size int) []float64

Make Nuttall window of a given size (number of samples).

type Rectangular

type Rectangular struct {
}

Rectangular is a Rectangular window maker. Produces a rectangular window (all ones) of a given size (number of samples). For more info, see https://en.wikipedia.org/wiki/Window_function#Rectangular_window.

func NewRectangular

func NewRectangular() *Rectangular

NewRectangular makes a new Rectangular window maker.

func (*Rectangular) Make

func (w *Rectangular) Make(size int) []float64

Make Rectangular window of a given size (number of samples).

type Triangular

type Triangular struct {
}

Triangular is a Triangular window maker. Endpoints are near zero. Midpoint is one. There is a linear slope between endpoints and midpoint. For more info, see https://en.wikipedia.org/wiki/Window_function//Triangular_window

func NewTriangular

func NewTriangular() *Triangular

NewTriangular makes a new Triangular window maker.

func (*Triangular) Make

func (w *Triangular) Make(size int) []float64

Make Triangular window of a given size (number of samples).

type Tukey

type Tukey struct {
	// contains filtered or unexported fields
}

Tukey is a Tukey window maker. The Tukey window, also known as tapered cosine, can be regarded as a cosine lobe of width alpha * N / 2 that is convolved with a rectangular window. At alpha = 0 it becomes rectangular, and at alpha = 1 it becomes a Hann window. For more info, see https://en.wikipedia.org/wiki/Window_function//Tukey_window.

func NewTukey

func NewTukey(alpha float64) (*Tukey, error)

NewTukey makes a new Tukey window maker.

func (*Tukey) Make

func (w *Tukey) Make(size int) []float64

Make Tukey window of a given size (number of samples).

type WindowMaker

type WindowMaker interface {
	// Make window of given size.
	Make(size int) []float64
}

Window makes windows of a certain kind.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL