Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Current »

A bit can have two states: 0 and 1, also called "True" and "False". Bit operations are mainly used with conditions, because there you always compare values against each other to decide whether the given condition is fulfilled (0) or not (1). Bits can also be used for logical operations in order to evaluate a result. There, two results are connected and the graph checks if the conjunction of these bits is true or false again. If both bits are 0, for example, then the conjunction is true (0) again. If one bit is 0 and the other one 1 then the result is false (1). For this purpose there are the classic operators like "AND", "OR", and "NOR" implemented as nodes.

Nodes

NameDescription
ArrayBitAllFalseThis node returns true if all the input bits are set to 1. False otherwise.
ArrayBitAllTrueThis node returns true if all the input bits are set to 0. False otherwise.
ArrayBitAnyFalseThis node returns true if the input contains at least one bit equal to 0. False otherwise.
ArrayBitAnyTrueThis node returns true if the input contains at least one bit equal to 1. False otherwise.
ArrayBitBuildByIndexGiven an array of indices this node returns a mask whereas each index included in the index-array is set to 1.
ArrayBitConcatThis node concatenates the inputs 'array0' and 'array1' into a single 'out' array.
ArrayBitConstantThis node returns a constant bit array.
ArrayBitCountFalseThis node returns the number of bits set to 0 in the input bit array.
ArrayBitCountTrueThis node returns the number of bits set to 1 in the input bit array.
ArrayBitFilterByMaskThis node returns the elements of the input 'array' at positions specified by the 'mask' parameter.
ArrayBitFirstFalseThis node returns the position of the first bit set to 0 in the input bit array or -1 if all bits are true.
ArrayBitFirstTrueThis node returns the position of the first bit set to 1 in the input bit array or -1 if all bits are false.
ArrayBitInfoReturns several information about the input bit array.
ArrayBitInsertElementThis node inserts all elements from the 'element' input into the input 'array' at the position specified by 'position'. If 'position' is equal or lower than 0 then the elements are inserted at the beginning of the array. If 'position' is greater or equal than the inputs 'array' size, elements are appended at the end.
ArrayBitLastFalseThis node returns the position of the last bit set to 0 in the input bit array or -1 if all bits are true.
ArrayBitLastTrueThis node returns the position of the last bit set to 1 in the input bit array or -1 if all bits are false.
ArrayBitMixThis node creates an output array based on the two inputs 'array0' and 'array1' and the input mask. If the mask value equals 0 then the value of 'array0' is used, if the mask value is 1 the value of 'array1' is used.
ArrayBitRandomThis node returns a random bit array of the size specified by the 'size' input.
ArrayBitRemoveIndexThis node removes all the input array positions indicated by the 'index' input.
ArrayBitResizeThis node resizes the input 'array'. If the new size is bigger than the original array-size, the last array-value is used to fill up the array.
ArrayBitReverseThis node reverses the order of the input array.
ArrayBitSetAllThis node sets all elements of the input 'array' to the given input 'value'.
ArrayBitSliceThis node returns an array containing the range of the input 'array' from the 'first' position with the given input 'size'.Thus, the output array is a subarray or slice of the input.
BitAndThis node returns the AND operation between the input bit arrays.
BitCopyThis node duplicates the value of 'in' to the output 'copy'.
BitEqualThis node returns the equivalence ( NOT XOR ) operation between the input bit arrays.
BitImplicationThis node returns the implication (NOT in0 OR in1) operation between the input bit arrays.
BitNandThis node returns the NAND operation between the input bit arrays.
BitNegateThis node inverts all the values of the input bit array.
BitNorThis node returns the NOR (NOT OR) operation between the input bit arrays.
BitOperationThis node computes a binary operation between the two input arrays.
BitOrThis node returns the OR operation between the input bit arrays.
BitXnorThis node returns the XNOR (NOT XOR) operation between the input bit arrays.
BitXorThis node returns the XOR operation between the input bit arrays.
GetArrayBitElementThis node returns the elements of the input 'array' at given positions, which are specified by the 'index' parameter.
GetBitGlobalVariableThis node returns a reference to previously stored variables in global memory (using the SetGlobalVariable-Nodes).
IntegerBitValueThis node returns the value of the bit at position 'index' of the binary representation of the input 'integer'.
IntegerSetBitValueThis node returns the input 'integer' value with its bit at position 'bit index' modified according to 'bit value'.
SetArrayBitElementThis node sets the elements of the input 'array' at given positions, which are specified by the 'index' parameter. The new value is specified by the 'value' input.
SetBitGlobalVariableThis node allows the user to create a reference or a copy of the input pin in global memory to be used within other RealFlow graph through the GetGlobalVariable nodes.

