create_pauli_expansion#
-
cuquantum.
bindings. cupauliprop. create_pauli_expansion( - intptr_t handle,
- int32_t num_qubits,
- intptr_t xz_bits_buffer,
- int64_t xz_bits_buffer_size,
- intptr_t coef_buffer,
- int64_t coef_buffer_size,
- int data_type,
- int64_t num_terms,
- int32_t is_sorted,
- int32_t has_duplicates,
Creates a Pauli operator expansion.
- Parameters:
handle (intptr_t) – Library handle.
num_qubits (int32_t) – Number of qubits.
xz_bits_buffer (intptr_t) – Pointer to a user-owned memory buffer to be used by the created Pauli operator expansion for storing the X and Z bits for each Pauli operator term. The first
num_termsPauli operator terms will define the current Pauli operator expansion.xz_bits_buffer_size (int64_t) – Size (in bytes) of the provided memory buffer for storing the X and Z bits.
coef_buffer (intptr_t) – Pointer to a user-owned memory buffer to be used by the created Pauli operator expansion for storing the coefficients for all Pauli operator terms. The first
num_termsPauli operator terms will define the current Pauli operator expansion.coef_buffer_size (int64_t) – Size (in bytes) of the provided memory buffer for storing the coefficients.
data_type (int) – Data type of the coefficients in the Pauli operator expansion.
num_terms (int64_t) – Number of the Pauli operator terms stored in the provided memory buffer (the first
num_termscomponents define the current Pauli operator expansion).is_sorted (int32_t) – Whether or not the Pauli expansion is sorted. A sorted expansion has its Pauli operator terms sorted by the X and Z bits in ascending order (interpreted as big integers in little-endian representation).
has_duplicates (int32_t) – Whether or not there are duplicates in the expansion, i.e. several terms with identical X and Z bits.
- Returns:
Pauli operator expansion.
- Return type:
intptr_t
See also