ZXEdge#

class tqec.computation.ZXEdge(u, v, has_hadamard=False)[source]#

Bases: object

An edge connecting two neighboring nodes in the ZX graph.

Warning

The attributes u and v will be ordered to ensure the position of u is smaller than v.

Parameters:
u#

The first node of the edge. The position of u is guaranteed to be smaller than v.

Type:

tqec.computation.zx_graph.ZXNode

v#

The second node of the edge. The position of v is guaranteed to be greater than u.

Type:

tqec.computation.zx_graph.ZXNode

has_hadamard#

Whether the edge is a Hadamard edge. Default to False.

Type:

bool

Methods

__init__(u, v[, has_hadamard])

Attributes

direction

3D direction of the edge.

has_hadamard

u

v

Detailed methods

__init__(u, v, has_hadamard=False)#
Parameters:
Return type:

None