ArrayBitAllFalse

This node returns true if all the input bits are set to 1. False otherwise.

Inputs

NameTypesPassThroughDescription
inBitthrough

The in

Outputs

NameTypesPassThroughDescription
allBit 

The all

throughPassThroughin

The input 'in'

ArrayBitAllTrue

This node returns true if all the input bits are set to 0. False otherwise.

Inputs

NameTypesPassThroughDescription
inBitthrough

The in

Outputs

NameTypesPassThroughDescription
allBit 

The all

throughPassThroughin

The input 'in'

ArrayBitAnyFalse

This node returns true if the input contains at least one bit equal to 0. False otherwise.

Inputs

NameTypesPassThroughDescription
inBitthrough

The in

Outputs

NameTypesPassThroughDescription
anyBit 

The any

throughPassThroughin

The input 'in'

ArrayBitAnyTrue

This node returns true if the input contains at least one bit equal to 1. False otherwise.

Inputs

NameTypesPassThroughDescription
inBitthrough

The in

Outputs

NameTypesPassThroughDescription
anyBit 

The any

throughPassThroughin

The input 'in'

ArrayBitBuildByIndex

Given an array of indices this node returns a mask whereas each index included in the index-array is set to 1.

Example:

index array is [4,3,8,0]

mask is [1, 0, 0, 1, 1, 0, 0, 0, 1 ]

.

 

Inputs

NameTypesPassThroughDescription
index arrayInteger 

The index array

Outputs

NameTypesPassThroughDescription
maskBit 

The mask

ArrayBitConcat

This node concatenates the inputs 'array0' and 'array1' into a single 'out' array.

Inputs

NameTypesPassThroughDescription
array0Bit
 Optional

out array

The array0

array1Bit
 Optional

out array

The array1

Outputs

NameTypesPassThroughDescription
out arrayBit
 Optional

array0
array1

The out array

ArrayBitConstant

This node returns a constant bit array.

Inputs

NameTypesPassThroughDescription
bitBit (1) 

The bit

sizeInteger (1) 

The size

Outputs

NameTypesPassThroughDescription
arrayBit 

The array

ArrayBitCountFalse

This node returns the number of bits set to 0 in the input bit array.

Inputs

NameTypesPassThroughDescription
inBitthrough

The in

Outputs

NameTypesPassThroughDescription
countInteger 

The count

throughPassThroughin

The input 'in'

ArrayBitCountTrue

This node returns the number of bits set to 1 in the input bit array.

Inputs

NameTypesPassThroughDescription
inBitthrough

The in

Outputs

NameTypesPassThroughDescription
countInteger 

The count

throughPassThroughin

The input 'in'

ArrayBitFilterByMask

This node returns the elements of the input 'array' at positions specified by the 'mask' parameter.

Inputs

NameTypesPassThroughDescription
arrayBit
 Optional

out array

The array

maskBit 

The mask

Outputs

NameTypesPassThroughDescription
out arrayBit
 Optional

array

The out array

ArrayBitFirstFalse

This node returns the position of the first bit set to 0 in the input bit array or -1 if all bits are true.

