Returns a slice (subset) of the register from the beginning to EndIndex, then
has the operation applied to it.
| C# | Visual Basic | Visual C++ |
public IQuantumRegister SliceTo( int EndIndex, IQuantumOperation Operation )
Public Function SliceTo ( _ EndIndex As Integer, _ Operation As IQuantumOperation _ ) As IQuantumRegister
public: virtual IQuantumRegister^ SliceTo( int EndIndex, IQuantumOperation^ Operation ) sealed
- EndIndex (Int32)
- The ending index of the slice.
- Operation (IQuantumOperation)
- The operation to apply to the slice.
The quantum register representing the slice.
| Exception | Condition |
|---|---|
| IndexOutOfRangeException | Thrown if the end index is out of range. |
| NotUnitaryOperationException | Thrown if a non-unitary operation is
passed. All quantum operations must be unitary. |
| SizeMismatchException | Thrown if the size of one of the operations
does not match the size of the register. |
| ArgumentException | Thrown if the operation does not have
AbstractSimulatedQuantumOperation as a base class. |