paulie.common.random_pauli_strings.get_random_k_local#

paulie.common.random_pauli_strings.get_random_k_local(k, n)#

Get random k-local Pauli string of length n.

Parameters:
  • k (int) – Length of locality.

  • n (int) – Length of Pauli string.

Returns:

Random k-local Pauli string of length n.

Return type:

str

Raises:

ValueError – If k > n.