Skip to content

v3.4.0

Compare
Choose a tag to compare
@TysonRayJones TysonRayJones released this 10 Oct 07:23
· 73 commits to master since this release

Overview

This release refactors QuEST for native Windows support, and adds some initialisation and seeding utilities mostly useful for simulators which use QuEST as a backend.

New features

Deterministically project a qubit into a classical outcome without renormalising the state.

  • applyProjector()

Density matrices, like state-vectors, can now be directly initialised from arrays of all amplitudes.

  • initStateFromAmps()

Users can now view and keep track of the seeds to QuEST's random number generator.

  • getQuESTSeeds()

Native Windows support! QuEST can now be compiled directly in MSVC, without needing to use MinGW. An MSVC build test is now part of the Github CI, although unit tests do not yet run automatically.

  • compile with CMake and NMake in the build folder via
    cmake .. -G "NMake Makefiles"
    nmake
    
  • or, compile directly with GNUMake from the root directory via
    cp examples/makefile .
    make COMPILER=cc COMPILER_TYPE=MSVC
    

API breaking changes

  • seedQuEST() and seedQuESTDefault() now require a pointer to the active QuESTEnv instance.
  • Previously, SCALED_INVERSE_SHIFTED_DISTANCE in applyNamedPhaseFunc() computed coeff/sqrt( (x2-x1-dx)^2 + ... ), but now computes coeff/sqrt( (x1-x2-dx)^2 + ... (x1 and x2 have swapped), to be more in-line with the expected behaviour.
  • Previously, SCALED_INVERSE_SHIFTED_NORM and SCALED_INVERSE_SHIFTED_DISTANCE in applyNamedPhaseFunc() used their divergence parameter when their denominators were precisely zero. Now, the divergence parameter is used whenever the denominator is within REAL_EPS to zero. This catches the scenario when a divergence has been translated only a very small distance from a sampled point.