Changes to physical behaviour of the Bell State Analyzer Node and photon emission at Rule Engine
In this PR I rewrote mainly the BSA and the BSAController.
Link level generation mechanism
Prior to this PR, the link generation creates a Phi+ state of Bell pair when no error occurs. This does not reflect the reality of linear optics which is the assumption of the hardware used in QuISP.
This PR changed the behaviour of the link generation to an entanglement swap where the BSA simply measure the incoming photons in Bell basis. The BSA is assume to be able to distinguish between Psi+ and Psi- state where Phi +/- state cannot be distinguish hence even with no loss or channel error. The success probability of the link generation is only at 50%.
The link level message is also changed into denoting a successful measurement instead of the failure.
The BSAController now has a BSMNotification time out which will increase each time QNode does not emit photons. The backoff time scales linearly to the number of no response.
Photon emission mechanism
Prior to this PR, Rule Engine (RE) relies on multiple packet and internal messages to emit a photon. In this PR, I introduce a new mechanism where upon receiving BSA results. All emission scheduled will be cancelled. And we only schedule one photon emission at a time to the QNIC. The self message only contains EmitPhoton message type and each QNIC has one single message maintained by the RE.
This should close #286 , close #371, close #187 and close #457.
Changes to physical behaviour of the Bell State Analyzer Node and photon emission at Rule Engine
In this PR I rewrote mainly the BSA and the BSAController.
Link level generation mechanism
Prior to this PR, the link generation creates a Phi+ state of Bell pair when no error occurs. This does not reflect the reality of linear optics which is the assumption of the hardware used in QuISP.
This PR changed the behaviour of the link generation to an entanglement swap where the BSA simply measure the incoming photons in Bell basis. The BSA is assume to be able to distinguish between Psi+ and Psi- state where Phi +/- state cannot be distinguish hence even with no loss or channel error. The success probability of the link generation is only at 50%.
The link level message is also changed into denoting a successful measurement instead of the failure.
The BSAController now has a BSMNotification time out which will increase each time QNode does not emit photons. The backoff time scales linearly to the number of no response.
Photon emission mechanism
Prior to this PR, Rule Engine (RE) relies on multiple packet and internal messages to emit a photon. In this PR, I introduce a new mechanism where upon receiving BSA results. All emission scheduled will be cancelled. And we only schedule one photon emission at a time to the QNIC. The self message only contains
EmitPhoton
message type and each QNIC has one single message maintained by the RE.This should close #286 , close #371, close #187 and close #457.
This change is