Discrete-time Semiclassical Szegedy Quantum Walks

Quantum walks are promising tools based on classical random walks, with plenty of applications such as many variants of optimization. Here we introduce the semiclassical walks in discrete time, which are algorithms that combines classical and quantum dynamics. Specifically, a semiclassical walk can be understood as a classical walk where the transition matrix encodes the quantum evolution. We have applied this algorithm to Szegedy's quantum walk, which can be applied to any arbitrary weighted graph. We first have solved the problem analytically on regular 1D cycles to show the performance of the semiclassical walks. Next, we have simulated our algorithm in a general inhomogeneous symmetric graph, finding that the inhomogeneity drives a symmetry breaking on the graph. Moreover, we show that this phenomenon is useful for the problem of ranking nodes in symmetric graphs, where the classical PageRank fails. We have demonstrated experimentally that the semiclassical walks can be applied on real quantum computers using the platform IBM Quantum.


I. INTRODUCTION
Quantum walks are algorithms born from the quantization of classical random walks. They were first proposed in [1] in the discrete time version, and later in [2] using a continuous time. However, precursor ideas can be attributed to Feynman [3]. These walks have given rise to a wide variety of algorithms for problems such us triangle finding [4], element distinctness [5] and quantum search [6]. Moreover, these algorithms are very interesting because they can simulate a lot of physical systems [3], and can be used for universal quantum computation [7].
In this paper we want to introduce the concept of semiclassical walk, which is a type algorithm that combines classical and quantum dynamics. The idea of mixing both dynamics is not new. In [8] it was introduced the quantum stochastic walk, a parameterized walk driven by non-unitary evolution that interpolates between the quantum and the classical dynamics. Another idea is measuring the position of the walker at regular intervals of time, and let the system evolve with the unitary quantum evolution between the measurements. This algorithm was introduced in [9] using a quantum walk in continuous time, and it was called measurement-induced quantum walk. We aim to generalize this algorithm with measurements to the context where the quantum evolution occurs in discrete time. As we will show in this work, in this scenario it is necessary to reset part of the system after the measurements, so that the system must be controlled by a classical computer beyond the usual quantum gates.
An important quantum walk is the one introduced by Szegedy in [10] as a generalization of the Grover algorithm [11]. In contrast to other approaches, this quantum walk can quantize a general Markov chain, so it can be used over arbitrary weighted graphs. It has been shown to be useful for problems of optimization [12][13][14][15], classification [16][17][18], quantum search [3,19,20] and machine learning [21]. Moreover, there has been research in implementing this algorithm in quantum circuits [22]. Due to its potential applications, we have chosen this quantum walk as an interesting example for implementing the semiclassical walks. We expect this could give rise to novel algorithms in the future. This paper is structured as follows. In Section II we review the formulation of classical and quantum walks, to later introduce the semiclassical walks in discrete time.
In Section III we focus on the semiclassical walks built from Szegedy's quantum walk. In Section IV we solve analytically the problem for 1D cycles and show results in some examples. In section V we simulate the semiclassical walks in a generic weighted graph, showing how this approach can break the symmetry of the graph. In Section VI we compare our results with the previous approach in continuous time. In section VII we show experimental results of semiclassical walks in a real quantum computer. Finally, we summarize and conclude in Section VIII.

II. SEMICLASSICAL WALK FORMULATION
In this section we are going to review the formulation of classical and quantum walks in discrete time, to later join them together to build up the semiclassical walk.

A. Classical Walk
The classical random walk occurs in the nodes of a graph. From a stochastic point of view, at each time step the walker is in only one node of the graph, and arXiv:2303.18202v2 [quant-ph] 24 Jul 2023 can jump to any other node, including the same node, with some probabilities. In Figure 1(a) it is shown an example of classical walk in a graph with three nodes. At the initial time t = 0 the walker is at node 2. At the first time step, the walker decides stochastically to jump to node 1. At the second time step it remains at node 1, and at the third time step it jumps to node 0. Since this process is stochastic, each time we repeat the random walk the trajectory followed by the walker is different. Averaging over the different trajectories we could obtain a probability distribution for the walker being at each node at each time step.
If we knew beforehand the probability that the walker jumps from one node to any other, then we could simulate deterministically the probability distribution of the walker being at each node. Let us define the classical transition matrix of a graph G, whose elements G ji are the probabilities of the walker jumping from node i to node j. This matrix is column-stochastic by definition, so that all the columns add up to one. Thus where N is the number of nodes in the graph. In this paper we count the nodes of the network, and therefore the matrix indexes, from 0 to N −1. Let p(t) be a column vector whose elements are the probabilities of the walker being at each node at time t. Then, given an initial probability distribution p(0), the classical walk can be simulated deterministically as Both points of view for the classical walk have applications depending on whether we want to obtain a specific position of the walker or the probability distribution. For example, the stochastic simulation is used for optimization algorithms like simulated annealing with Metropolis-Hastings, where it is wanted to obtain a single node as an optimal solution [23][24][25]. The search space can be so big that it is unfeasible to calculate the entire transition matrix. Thus, only the probabilities needed at each time step are calculated, reducing the computational cost of the algorithm. Other example is the PageRank algorithm, where the objective is the limiting probability distribution of the walker for classifying the nodes of the graph [26][27][28][29].

B. Quantum Walk
A quantum walk is a quantization of a classical walk. In this case, the walker can be in a superposition of the nodes of the graph, so that the position at each time step is represented by a quantum state |ψ(t) . The evolution of the system is given by a unitary matrix U , so that Let us define the computational basis as the one formed by the vectors |i , with i = 0, 1, ..., N − 1 representing the nodes of the graph. Then, the probability that the quantum walker can be measured at each node at time step t is: An example of a quantum walk in a graph with three nodes is shown in Figure 1(b). The walker start in a quantum state that represents node 2, it performs three time steps of the walk, being in a superposition of all nodes, and finally we measure the position obtaining node 1.
If we knew the unitary matrix U , then we could simulate deterministically the quantum walk in a classical computer, obtaining the probability distribution at each time step. This would be equivalent to the deterministic point of view of the classical walk. However, in some cases it is very costly to simulate the quantum walk, so that it is thought to be performed in quantum hardware instead. In this real scenario, after measuring the quantum state collapses to a state of the computational basis with a certain probability, being analog to the stochastic simulation of the classical walk. This is useful for example in the case of the quantum Metropolis algorithm [12][13][14][15]. If we wanted the probability distribution we would have to repeat the walk several times and average the results. Moreover, since the state collapses after the measurement, we cannot measure at intermediate steps of the walk and resume it. If we wanted the probability distribution at each time step we would have to perform a different quantum walk for each final time. This is for example what is done in the quantum version of the PageRank algorithm [16][17][18].

C. Semiclassical Walk
As we have mentioned above, if we measure the position of the quantum walker at a certain time, the state collapses so that the coherence of the quantum state is broken. We wonder what happens if we resume the quantum evolution after the measurement. As we will see, this new walk can be expressed as a classical walk with a different transition matrix. Let us define the following quantities: -t q : Quantum time [30]. It is the number of times we apply the unitary evolution U between measurements.
-t c : Classical time. It is the number of times we apply the quantum evolution U tq and measure the position of the walker.
Let us define the states |φ i as proxies for the positions i of the graph. Thus, if the walker is at node i at each classical time t c , then we prepare the state |φ i to per- Figure 1. Examples of trajectories followed by a particle in the different types of walks in a graph with 3 nodes. Blue color represents classical information whereas red color represents quantum information. a) Classical walk. The particle is in a particular node at each time step, and it jumps to other node with a certain probability. b) Quantum walk. The walker can be in a superposition of the nodes at each time step, and it is represented by a quantum state. In the end of the quantum walk the position is measured so that the walker collapses to a particular state with a certain probability. c) Semiclassical walk. At each classical step the walker is in a particular classical position. For each of these steps, the proxy quantum state is prepared and it is performed the quantum evolution tq times. After that, the position is measured obtaining a new classical position. d) Representation of the semiclassical trajectory in c) as a classical walk. Purples arrows indicate that the evolution is affected by both classical and quantum dynamics.
form the quantum evolution U t q times. An example is shown in Figure 1(c). There, the walker start at node 2. We prepare the quantum proxy state |φ 2 and perform the quantum evolution t q times. After measuring the position we obtain that it is at node 1. This corresponds to the first classical step t c = 1. For the second classical step t c = 2, we prepare the quantum proxy |φ 1 , perform the quantum evolution t q times, and measure, obtaining that the walker is at node 0. If we treat the quantum evolution as a black box and we only deal with the positions after each measurement, then we can treat the walk as a classical walk as shown in Figure 1(d). Thus, we only see that the walker starts at node 2, jumps to node 1, and after that it jumps to node 0.
As in the classical walk, a particular trajectory of the walker is obtained with a certain probability each time we run the algorithm. If we knew the probability of measuring each node after the quantum evolution starting with the proxy state |φ i , then we could define a transition matrix and simulate the walk in a similar way as equation (2). Thus, let us define the semiclassical transition matrix for a semiclassical walk as G (tq) , whose elements are G (tq) Note that there is a different semiclassical matrix for each value of t q , that is, there is a different semiclassical walk for each number of times we perform the quantum unitary evolution U between measurements. Thus, we actually have a family of semiclassical walks. The quantum time t q is actually a parameter that defines a particular semiclassical walk in the family, whereas the classical time t c is the actual evolution time, since we would only deal with the particle position at each classical step, and not at intermediary steps of the quantum evolution. Finally, we have to define how to construct the proxy states |φ i . A priori they could be exactly the same as the computational basis states |i , so that when we measure the position of the system, it collapses to the proxy state and it is ready for the next quantum evolution. That would be true if the Hilbert space where the quantum evolution takes place were the span of the states |i . For a quantum walk in continuous time this is true, and this is how the measurement-induced quantum walk studied in [9] is performed. However, for discrete time quantum walks the space have to be extended with an auxiliary register, usually called coin register, that tells the possible jumps of the quantum walker at each position. This prevents us from constructing a semiclassical walk only measuring the position state. Suppose we start at node 3, with the coin register in the state |c . The total wave function would be Now, suppose we evolve the system with the unitary U t q times and measure it, obtaining again node 3. Then the system would collapse to the following quantum state: In general, the coin state after the projection is not the same as in the initial state, even if we measured the same initial node. Since the probabilities of measuring each node after the quantum evolution depends not only on the initial position but also on the initial coin state, then the next quantum evolution would not provide the same probabilities. Thus, the process would not be Markovian, since the state at t c = 2, would depend on the state of the coin at t c = 1, which in turn depends on the state at t c = 0.
To overcome this issue we propose a reset scheme, so that with the information of the position after the measurement, we delete the information of the coin register and reprepare it in the initial coin state. In other words, we chose the proxy states as where c i is a coin state that can be different for each node in the network. Thus, after the measurement, we prepare the proxy |φ i using only the information of the position register, without taking into account the coin register. In general, the coin states in the proxies can be chosen arbitrarily, giving rise to different semiclassical walk families. However, for Szegedy's quantum walk we will see in the next section that there is a natural definition for them.

