SetQubit Method (Index, SetTo)
Cove - A Practical Quantum Computer Programming Framework
SetQubit Method (Index, SetTo)
NamespacesCove.BaseIQuantumRegisterSetQubit(Int32, Boolean)
Set a qubit to a particular state.
Declaration Syntax
C#Visual BasicVisual C++
IQuantumRegister SetQubit(
	int Index,
	bool SetTo
)
Function SetQubit ( _
	Index As Integer, _
	SetTo As Boolean _
) As IQuantumRegister
IQuantumRegister^ SetQubit(
	int Index, 
	bool SetTo
)
Parameters
Index (Int32)
Index of the qubit to set.
SetTo (Boolean)
Value to set the qubit to, true (1) or false (0)
Return Value
A reference to the modified register.
Remarks
A qubit is measured before it is set, so any other qubits entangled with this one will be effected.
Exceptions
ExceptionCondition
IndexOutOfRangeExceptionThrown if the specified index is out of range.

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