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.

An error in the function FixedPointReflectionPhases #511

@vivienlonde

Description

@vivienlonde

Describe the bug
FixedPointReflectionPhases returns NaN phases.
https://github.com/microsoft/QuantumLibraries/blob/main/Standard/src/AmplitudeAmplification/StandardAlgorithms.qs#L53

Expected origin of the bug
At line 59: let beta = Cosh((1.0 / nQueriesDouble) * ArcCosh(Sqrt(successMin)));
ArcCosh is called on a value less than 1.

Expected fix
From https://arxiv.org/pdf/1409.3305.pdf: gamma^{-1} = T_{1/L} (1/delta).
I think that the Cosh and ArcCosh should be Cos and ArcCos instead.
(Other fixes may be needed too).

Additional context
Thanks for the great Amplitude Amplification library!

Metadata

Metadata

Assignees

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