Carry Method (CarryIndex, XIndex, YIndex, AncilliaIndex)
Cove - A Practical Quantum Computer Programming Framework
Carry Method (CarryIndex, XIndex, YIndex, AncilliaIndex)
NamespacesCove.BaseIQuantumAlgorithmsCarry(Int32, Int32, Int32, Int32)
Return the operations to perform the carry gate.
Declaration Syntax
C#Visual BasicVisual C++
List<IQuantumOperation> Carry(
	int CarryIndex,
	int XIndex,
	int YIndex,
	int AncilliaIndex
)
Function Carry ( _
	CarryIndex As Integer, _
	XIndex As Integer, _
	YIndex As Integer, _
	AncilliaIndex As Integer _
) As List(Of IQuantumOperation)
List<IQuantumOperation^>^ Carry(
	int CarryIndex, 
	int XIndex, 
	int YIndex, 
	int AncilliaIndex
)
Parameters
CarryIndex (Int32)
The index of the carry qubit. Remains unchanged after the operations are applied.
XIndex (Int32)
The index of the X qubit. Remains unchanged after the operations are applied.
YIndex (Int32)
The index of the Y qubit. On output this will be a + b (mod 2 addition)
AncilliaIndex (Int32)
The index of the ancillia (scratch) qubit. On output this will be (CarryIndex)(XIndex) + (XIndex)(CarryIndex) + (YIndex)(CarryIndex) (mod 2 addition)
Return Value
The operations to perform carry.
Exceptions
ExceptionCondition
DuplicateIndexesException Thrown if any of the indexes are duplicates.

Assembly: Cove.Base (Module: Cove.Base) Version: 1.0.0.0 (1.0.0.0)