Inputs

NameTypesPassThroughDescription
inBitthrough

The in

Outputs

NameTypesPassThroughDescription
firstInteger 

The first

throughPassThroughin

The input 'in'

ArrayBitFirstTrue

This node returns the position of the first bit set to 1 in the input bit array or -1 if all bits are false.

Inputs

NameTypesPassThroughDescription
inBitthrough

The in

Outputs

NameTypesPassThroughDescription
firstInteger 

The first

throughPassThroughin

The input 'in'

ArrayBitInfo

Returns several information about the input bit array.

Inputs

NameTypesPassThroughDescription
inBitthrough

The in

Outputs

NameTypesPassThroughDescription
sizeInteger 

The size

all trueBit 

True if all input bits are True. False otherwise

all falseBit 

True if all input bits are False. False otherwise

any trueBit 

True if any input bit is True. False otherwise

any falseBit 

True if any input bit is False. False otherwise

count trueInteger 

Number of input bits with True value

count falseInteger 

Number of input bits with False value

first trueInteger 

Position of the first input bit set to True

first falseInteger 

Position of the first input bit set to False

last trueInteger 

Position of the last input bit set to True

last falseInteger 

Position of the last input bit set to False

negatedBit 

Input array with all the bits inverted

throughPassThroughin

The input 'in'

ArrayBitInsertElement

This node inserts all elements from the 'element' input into the input 'array' at the position specified by 'position'. If 'position' is equal or lower than 0 then the elements are inserted at the beginning of the array. If 'position' is greater or equal than the inputs 'array' size, elements are appended at the end.

Inputs

NameTypesPassThroughDescription
arrayBit
 Optional

out array

The array

elementBit 

The value to insert

indexInteger (1) 

The position to insert the input element on

Outputs

NameTypesPassThroughDescription
out arrayBit
 Optional

array

The out array

ArrayBitLastFalse

This node returns the position of the last bit set to 0 in the input bit array or -1 if all bits are true.

Inputs

NameTypesPassThroughDescription
inBitthrough

The in

Outputs

NameTypesPassThroughDescription
lastInteger 

The last

throughPassThroughin

The input 'in'

ArrayBitLastTrue

This node returns the position of the last bit set to 1 in the input bit array or -1 if all bits are false.

Inputs

NameTypesPassThroughDescription
inBitthrough

The in

Outputs

NameTypesPassThroughDescription
lastInteger 

The last

throughPassThroughin

The input 'in'

ArrayBitMix

This node creates an output array based on the two inputs 'array0' and 'array1' and the input mask. If the mask value equals 0 then the value of 'array0' is used, if the mask value is 1 the value of 'array1' is used.

The size of the output is the same as mask's size.

Inputs

NameTypesPassThroughDescription
array0Bit
 Optional

out array

The array0

array1Bit
 Optional

out array

The array1

maskBit 

The mask

Outputs

NameTypesPassThroughDescription
out arrayBit
 Optional

array0
array1

The out array

ArrayBitRandom

This node returns a random bit array of the size specified by the 'size' input.

Inputs

NameTypesPassThroughDescription
sizeInteger (1) 

The size

seedInteger (1) 

The seed

Outputs

NameTypesPassThroughDescription
arrayBit 

The array

ArrayBitRemoveIndex

This node removes all the input array positions indicated by the 'index' input. .

Inputs

NameTypesPassThroughDescription
arrayBit
 Optional

out array

The array

indexInteger 

The positions of the input array to remove

Outputs

NameTypesPassThroughDescription
out arrayBit
 Optional

array

The out array

ArrayBitResize

This node resizes the input 'array'. If the new size is bigger than the original array-size, the last array-value is used to fill up the array.

Inputs

NameTypesPassThroughDescription
arrayBit
 Optional

out array

The array

sizeInteger (1) 

The size

Outputs

NameTypesPassThroughDescription
out arrayBit
 Optional

