Engee documentation

Zero Crossing

Counting the number of signal crossings with zero in one time step.

blockType: Zero Crossing

Path in the library:

/Signal Operations/Signal Operations/Zero Crossing

Description

Block Zero Crossing concludes that the signal in this channel has passed through zero if it meets any of the following criteria, where — current signal value, — previous value and so on:

  • and

  • and

  • For a positive integer right , and , where

  • For a positive integer right , and , where

For the first value of the input signal and are equal to zero.

On the Cnt port, the block outputs the number of signal crossings with zero in one time step.

Ports

Input

# IN_1 — Input signal
vector | the matrix

Details

An input signal specified as a real vector or matrix.

Data types

Float16, Float32, Float64, Int8, Int16, Int32, Int64, UInt8, UInt16, UInt32, UInt64, Bool

Complex numbers support

I don’t

Output

# Cnt — number of zero crossings
scalar | vector-string

Details

The block displays the number of zero crossings in the input data as one of these values:

  • scalar — if the Input receives data in the form of a column vector, the block outputs a scalar value representing the number of zero crossings at the data Input.

  • vector-string — if the input data is a matrix, then the block outputs a row vector, each element of which represents the number of zero crossings in the corresponding input data column.

Data types

Float64

Complex numbers support

I don’t

Parameters

Main

# Input processing — input signal processing method
Columns as channels (frame based) | Elements as channels (sample based)

Details

Specify the input signal processing method:

  • Columns as channels (frame based) — when this value is selected, the unit processes each column of the input signal as a separate channel.;

  • Elements as channels (sample based) — when this value is selected, the unit processes each element of the input signal as a separate channel.

Values

Columns as channels (frame based) | Elements as channels (sample based)

Default value

Columns as channels (frame based)

Program usage name

InputProcessing

Tunable

No

Evaluatable

No