https://github.com/fieldofnodes/VeriQuEST.jl

Quantum computation is an exciting field. There are many research institutes and companies working hard to push the state of the art into the era beyond the noisy intermediate-scale quantum (NISQ) era. This package is designed to emulate quantum computation classically. Specifically, `RobustBlindVerification.jl`

is an emulator of measurement based quantum computation (MBQC). Different to the gate model, MBQC relies on entangled states, projective measurements and adaptivity to perform quantum computation.

Implementation of protocol 1 from Leichtle et al (Verifying BQP Computations on Noisy Devices with Minimal Overhead).

Run the following commands along with relevant input to implement the blind verification.

Load packages, if not installed, then run `] add <PackageName>`

, for `QuEST_jl`

, go to https://github.com/fieldofnodes/QuEST_jl for installation instructions.

```
using Pkg
Pkg.activate(".")
using QuEST
using Test
using StatsBase
using Graphs
using CairoMakie
using RobustBlindVerification
```

Define the quantum state type, either a state vector backend (`StateVector()`

) or a density matrix backend (`DensityMatrix()`

)

` state_type = DensityMatrix()`

Using the Julia Graphs package, implement a graph.

```
num_vertices = N
graph = Graph(num_vertices)
```

Define the flow. As long a qubit index is inputted and a qubit index is ouputed, any function will do. Note that Julia is indexed starting from

The `forward_flow`

function takes a present qubit and returns the next qubit according to the flow.

```
function forward_flow(vertex)
# Define function or data structure to output new vertex index
return forward_vertex
end
```

The `backward_flow`

package takes the current vertex and returns the previous vertex.

```
function backward_flow(vertex)
# Define function or data structure to output old vertex index
return backward_vertex
end
```

Define the input and output vertices as tuples. For input vertices, provide the indices and the classical inputs. For no inputs, provide empty brackets `()`

```
input_indices = () # a tuple of indices
input_values = () # a tuple of input values
```

Provide the vertices considered the outputs of the graph.

` output_indices = (output_index_1,output_index_2,...,output_index_M)`

for

Provide the angles known to the client only. Data structures encapsulated by `[]`

are vectors in Julia.

` secret_angles = []`

Define the total number of rounds, the number of computational rounds and the test round threshold value (e.g.

```
total_rounds,computation_rounds = n,d
test_rounds_theshold = w
```

Contain all separate variables and parametes into the following `NamedTuple`

. Do not change this, simply name all of the above variables as seen in the code snippets.

```
para= (
graph=graph,
forward_flow = forward_flow,
backward_flow=backward_flow,
input_indices = input_indices,
input_values = input_values,
output_indices =output_indices,
secret_angles=secret_angles,
state_type = state_type,
total_rounds = total_rounds,
computation_rounds = computation_rounds,
test_rounds_theshold = test_rounds_theshold)
```

To just run the verification simulator

`run_verification_simulator(para)`

The outcome will be a named tuple

`(test_verification = test_verification_outcome, computation_verification = computation_verification_outcome, mode_outcome = mode_outcome)`

where `test_verification_outcome`

and `computation_verification_outcome`

is of type `Ok()`

or `Abort()`

based on outcomes computed according to Leichtle et al. The outcome of the computation is `mode_outcome`

.

For an example see `grover_verification_script.jl`

.