Skip to content

0 44 0

Released on 2024-08-04.

Upgrade Instructions

Bug Fixes

  1. Fixed a bug related to nested control operations.
  2. Fixed a bug related to boolean arithmetic expressions with invert.
  3. Fixed a bug related to arithmetic expressions inside within-apply.

IDE

  1. Add back improved circuit nodes search.
  2. Fix bug in Quantum Program page .qprog file extensions uploads.
  3. New Quantum Program export option: Quantum programs can now be exported as .qprog files.
  4. Poll all active jobs in the job list, not just the selected job.
  5. Add support for Alice & Bob hardware configurations in the IDE.

Enhancements

  1. Add support for arithmetic boolean expressions as conditionals for control statements; see here.
  2. Add quantum structs.
  3. The element type of quantum arrays can be any quantum type. N-dimensional quantum arrays are supported.
  4. Operand parameter names are optional in both Native (qfunc (indicator: qbit) -> qfunc (qbit)) and Python (QCallable[QBit] -> QCallable[Annotated[QBit, "indicator"]]) Qmod.
  5. Improve error messages.
  6. Provide better circuits for certain boolean arithmetic expressions.
  7. Improved qubit reuse and runtime performance for model without constraints.
  8. Add solovay_kitaev_max_iterations field to the synthesis preferences, allowing for tuning the accuracy of the Solovay-Kitaev algorithm.
  9. Built-in classical functions to decompose/compose a matrix into/from a Hamiltonian. Example of usage:
mat = np.array([[0, 1, 2, 3], [1, 4, 5, 6], [2, 5, 7, 8], [3, 6, 8, 9]])
hamiltonian = matrix_to_hamiltonian(mat)
mat = hamiltonian_to_matrix(hamiltonian)
  1. parsed_states, parsed_counts, parsed_state_vector will contain the parsed execution details as lists if a quantum array was used in the model.
@qfunc
def main(qna: Output[QArray[QNum[3, True, 0]]]) -> None:
    allocate(6, qna)
    hadamard_transform(qna)


qp = synthesize(create_model(main))
res = execute(qp).result()
print(res[0].value.parsed_counts[0])

previously this would print -> state={'qna': 43} shots=27 now it prints -> state={'qna': [-2, 3]} shots=27

Library and Documentation

  1. A new tutorial on Hamiltonian simulation for block-encoded Hamiltonians, using QSVT and Qubitization, was added to the library; see here.
  2. A new tutorial on solving the discrete Poisson's equation using the HHL algorithm, combined with quantum sine and cosine transforms, was added to the library; see here.
  3. New state preparation functions - prepare_unifrom_trimmed_state, prepare_unifrom_interval_state, see here.
  4. Enhanced the Discrete logarithm example to the case where the order is not power of 2, see here.
  5. Updated the Quantum Types documentation page.

Interface Changes

  1. Some builtin operations parameters have been renamed:
  2. control(ctrl=..., operand=...) => control(ctrl=..., stmt_block=...)
  3. within_apply(compute=..., action=...) => within_apply(within=..., apply=...)
  4. power(power=..., operand=...) => power(exponent=..., stmt_block=...)
  5. invert(operand=) => invert(stmt_block=...)

Deprecations

  1. SDK: The @struct decorator has been removed. Define classical structs using @dataclass.
  2. The field variance in EstimationResult is deprecated, and will be populated with the value -1 until removed.
  3. The field timeout_sec in ExecutionPreferences, and the field job_timeout in AwsBackendPreferences, have been removed.
  4. classical arguments in the native language are now inside the parentheses section ((...)) alongside quantum variables and not inside the angle brackets (<...>), the angle brackets section is now considered deprecated. For example, you should migrate: qfunc <a: real> main{...} -> qfunc main(a: real) {...} for info refer to the language reference about functions. A Warning was added to the IDE in the case it is used.