array

The out array

ArrayBitReverse

This node reverses the order of the input array. .

Inputs

NameTypesPassThroughDescription
arrayBit
 Optional

out array

The array

Outputs

NameTypesPassThroughDescription
out arrayBit
 Optional

array

The out array

ArrayBitSetAll

This node sets all elements of the input 'array' to the given input 'value'.

Inputs

NameTypesPassThroughDescription
arrayBit
 Optional

out array

The array

valueBit (1) 

The value

Outputs

NameTypesPassThroughDescription
out arrayBit
 Optional

array

The out array

ArrayBitSlice

This node returns an array containing the range of the input 'array' from the 'first' position with the given input 'size'.Thus, the output array is a subarray or slice of the input.

Inputs

NameTypesPassThroughDescription
arrayBit
 Optional

out array

The array

firstInteger (1) 

The position of the element that will be the first of the output array

sizeInteger (1) 

The total number of elements to copy from the input array. If value is negative, all the elements from 'first' are copied to the output array

Outputs

NameTypesPassThroughDescription
out arrayBit
 Optional

array

The out array

BitAnd

This node returns the AND operation between the input bit arrays.

The size of the output is the same as of the 'in0' input.

If the 'in1' input is smaller than 'in0' then its last value is reused for the rest of the array operation.

Inputs

NameTypesPassThroughDescription
in0Bit
 Optional

result

The in0

in1Bit 

The in1

Outputs

NameTypesPassThroughDescription
resultBit
 Optional

in0

The result

BitCopy

This node duplicates the value of 'in' to the output 'copy'.

Inputs

NameTypesPassThroughDescription
inBit 

The value to duplicate

Outputs

NameTypesPassThroughDescription
copyBit 

A copy of 'in'

BitEqual

This node returns the equivalence ( NOT XOR ) operation between the input bit arrays.

The size of the output is the same as of the 'in0' input.

If the 'in1' input is smaller than 'in0' then its last value is reused for the rest of the array operation.

Inputs

NameTypesPassThroughDescription
in0Bit
 Optional

result

The in0

in1Bit 

The in1

Outputs

NameTypesPassThroughDescription
resultBit
 Optional

in0

The result

BitImplication

This node returns the implication (NOT in0 OR in1) operation between the input bit arrays.

The size of the output is the same as of the 'in0' input.

If the 'in1' input is smaller than 'in0' then its last value is reused for the rest of the array operation.

Inputs

NameTypesPassThroughDescription
in0Bit
 Optional

result

The in0

in1Bit 

The in1

Outputs

NameTypesPassThroughDescription
resultBit
 Optional

in0

The result

BitNand

This node returns the NAND operation between the input bit arrays.

The size of the output is the same as of the 'in0' input.

If the 'in1' input is smaller than 'in0' then its last value is reused for the rest of the array operation.

Inputs

NameTypesPassThroughDescription
in0Bit
 Optional

result

The in0

in1Bit 

The in1

Outputs

NameTypesPassThroughDescription
resultBit
 Optional

in0

The result

BitNegate

This node inverts all the values of the input bit array.

Inputs

NameTypesPassThroughDescription
inBit
 Optional

result

The in

Outputs

NameTypesPassThroughDescription
resultBit
 Optional

in

The result

BitNor

This node returns the NOR (NOT OR) operation between the input bit arrays.

The size of the output is the same as of the 'in0' input.

If the 'in1' input is smaller than 'in0' then its last value is reused for the rest of the array operation.

Inputs

NameTypesPassThroughDescription
in0Bit
 Optional

result

The in0

in1Bit 

The in1

Outputs

NameTypesPassThroughDescription
resultBit
 Optional

in0

The result

BitOperation

This node computes a binary operation between the two input arrays.

The size of the output is the same as of the 'in0' input.

If the 'in1' input is smaller than 'in0' then its last value is reused for the rest of the array operation.

