Qrack  1.7
General classical-emulating-quantum development framework
Functions
Utility functions

Functions

virtual complexQrack::QEngineCPU::GetState ()
 
virtual void Qrack::QEngineCPU::CopyState (QInterfacePtr orig)
 Direct copy of raw state vector to produce a clone. More...
 
virtual double Qrack::QEngineCPU::Prob (bitLenInt qubitIndex)
 PSEUDO-QUANTUM Direct measure of bit probability to be in |1> state. More...
 
virtual double Qrack::QEngineCPU::ProbAll (bitCapInt fullRegister)
 PSEUDO-QUANTUM Direct measure of full register probability to be in permutation state. More...
 
virtual void Qrack::QEngineCPU::SetBit (bitLenInt qubitIndex1, bool value)
 Set individual bit to pure |0> (false) or |1> (true) state. More...
 
virtual void Qrack::QInterface::CopyState (QInterfacePtr orig)=0
 Direct copy of raw state vector to produce a clone. More...
 
virtual double Qrack::QInterface::Prob (bitLenInt qubitIndex)=0
 Direct measure of bit probability to be in |1> state. More...
 
virtual double Qrack::QInterface::ProbAll (bitCapInt fullRegister)=0
 Direct measure of full register probability to be in permutation state. More...
 
virtual void Qrack::QInterface::SetBit (bitLenInt qubitIndex1, bool value)
 Set individual bit to pure |0> (false) or |1> (true) state. More...
 
virtual void Qrack::QUnit::CopyState (QUnitPtr orig)
 
virtual void Qrack::QUnit::CopyState (QInterfacePtr orig)
 Direct copy of raw state vector to produce a clone. More...
 
virtual double Qrack::QUnit::Prob (bitLenInt qubit)
 Direct measure of bit probability to be in |1> state. More...
 
virtual double Qrack::QUnit::ProbAll (bitCapInt fullRegister)
 Direct measure of full register probability to be in permutation state. More...
 
virtual void Qrack::QUnit::SetBit (bitLenInt qubit1, bool value)
 Set individual bit to pure |0> (false) or |1> (true) state. More...
 

Detailed Description

Function Documentation

void Qrack::QUnit::CopyState ( QUnitPtr  orig)
virtual
void Qrack::QUnit::CopyState ( QInterfacePtr  orig)
virtual

Direct copy of raw state vector to produce a clone.

Warning
PSEUDO-QUANTUM

Implements Qrack::QInterface.

void Qrack::QEngineCPU::CopyState ( QInterfacePtr  orig)
virtual

Direct copy of raw state vector to produce a clone.

Warning
PSEUDO-QUANTUM

Implements Qrack::QInterface.

virtual void Qrack::QInterface::CopyState ( QInterfacePtr  orig)
pure virtual

Direct copy of raw state vector to produce a clone.

Warning
PSEUDO-QUANTUM

Implemented in Qrack::QEngineCPU, and Qrack::QUnit.

complex * Qrack::QEngineCPU::GetState ( )
virtual
double Qrack::QUnit::Prob ( bitLenInt  qubitIndex)
virtual

Direct measure of bit probability to be in |1> state.

Warning
PSEUDO-QUANTUM

Implements Qrack::QInterface.

double Qrack::QEngineCPU::Prob ( bitLenInt  qubitIndex)
virtual

PSEUDO-QUANTUM Direct measure of bit probability to be in |1> state.

Implements Qrack::QInterface.

virtual double Qrack::QInterface::Prob ( bitLenInt  qubitIndex)
pure virtual

Direct measure of bit probability to be in |1> state.

Warning
PSEUDO-QUANTUM

Implemented in Qrack::QEngineCPU, and Qrack::QUnit.

double Qrack::QUnit::ProbAll ( bitCapInt  fullRegister)
virtual

Direct measure of full register probability to be in permutation state.

Warning
PSEUDO-QUANTUM

Implements Qrack::QInterface.

double Qrack::QEngineCPU::ProbAll ( bitCapInt  fullRegister)
virtual

PSEUDO-QUANTUM Direct measure of full register probability to be in permutation state.

Implements Qrack::QInterface.

virtual double Qrack::QInterface::ProbAll ( bitCapInt  fullRegister)
pure virtual

Direct measure of full register probability to be in permutation state.

Warning
PSEUDO-QUANTUM

Implemented in Qrack::QEngineCPU, and Qrack::QUnit.

void Qrack::QUnit::SetBit ( bitLenInt  qubitIndex1,
bool  value 
)
virtual

Set individual bit to pure |0> (false) or |1> (true) state.

To set a bit, the bit is first measured. If the result of measurement matches "value," the bit is considered set. If the result of measurement is the opposite of "value," an X gate is applied to the bit. The state ends up entirely in the "value" state, with a random phase factor.

Reimplemented from Qrack::QInterface.

void Qrack::QEngineCPU::SetBit ( bitLenInt  qubitIndex1,
bool  value 
)
virtual

Set individual bit to pure |0> (false) or |1> (true) state.

Reimplemented from Qrack::QInterface.

void Qrack::QInterface::SetBit ( bitLenInt  qubitIndex1,
bool  value 
)
virtual

Set individual bit to pure |0> (false) or |1> (true) state.

To set a bit, the bit is first measured. If the result of measurement matches "value," the bit is considered set. If the result of measurement is the opposite of "value," an X gate is applied to the bit. The state ends up entirely in the "value" state, with a random phase factor.

Reimplemented in Qrack::QEngineCPU, and Qrack::QUnit.