Compare To Constant
Compares the input signal with a constant.
blockType: Compare To Constant
Path in the library:
|
Description
Block Compare To Constant compares the input signal with the constant specified in the parameter Constant value. The comparison method is set by the parameter Operator.
Ports
Input
#
IN_1
—
Input signal
scalar
Details
The input signal is in the form of a scalar for comparison with a constant.
| Data types |
|
| Complex numbers support |
Yes |
Output
#
OUT_1
—
Output signal
scalar
Details
Output — 0 if the comparison is false, and 1 if it is true.
| Data types |
|
| Complex numbers support |
Yes |
Parameters
Main
#
Operator —
The logical operator
⇐ | == | ~= | < | >= | >
Details
- This parameter can have the following values
-
-
==— the input value is equal to a constant. -
~=— the input value is not equal to a constant. -
<— the input value is less than a constant. -
⇐— the input value is less than or equal to a constant. -
>— the input value is greater than a constant. -
>=— the input value is greater than or equal to a constant.
-
| Values |
|
| Default value |
|
| Program usage name |
|
| Tunable |
No |
| Evaluatable |
No |
#
Constant value —
a constant for comparison
Scalar / array of real and/or complex numbers
Details
The value of the constant that the input value is compared to.
| Default value |
|
| Program usage name |
|
| Tunable |
Yes |
| Evaluatable |
Yes |
#
Output data type —
type of output data
Bool | UInt8
Details
Specify the type of output data Bool or UInt8.
| Values |
|
| Default value |
|
| Program usage name |
|
| Tunable |
No |
| Evaluatable |
No |