ComputeReciprocalFxP operation


This documentation refers to the Classic QDK, which has been replaced by the Modern QDK.

Please see for the API documentation for the Modern QDK.

Namespace: Microsoft.Quantum.Arithmetic

Package: Microsoft.Quantum.Numerics

Computes the reciprocal of a number stored in a quantum register with the fixed-point representation.

operation ComputeReciprocalFxP (x : Microsoft.Quantum.Arithmetic.FixedPoint, result : Microsoft.Quantum.Arithmetic.FixedPoint) : Unit is Adj + Ctl


Given a register in the state $\ket{x}$ for a fixed-point number $x$, computes the reciprocal $1 / x$ into the state of the result register.


x : FixedPoint

Fixed-point number to be inverted.

result : FixedPoint

Fixed-point number that will hold the result. Must be initialized to $\ket{0.0}$.

Output : Unit