The negate operation is performed only over the 'in0' input.

Inputs

NameTypesPassThroughDescription
in0Bit
 Optional

result

The in0

in1Bit 

The in1

op
 List (1)

and
or
negate
xor
nor
xnor
nand
implication
equal

 

The bit operation

Outputs

NameTypesPassThroughDescription
resultBit
 Optional

in0

The result

BitOr

This node returns the OR operation between the input bit arrays.

The size of the output is the same as of the 'in0' input.

If the 'in1' input is smaller than 'in0' then its last value is reused for the rest of the array operation.

Inputs

NameTypesPassThroughDescription
in0Bit
 Optional

result

The in0

in1Bit 

The in1

Outputs

NameTypesPassThroughDescription
resultBit
 Optional

in0

The result

BitXnor

This node returns the XNOR (NOT XOR) operation between the input bit arrays.

The size of the output is the same as of the 'in0' input.

If the 'in1' input is smaller than 'in0' then its last value is reused for the rest of the array operation.

Inputs

NameTypesPassThroughDescription
in0Bit
 Optional

result

The in0

in1Bit 

The in1

Outputs

NameTypesPassThroughDescription
resultBit
 Optional

in0

The result

BitXor

This node returns the XOR operation between the input bit arrays.

The size of the output is the same as of the 'in0' input.

If the 'in1' input is smaller than 'in0' then its last value is reused for the rest of the array operation.

Inputs

NameTypesPassThroughDescription
in0Bit
 Optional

result

The in0

in1Bit 

The in1

Outputs

NameTypesPassThroughDescription
resultBit
 Optional

in0

The result

GetArrayBitElement

This node returns the elements of the input 'array' at given positions, which are specified by the 'index' parameter.

Inputs

NameTypesPassThroughDescription
arrayBit 

The array

indexInteger 

The index

Outputs

NameTypesPassThroughDescription
outBit 

The out

GetBitGlobalVariable

This node returns a reference to previously stored variables in global memory (using the SetGlobalVariable-Nodes).

Inputs

NameTypesPassThroughDescription
nameString (1) 

The name

Outputs

NameTypesPassThroughDescription
outBit 

The out

IntegerBitValue

This node returns the value of the bit at position 'index' of the binary representation of the input 'integer'.

Inputs

NameTypesPassThroughDescription
integer
 Numeric

Integer
Integer64

 

The integer

bit indexInteger 

The position of the bit of the input 'integer' to check

Outputs

NameTypesPassThroughDescription
bitBit 

The value of the bit for the 'integer' input

IntegerSetBitValue

This node returns the input 'integer' value with its bit at position 'bit index' modified according to 'bit value'.

Inputs

NameTypesPassThroughDescription
integer
 Numeric

Integer
Integer64

 Optional

result

The integer

bit indexInteger 

The position of the bit of the input 'integer' to be modified

bit valueBit 

The bit value to set for the 'integer' input

Outputs

NameTypesPassThroughDescription
result
 Numeric

Integer
Integer64

 Optional

integer

The input 'integer' with its bit modified

SetArrayBitElement

This node sets the elements of the input 'array' at given positions, which are specified by the 'index' parameter. The new value is specified by the 'value' input.

Inputs

NameTypesPassThroughDescription
arrayBit
 Optional

out array

The array

indexInteger 

The index

valueBit 

The value

Outputs

NameTypesPassThroughDescription
out arrayBit
 Optional

array

The out array

SetBitGlobalVariable

This node allows the user to create a reference or a copy of the input pin in global memory to be used within other RealFlow graph through the GetGlobalVariable nodes.

Inputs

NameTypesPassThroughDescription
nameString (1) 

The name

inBitthrough

The in

store copyBit (1) 

The store copy

Outputs

NameTypesPassThroughDescription
throughPassThroughin

The value connected to the input

out copyBit 

The value copied in memory in case a copy has been performed. The same input value otherwise

  • No labels