convert_dec2bin {QuantumOps}R Documentation

convert_dec2bin

Description

Takes an integer and returns an unsigned vector bits representing the same value

Usage

convert_dec2bin(x,len=32)

Arguments

x

Integer

len

Number of bits to represent integer with. Will crop most significant bits if insufficient length.

Value

Vector of bits with MSB first

Examples

 convert_dec2bin(10)
 convert_dec2bin(10,8)

[Package QuantumOps version 3.0.1 Index]