III. SZEGEDY SEMICLASSICAL WALK
Szegedy's quantum walk was proposed in [10] as a coinless quantization of Markov chains. In contrast to previous coined quantum walks, which were only suitable for unweighted graphs, Szegedy's quantum walk is able to quantize any classical transition matrix G.
In Szegedy's quantum walk the Hilbert space is the span of all the vectors representing the N × N directed edges of the duplicated graph, i.e., H = span{|i 1 |j 2 , i, j = 0, 1, ..., N − 1} = C N ⊗ C N , where the states with indexes 1 and 2 refer to the nodes on two copies of the original graph. The original formulation was based on two reflections, each around one of the two subspaces. However, there is an alternative formulation that generalizes the original one [31] and it is more commonly used. We define the vectors: which are a superposition of the vectors representing the edges outgoing from the i th vertex, whose coefficients are given by the square root of the i th column of the matrix G. From these vectors we can define a projector operator onto the subspace generated by them: The quantum walk operator U is defined as where S is the swap operator between the two quantum registers, i.e., Let us define the adjacency matrix A of a graph as a boolean matrix where A ij = 1 if and only if there is an edge between nodes i and j. When the transition matrix is obtained by normalizing the columns of the adjacency matrix the unitary operator U corresponds to the one of the coined Grover quantum walk [11,31]. Thus, the Szegedy's quantum walk can be understood as a coined quantum walk where the first register encodes the position in the graph, and the second register encodes the coin state. The original unitary operator formulated by Szegedy would be recovered taking the square of U , i.e. it would be U 2 .
In order to formulate the semiclassical walk from Szegedy's quantum walk we can use the set of states |ψ i as the proxy states in (8). An example of implementation of a semiclassical Szegedy's walk is shown in Figure  2(a). Let us denote x tc as the position at classical time step t c . Thus, we start at node x 0 . We prepare the proxy |ψ x0 and perform the quantum evolution, parameterized by the quantum time t q . After measuring the first register the system collapses to a particular node x 1 in the first register, and we do not worry about the state of the second register. We use the measured information about the node to reset the system and prepare the new proxy for the node we have just measured, |ψ x1 . This process is then repeated the number of classical steps as desired. We call this a semiclassical walk of class I since we are measuring in the first register Although it is common to measure the first register, there are other applications where the second register is measured instead to obtain the information about the nodes. An example is the quantum PageRank algorithm represented by xt c . The classical information is used to prepare the corresponding proxy state, the quantum evolution is performed, and finally a new classical position is measured from the first register. b) Scheme of the semiclassical Szegedy's walk of class II. In this case, the second register is measured, and that information is used to prepare the new proxy state. [16][17][18]. Thus, we can define a semiclassical walk of class II by measuring in the second register. An implementation is shown in Figure 2(b). In this case the information of the nodes are obtained measuring the second register, but the proxies are prepared in the same form as before, as per equation 9.
Finally, we can simulate both classes of semiclassical walks as classical walks with a semiclassical transition matrix. Let us use a left-subscript in the semiclassical matrix to denote the class of the walk. Then, the semiclassical matrices are obtained as: From the semiclassical matrices we can formulate some theorems about the semiclassical Szegedy's walk.
Theorem 1: Classical limit I. The classical walk is recovered for the semiclassical walk of class I with a quantum time t q = 1, thus: Proof: We start calculating the quantum state that re-sults of applying the unitary evolution once.
since Π |ψ i = |ψ i , due that the space where Π projects is the subspace spanned by the states |ψ i . The swap operator swaps the states between both registers, so To obtain the semiclassical matrix 1 G (1) we take the inner product with the computational basis of the first register and take the squared modulus.
This theorem reinforces the idea that the set of states |ψ i is natural as proxies for the semiclassical walks, since the classical walk is obtained in the limit of only applying once the unitary evolution between measurements, which corresponds to a lack of a coherent quantum evolution. Theorem 2: Classical limit II. The classical walk is recovered for the semiclassical walk of class II with a quantum time t q = 2, thus: For a proof see Supplementary Material (SM) [32]. This theorem makes us think that when measuring the second register it is more natural to use the Szegedy's original quantum unitary evolution U 2 instead of U . This is indeed what is done in the quantum PageRank [16][17][18]. Theorem 3: Equivalence between semiclassical classes. The semiclassical walk of class I obtained with a quantum time t q is the same as the one of class II obtained with a quantum time t q + 1: For a proof see SM [32]. Due to this theorem, in the following we will only regard to the semiclassical walks of class I, since we are dealing with the general single operator U in this work. However, for other scenarios where the evolution were performed with U 2 , both classes would not be equivalent. There would not be equivalence either if the operator were modified with oracles, as done for quantum search [19,20], or modified with arbitrary phase rotations [18].

