Skip to content
This repository was archived by the owner on Jan 12, 2024. It is now read-only.
This repository was archived by the owner on Jan 12, 2024. It is now read-only.

phases of FixedPointReflectionPhases #616

Open
@vivienlonde

Description

@vivienlonde

Describe the bug
FixedPointReflectionPhases returns phases to amplify the <0| _ |0> block of a StateOracle whereas the Q# documentation states that a StateOracle encodes information in its <1| _ |0> block: StateOracle documentation

To Reproduce
Here is a minimal not working example and a proposed fix : testFPAA

Expected behavior
The AboutTarget phases should be the opposite of their current value - see testFPAA.

Screenshots
FPAA_diagnostics

Additional context

  • It's a consistency issue between FixedPointReflectionPhases and the StateOracle type. Since other functions of the AmplitudeAmplification libraries (such as StandardAmplitudeAmplification and ObliviousAmplitudeAmplification) also use the <1| _ | 0> convention, I suggest to keep this convention and change the AboutTarget phases of FixedPointReflectionPhases. Indeed changing everything to the <0| _ | 0> convention would be more work and would be confusing for e.g. StandardAmplitudeAmplification.

  • Note that in the current implementation of FixedPointReflectionPhases, ReflectionPhases are computed from RotationPhases (see here). To find the transformation on RotationPhases that corresponds to taking the opposite of AboutTarget ReflectionPhases, it may be useful to think of RotationPhases as a kind of partial sums of ReflectionPhases (and therefore ReflectionPhases are a kind of discrete derivative of RotationPhases). See here for exact formulas.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Kind-BugSomething isn't workingPkg-StandardIssue relates to the Microsoft.Quantum.Standard package.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions