Hi Mr @nathan,
I’m sorry i didn’t provide any code .
import strawberryfields as sf
from strawberryfields.ops import *
import numpy as np
sf.__version__
>> '0.12.1'
#### create random points
x1 = 1
x2 = 0
eng = sf.Engine(
backend="fock",
backend_options={"cutoff_dim": 8,'shots':5000}
)
dist = sf.Program(4)
with dist.context as q:
Fock(1) |q[0]
Vacuum() | q[1]
Dgate(a=x1) | q[2]
Dgate(a=x2) | q[3]
BSgate() | (q[0],q[1])
BSgate() | (q[2],q[3])
CZgate(np.pi) | (q[1],q[3])
BSgate() | (q[0],q[1])
BSgate() | (q[2],q[3])
MeasureFock() | q[0]
MeasureFock() | q[1]
results = eng.run(dist)
print(results.samples)
>> [0, 0, None, None]
I implemented this figure:
I just want to know if I’m correct with my code and also how I can interpret the outcome as stated in the paper. I also want to know why the number of the samples is just one and I set the shots to 5000
sorry for not including the code from the beginning and I hope that the coronavirus situation is not bad at your place.