IV. SZEGEDY SEMICLASSICAL WALK ON 1D CYCLES
Once we have defined the semiclassical Szegedy's walk, let us see some examples in 1D lattices. We are going to analytically solve the problem for the infinite line, and after that put cyclic boundary conditions to obtain the semiclassical walks on 1D cycles.
The classical matrix of the walk is given by so that a walker at node i can jump to either node i + 1 or i − 1 with a 50% of probability for both cases. The proxy states in the Szegedy's semiclassical walk are We can define a set of orthogonal states to these proxy states as follows: With these sets we can calculate easily the action of the unitary operator U over the set of states |i 1 |i ± 1 2 .
These states can be expressed as Since the states ψ ⊥ i are perpendicular to all states |ψ i , they are in the kernel of the projector, so Π ψ ⊥ i = 0. Using the expressions (23) and (24), the reflection part of the unitary operator yields Finally, we apply the swap between the two registers, obtaining the action of U : With (29) and (30) we can calculate the quantum evolution of the proxy states: and for a general number t q of quantum steps: We see then that the quantum walk starting from a single node moves apart from that node in a symmetric form. The walker jumps t q times from the starting node i, reaching nodes ±t q with a probability of 50%.
If we impose cyclic boundary conditions, then we have the identification −N = 0 = N , and the same for each two integers with a difference of N . Then, there are two interesting cases. The first one is when N is even and t q = N/2. For the sake of simplicity, let us see the effect over the state |ψ 0 in a graph with N = 6, so t q = 3 and where we have used the boundary conditions to identify −3 with 3 and −2 with 4. In this case the walker reach the same node from both sides, so the probability of measuring it is of 100%. The second case is when t q = N for  any value of N . In that case: so the walker start at the same point with certainty. Thus, the Szegedy's quantum walk has a period of N over the proxy states |ψ i . This is a great difference with the Hadamard coined quantum walk in 1D cycles, which is only periodic for a few values of N [3]. Finally, from (32) we can calculate the semiclassical matrices using (13) for the semiclassical family of class I: This is equivalent to a classical walk where each node i connects only to nodes i ± t q . Due to the periodicity of U over the proxy states, the semiclassical family will also have a periodicity in the quantum time, thus so there will be at most N different semiclassical walks. Since a classical walk occurs in a graph where the edges encode the probabilities of the walker jumping from one node to another, we can also represent the semiclassical walk family as a set of weighted graphs, denoted as semi-  classical graphs. In Figure 3 it is shown an example of the semiclassical graphs for the cycle with N = 6 nodes. For the first quantum time, t q = 1, we obtain the same graph than in the classical walk, so each node links to its immediate neighbors. The same result is obtained for  t q = 5. However, for other values of the quantum time we obtain genuine walks. For t q = 2 and t q = 4 each node connects to the second nearest neighbors, so the graphs breaks into triangles. Thus, if a particle start at node 0 it will perform a walk equivalent to a classical one in the triangle formed by nodes 0, 2 and 4. For t q = 3 each node links only to the opposite node in the graph, breaking the graph into lines of 2 nodes. Finally, for t q = 6 each node links only to itself with a loop, so the graphs breaks into single nodes. This would be equivalent to t q = 0, which is not actually a walk since there is not quantum evolution, so that the transition matrix is just the identity. For a larger value of the quantum time the sequence of graphs is repeated due to the periodicity of N = 6. The breaking in the connectivity of the graph is due to a degeneration of the eigenvalue 1 of the semiclassical matrix, which agrees with the results of the continuous quantum time version in [9] where the same cycle with six nodes was also broken for concrete values of the quantum time.
We have seen that a priori we could have N different semiclassical graphs. Nevertheless, here there are some graphs inside a period that are repeated. This is due to the fact that the semiclassical walks comes from the projection of quantum states so that different quantum states can yield the same position after measurement. As an example, note that the quantum states after the evolution from |ψ 0 are not the same for t q = 2 and t q = 4: Nevertheless, when the first register is measured, in both cases there is a 50% of probability for measuring node 2 or node 4, giving rise to the same semiclassical walk. To see better how the semiclassical matrices between different quantum times are related, in Figure 4 it is shown the oscillation of the semiclassical matrices 1 G (tq) with respect to the quantum time, where we can see that there are only 4 different semiclassical walks in the family. In the same figure it is shown the period of the unitary operator U , so we effectively see that there are six different operators U tq .
The number of different semiclassical walks depend on how many jumps the walker makes between the measurements. The number of jumps is just t q , and since it jumps in both directions, due to the cyclic boundary conditions we would have in general that the number of different graphs is # graphs = N/2 + 1.
Furthermore, the type of subgraphs that the classical graph can be broken into depends on how the number of nodes N can be factorized. For N = 6 we have 6 = 2 × 3 = 1 × 6, so we can have one hexagon, two triangles, three lines or six separate nodes.
As another example, in Figure 5 it is shown the semiclassical graphs for the cycle with N = 7 nodes. Since N is prime, in this case the graph cannot be broken in more than single nodes, although we can also have different graphs. For t q = 1 we recover the classical walk as expected, and the same for t q = 6. For t q = 2 and t q = 5 node 0 connects with nodes 2 and 5. But node 2 connects to 4, 4 to 6, 6 to 1, 1 to 3, 3 to 5, and 5 to node 0 again. So the graph is not broken. In this case it is again as a classical walk on the cycle with seven nodes, but the nodes are permuted. If we unroll the graph, it is similar to having a cycle formed by the chain of nodes 0 − 2 − 4 − 6 − 1 − 3 − 5. For t q = 3 and t q = 4 something similar happens, but with a different order of the nodes. Finally, for t q = N = 7 the graph is broken into single nodes, closing a period in the quantum time. We can check that relation (39) holds true, having 4 different semiclassical walks in this case.
In Figure 6 it is shown the periodicity of the semiclassical matrices and the quantum evolution operator U with the quantum time. It is clearly seen that the period of the semiclassical walks is N = 7, having only 4 different semiclassical matrices. However, in this case the period of the unitary operator is 14 instead of 7. This is due to that despite U having a period of N when it acts over the set of states |ψ i , this set only generates a N dimensional subspace of the entire N 2 dimensional Hilbert space. Since U |ψ i = S |ψ i , U also has a period of N over the set of the swapped states S |ψ i . Let us define: as the space generated by all the proxy states and their swapped states. Any vector |a in the orthogonal complement of I U is perpendicular to both |ψ i and S |ψ i . Thus, Π |a = 0 and the first application of U yields U |a = −S |a . Since |a is perpendicular to the states S |ψ i , then S |a is perpendicular to the states |ψ i and ΠS |a = 0. Thus, a second application of U yields: since S 2 = 1, so the period of U over I ⊥ U is just 2. The total period of the unitary U will be the least common multiple of the periods in both subspaces. Thus, for N even the period is N , whereas for N odd the period is 2N .  Figure 6. Periodicity of the semiclassical matrices and the unitary evolution for the cycle with N = 7 nodes. At each quantum time it is represented the minimum value of tq for which there is a matrix that is equal. For example, for tq = 10 the semiclassical matrix is equal to the one at tq = 3. However, the unitary operator is not still repeated, so that the equivalent quantum time is also tq = 10. Time tq = 0 is not an actual walk, but is used to represent that the matrix is equal to the identity.
We have shown only the results for N = 6 and N = 7 nodes. More results on different 1D cycles can be found in SM [32].

