 # Encoding graph into a GBS

Hello I would like to clarify something about the process of encoding a graph into a GBS device. In paper such as this one it is said that once you have the doubled adjacency matrix \tilde{A} of the graph you can map that matrix to covariance matrix \Sigma of a pure Gaussian state through a series of matrix multiplications: \begin{equation} \Sigma = Q - \mathbb{I}_{2M}/2, \quad Q = (\mathbb{I} - X\tilde{A})^{-1}, \quad X = \begin{bmatrix} 0 & \mathbb{I}_{M}\\ \mathbb{I}_{M} & 0 \end{bmatrix} \end{equation}.\\ It is then said that the GBS device can be programmed according to this matrix \Sigma.

However in this paper the Takagi-Autonne decomposition of the adjacency matrix is taken to program the gates of the GBS. I would like to know if these methods are independent of each other? Can either one of them be used? And is there a reference that explains how to program the GBS device according to the matrix \Sigma as I can’t seem to find one in the first paper?

Hi @Amanuel, thank you for your question. We will be taking a look at it and coming back with an answer hopefully on Tuesday. Have a good weekend!

Hey @Amanuel,

give me another day to double check with the co-authors, it has been a while… Hi @Maria_Schuld , thanks so much for the reply! I’ve been doing some more reading and it seems to me that the series of equations I listed above only give you the covariance matrix of the Gaussian state that corresponds to the adjacency matrix. But to actually program the GBS device to sample from that Gaussian state I believe you need to know what squeezing parameter to set each squeezer to and what the angles of each beam splitter need to be. These values seem to only be obtained from the Takagi-Autonne decomposition of the adjacency matrix but I could be missing something.

Hey @Amanuel,

Yes, I finally had a look as well and what you say sounds spot on. They are both referring to the same idea, but the second paper you cite goes into more detail of how to actually implement the strategy.

Hope this helps? (Well, you technically answered your own question )

Hi @Maria_Schuld, thank you for the confirmation!