Scale by Power of 2
- Updated2023-02-17
- 2 minute(s) read
Scale by Power of 2
Multiplies the input by 2 raised to a specified power.
Inputs/Outputs

n
The power to raise the input by.
Rounding and Coercion Behavior
If n is a floating-point number, this function rounds n before it scales x (0.5 rounds to 0; 0.51 rounds to 1). If n is a 64-bit integer, this function coerces n to a 32-bit integer.

x
The value to multiply by 2 raised to the specified power.
Data Type Changes on FPGA
When you add this node to a document targeted to an FPGA, this input has a default data type that uses fewer hardware resources at compile time.

x * 2^n
The result of multiplying the input by 2 raised to the specified power.
Data Type Changes on FPGA
When you add this node to a document targeted to an FPGA, this output has a default data type that uses fewer hardware resources at compile time.