V. INHOMOGENEITY-DRIVEN SYMMETRY BREAKING
Let us introduce the following two concepts: -Symmetric graph: it is a weighted graph whose transition matrix is symmetric, meaning that between each pair of nodes the probability for going from one to the other is the same in both directions. If G is the transition matrix, then G = G T .
-Homogeneous graph: it is a weighted graph whose transition matrix elements only depend on the relative  Figure 7. a) Asymmetric and homogeneous graph. Between each pair of nodes the weights can be different in both directions, so it is asymmetric. However, all nodes have the same connectivity pattern, with weights that only depend on the relative distance between the nodes. b) Symmetric and inhomogeneous graph. Between each pair of nodes the weights are the same in both directions, so it is symmetric. However, each node has a different connectivity pattern, so it is inhomogeneous. The graphs have been plotted using the python library NetworkX [33].
position of the nodes. Thus, all nodes have the same connectivity pattern and the same weights in their links.
In Figure 7(a) it is shown an instance of asymmetric and homogeneous graph. On one hand, the transition matrix is not symmetric since the probability for going from node 0 to node 1 is bigger than from node 1 to node 0. On the other hand, each node has the same behavior, meaning that the weights of their links depend only on the relative distance to the other nodes. In this case, each node i connects with nodes i ± 1 and i + 3, and the weights are the same for each node i. Thus, the graph is homogeneous.
In the examples of 1D cycles all the semiclassical graphs are symmetric. This could be due to the fact that the classical graphs were also symmetric. However, they were also homogeneous. So we wonder what happens when the classical graph is symmetric but inhomogeneous. With that purpose, we have built the graph shown in Figure 7(b). It can be seen that the weights between each pair of nodes have the same intensity, so the transition matrix is symmetric. Nevertheless, each node has different connectivity patterns. For example, node 3 connects to four nodes, whereas node 0 only connects to one node and itself with a loop. Moreover, nodes 0, 1 and 2 have also different weights in their links with node 3 and the self-loop.
We have simulated the semiclassical walks of the inhomogeneous graph in Figure 7(b), and the first six semiclassical graphs are shown in Figure 8. For the first quantum time, t q = 1, we obtain the same as the classical graph, which is symmetric. However, for any other quantum time we observe that the symmetry has been broken. For example, for the graph with t q = 2 note that the weight in the edge that goes from node 6 to 5 is stronger than the weight from node 5 to 6. Moreover, since this is a more general case than with 1D cycles, there is not a periodicity in the semiclassical family. We have made simulations with other homogeneous symmetric graphs constructed at random finding that the symmetry is never broken, so we can conclude that the inhomogeneity is the cause of the symmetry breaking.
The fact that the semiclassical transition matrices are not symmetric anymore opens an application of the semiclassical walk to the problem of ranking nodes. Let us formulate the following theorems.
Theorem 4: Uniform distribution for symmetric walks. For a symmetric transition matrix G = G T , the uniform distribution is an eigenvector with eigenvalue 1, i.e., it is at equilibrium [34].
Proof: Let G be the transition matrix, so that G ij = G ji , and let v be the uniform probability vector, so that v i = 1/N ∀ i. We apply the transition matrix to this vector: where we have used that G is column-stochastic so that each column adds up to one (1).  The weights of the edges are represented by the colormap. Moreover, to ease the visualization, the width of the edges are proportional to their weights. It can be seen how the symmetry of the graph is broken from tq = 2 onwards. The graphs have been plotted using the python library NetworkX [33].
|ψ i states, denoted as is an eigenvector of U with eigenvalue 1. Proof: Since Ψ (0) is a linear combination of the |ψ i states, the action of U over it is just S. So, using the fact that G ij = G ji , The limiting distribution of the classical walk is used in the PageRank algorithm to rank the nodes of the graph [26][27][28][29]. However, for a symmetric transition matrix, in the case that the walk converges, it will converge to the uniform distribution, so no useful information can be ob-tained. In the case of the quantum PageRank, it is used the Szegedy's quantum walk starting from the uniform state Ψ (0) in (43), and the distributions for each time step are averaged since the unitary character of the evolution makes it oscillate instead of converge [16,17]. However, for a symmetric classical transition matrix the state Ψ (0) is an eigenvector, so the uniform distribution is obtained again. Thus, neither the classical nor quantum PageRank algorithms can rank successfully the nodes of a symmetric graph.
Thanks to the symmetry breaking in the semiclassical graphs, the semiclassical walks converge to distributions different to the uniform one. The limiting distributions for the six semiclassical graphs of Figure 8 are shown in Figure 9(a). We now obtain different rankings for the nodes, but they are different for each semiclassical graph. To obtain an objective classification we average the distributions over the different quantum times, in a similar manner as the quantum PageRank does. For a Szegedy quantum walk it has been proved that averaging for a long enough time, the averaged distribution converges [35]. For the semiclassical walk, the same happens as can be seen in Figure 9(b). Finally, in Figure 9(c) it is shown the averaged distribution, compared with the uniform ones using the classical and quantum PageRank algorithms over the classical transition matrix G.
The final question is how this ranking relates to the structure of the network. Node 3 is the most important being the node with more connections. The follow-  Figure 9. Limiting distributions for the first six semiclassical walks of the graph in Figure 7(b). b) Average of the limiting distributions vs. the quantum time used to average. c) Averaged limiting distribution of the semiclassical walks. It is compared with the classical and quantum PageRanks obtained from the classical graph, which yield a uniform distribution.
ing most important is node 4, which is the other central node. So it is as if the connectivity of the nodes plays a major role over the ranking. Furthermore, note that the differences in weights play also a role. Nodes 0, 1, and 2, all linking to node 3 and having a self-loop, are not degenerate due to the differences in the values of the weights. Node 1 has the strongest weights in the edges with node 3, and thus is the most important out of the three.

VI. COMPARISON WITH THE CONTINUOUS TIME APPROACH
The measurement-induced quantum walk [9] can be understood as a semiclassical walk where the quantum time is a continuous variable. The Hilbert space is the span of the computational basis |i . Thus, in contrast with our approach, there is no need to reset any coin register after the measurement, since the system collapses to a suitable state for the next quantum evolution procedure. Thus, the transition matrices are obtained as: where U (t q ) is the unitary operator that performs the quantum evolution during a quantum time t q . Note that despite the quantum time being continuous, the new transition matrix G (tq) represents a walk in discrete classical time as in our approach.
In contrast to Szegedy's quantum walk, the unitary operator is obtained from the exponentiation of an hermitian operator H related to the adjacency matrix of a graph, so that U (t q ) = exp(−iHt q ). Thus, whereas the Szegedy's quantum walk can be performed over any generic graph, in the continuous quantum walk there is the restriction that the graph must be undirected, so that the adjacency matrix is symmetric. Furthermore, since H T = H, then the unitary matrix is also symmetric: and thus the transition matrices G (tq) are also symmetric. This means that the uniform distribution is always a stationary state of the semiclassical walk. As the authors of [9] point out, in the case that the eigenvalue 1 is not degenerate, it is as if the repeated measurements drove the system to a high temperature classical limit [36]. This is not the case for our discrete-time semiclassical walks since we are not only measuring repeatedly, but also resetting to the desired proxy states using the classical information from the measurement. Thus, the reset scheme prevents this behavior.
Regarding the results in 1D cycles, the measurementinduced quantum walk is also able to break the graph into subgraphs. However, this breaking occurs for exceptional values of the quantum time, so they are very infrequent inside the family of semiclassical walks. Moreover, due to the continuous behavior of the quantum walk, except in the cases that the graph is broken, all the transition matrices are fully connected, meaning that there is a nonnull probability for jumping from one node to any other or itself. Thus, the equivalent classical walk encoded by the hermitian matrix H is never recovered in contrast to our discrete quantum time version.

VII. EXPERIMENTAL SEMICLASSICAL WALK ON IBM-Q
In order to show that the semiclassical walk functions in a real quantum processor unit (QPU), we have performed an experiment in the the platform IBM Quantum [38], with the processor ibmq-manila. This platform has been previously used to demonstrate experimentally other quantum walks such as the staggered quantum walk [39,40], and even the measurement-induced quantum walk [41]. Since current QPUs are very error prone, we have chosen a graph with only two nodes, where the Szegedy's quantum walk requires only two qubits, one per register of the state. The decoherence effects of quantum computers make the system end up in a uniform distribution. Thus, we have taken a weighted asymmetric graph so that the equilibrium distribution is different to the uniform one. The classical transition matrix of this graphs is In our experiment we wanted to obtain the probability distribution p(t) of the walker being at each node for each classical time t c . To do that, we must run the semiclas-sical walk several times to sample from the probability distributions, and then estimate the probabilities dividing the number of times the walker ends up in a node by the number of times the circuit has been run. Moreover, equation (2) tells us that we can start from a non-trivial probability distribution p(0). This can be achieved by initializing the circuit each time with a state taken at random from p(0). To demonstrate that this actually works, we have taken the initial probability distribution as p(0) = (0.8, 0.2) T .
The general quantum circuit to perform the semiclassical walks is shown in Figure 10(a). The circuit always starts with both qubits in the state |0 . To randomly sample the initial distribution for taking an initial node, we apply a R Y (0.927) gate, so that the first register is converted to √ 0.8 |0 + √ 0.2 |1 . Thus, after measuring it, the first register is initialized to |0 with an 80% of probability, and to |1 with a 20% of probability. The result of this measurement corresponds to the position of the walker at t c = 0. For any other classical time, we repeat the following block. First, the second register is reset to |0 , which do not affect to the first register since they are not entangled due to the previous measurement. After that, we prepare the proxy state conditioned by the information of the first register, using controlled R Y (θ i ) gates. We know that where θ 0 = 2.5 and θ 1 = 2.21. Thus, when the first register is in |0 the proxy state |ψ 0 is prepared, whereas when it is in |1 the state |ψ 1 is prepared instead. Once the proxy state is prepared, we apply the quantum evolution U the number of quantum times t q required, where the circuit for the unitary U is represented in Theoretical Simulator Experimental (f) Figure 11. a)-c) Semiclassical graphs for the classical graph given by (47) for a) tq = 1, b) tq = 2, c) tq = 3. The weights of the edges are represented by the colormap and also over the edges. The graphs have been plotted using the python library NetworkX [33]. d)-f) Experimental results for the semiclassical walks for d) tq = 1, e) tq = 2, f) tq = 3. Since there are only two nodes, the probability distribution can be represented by the probability of measuring node 1. The error bars are computed with the standard deviations between ten different experiments. The results are compared with the theoretical results and the ones from the QASM simulator.
10(b). Finally, we measure the state in the first register obtaining the position of the walker for that classical time. Note that we are using quantum controlled gates to reset the proxy states, which means that we would need one gate for each of the N nodes in the graph. This would be very inefficient for complex graphs, so it would be far better to use the classical information of the measurement to tell the circuit what proxy state to prepare directly. Despite the fact that classically controlled gates are theoretically possible to implement, current QPUs of IBM do not allow them. We have performed the experiments for the first three semiclassical walks of the family, t q = 1, 2, 3, whose semiclassical graphs are shown in Figures 11(a)-11(c). In each case, we have performed ten independent experiments and averaged the results. For each experiment the probability distributions were obtained sampling the circuit 20000 times. The results are shown in Figures 11(d)-11(f). On one hand, in order to check the accuracy of the results, we can simulate the same circuit in the QASM simulator of Qiskit [37]. This is a stochastic simulator that simulates a fault-tolerant quantum computer, also sampling a finite number of times to estimate the probability distributions. In our case we sample 20000 times the circuits as in the real experiments. On the other hand, we can also calculate the theoretical probability distributions using the semiclassical matrices and equa-tion 2. In all cases the simulated circuits yield the same results as the theoretical formulation, verifying that the implemented circuit of Figure 10(a) works.
The first semiclassical walk, for t q = 1, corresponds actually to the classical walk. We can see that the initial probability of the walker being at node 1 is 0.2. After the first step this probability rises to 0.88. Then it goes down to 0.82 and converges. The experimental results agree with the theoretical behavior. However, due to the errors of the real QPU it converges to approximately 0.77, so the relative error is of a 6%. For the second semiclassical walk, the graph is roughly symmetric, so it is not surprising that the limiting distribution is almost uniform. In this case the theoretical result converges to 0.51 whereas the experimental one to 0.54, so there is an approximate error again of a 6%. Finally, for the third semiclassical walk the theoretical result converges to 0.89 whereas the experimental one to 0.83, with an error of a 7%. Taking into account that current QPU are still very error prone, and we have not used any error mitigation nor error correction technique, our experimental results have an incredibly well agreement with the theoretical ones.

VIII. CONCLUSIONS
We have reviewed the formulation of classical and quantum walks aiming at introducing the family of semiclassical walks. Each semiclassical walk can be seen as a classical walk where the transition matrix encodes a quantum evolution, and thus the dynamics is a mixture of classical and quantum evolution. Moreover, to be able to perform the semiclassical walk from quantum walks in discrete time, we have introduced the reset scheme and the proxy states, which encode the position of the walker in a graph.
We have formulated the semiclassical walk from the Szegedy's quantum walk, which is a walk in discrete time that is suitable for quantizing any classical transition matrix. The quantum states for Szegedy's quantum walk are formed by two registers, and each of both can yield information about the position of the walker. Thus, we have defined two classes of semiclassical Szegedy's walks depending on which register we use. Furthermore, we have proved that this two classes of semiclassical walks include the original classical walk, and there is an equivalence between them.
The semiclassical Szegedy's walks can be solved analytically for 1D lattices, such as cycles. We have obtained the semiclassical transition matrices for this case, and we have observed that for certain members of the semiclassical family the walk occurs in a broken graph. Moreover, there are some cases where the cycle is not broken, but the nodes are permuted. This results agree with the measurement-induced quantum walk, which is similar to the semiclassical walk but with a continuous quantum time, where the authors also observed that the 1D cycles could be broken.
Szegedy's quantum walk is suitable for any transition matrix, so it can be performed even in asymmetric graphs. Furthermore, we have observed that even if the classical graph is symmetric but not all nodes have the same behavior, i.e., it is not homogeneous, the symmetry of the transition matrix is broken in the semiclassical walk family. This can be useful for ranking nodes in graphs with symmetric transition matrices, where both classical and quantum PageRanks yield the uniform distribution. Due to the asymmetry in the semiclassical walks, these can converge to non-trivial distributions that can yield information about the graph. These results contrast with the ones of the continuous quantum time version, where all the semiclassical matrices are symmetric.
To demonstrate that the semiclassical walks can be implemented in quantum computers, we have performed some experiments in the platform IBM Quantum using a real QPU. We have used an asymmetric graph with 2 nodes so that the limiting distributions are different to the trivial uniform one. We have done the experiments for the first three members of the semiclassical family, which include the classical walk. The results that we have obtained agree incredibly well with the theoretical ones, with a maximum error of a 7% due to the errors of current QPUs.
In the future, it would be interesting to apply these semiclassical Szegedy's walks to more complex graphs, in applications like optimization, quantum search or machine learning, where Szegedy's quantum walk has shown to have a good performance. Moreover, in contrast to quantum walks, the position of the walker can be measured at intermediate time steps. This could be crucial in algorithms that require knowing the position not only at the end of the walk.