Skip to content

Commit

Permalink
change docs
Browse files Browse the repository at this point in the history
  • Loading branch information
exAClior committed Oct 15, 2023
1 parent 8b1eb13 commit cf20e85
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 150 deletions.
4 changes: 2 additions & 2 deletions docs/make.jl
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,11 @@ using Documenter
using DocThemeIndigo

using ZXCalculus
using ZXCalculus: ZXW, ZW
using Multigraphs

indigo = DocThemeIndigo.install(ZXCalculus)
makedocs(;
modules = [ZXCalculus, ZXW, ZW],
modules = Module[ZXCalculus],
format=Documenter.HTML(;
# ...
# put your indigo css in assets
Expand All @@ -21,6 +20,7 @@ makedocs(;
],
repo = "https:/github.com/QuantumBFS/ZXCalculus.jl",
sitename = "ZXCalculus.jl",
warnonly=true,
)

deploydocs(repo = "github.com/QuantumBFS/ZXCalculus.jl.git")
147 changes: 0 additions & 147 deletions docs/src/api.md
Original file line number Diff line number Diff line change
@@ -1,148 +1 @@
# APIs

```@meta
CurrentModule = ZXCalculus
```

## ZX-diagrams

```@docs
ZXCalculus.ZXDiagram
ZXDiagram(nbit::Int)
ZXCalculus.ZXGraph
ZXCalculus.ZXGraph(::ZXDiagram)
ZXCalculus.ZXLayout
ZXCalculus.qubit_loc
spider_type(zxd::ZXDiagram{T, P}, v::T) where {T<:Integer, P}
ZXCalculus.phase(zxd::ZXDiagram{T, P}, v::T) where {T<:Integer, P}
Graphs.nv(zxd::ZXDiagram)
Graphs.ne(::ZXDiagram)
Graphs.neighbors(::ZXDiagram, v)
ZXCalculus.is_interior(zxg::ZXGraph{T, P}, v::T) where {T, P}
ZXCalculus.add_spider!
ZXCalculus.insert_spider!
ZXCalculus.rem_spiders!
ZXCalculus.rem_spider!
```

## Pushing gates
```@docs
ZXCalculus.push_gate!
ZXCalculus.pushfirst_gate!
```

## Simplification
```@docs
ZXCalculus.phase_teleportation
ZXCalculus.clifford_simplification
Rule{L} where L
ZXCalculus.simplify!
ZXCalculus.replace!
ZXCalculus.match
ZXCalculus.rewrite!
ZXCalculus.Match
```

## Circuit extraction
```@docs
ZXCalculus.circuit_extraction(zxg::ZXGraph{T, P}) where {T, P}
```

## ZXW-diagram
```@docs
ZXCalculus.ZXW.add_inout!
ZXCalculus.ZXW.substitute_variables!
ZXCalculus.biadjacency
ZXCalculus.ZXW.rem_spider!
ZXCalculus.continued_fraction
ZXCalculus.ZXW.symbol_vertices
ZXCalculus.ZXW.dagger
ZXCalculus.ZXW.add_spider!
ZXCalculus.tcount
ZXCalculus.Phase
ZXCalculus.round_phases!
ZXCalculus.gaussian_elimination
ZXCalculus.Scalar
ZXCalculus.ZXW.expval_circ!
Graphs.SimpleGraphs.rem_edge!
ZXCalculus.ZXW.parameter
ZXCalculus.ZXW.int_prep!
ZXCalculus.update_frontier!
ZXCalculus.ZXW.integrate!
ZXCalculus.set_column!
ZXCalculus.set_phase!
ZXCalculus.prev
ZXCalculus.ancilla_extraction
Graphs.SimpleGraphs.add_edge!
ZXCalculus.ZXW.stack_zxwd!
ZXCalculus.ZXW.get_outputs
ZXCalculus.scalar
ZXCalculus.get_inputs
ZXCalculus.ZW.get_inputs
ZXCalculus.column_loc
ZXCalculus.GEStep
ZXCalculus.ZXW.spider_type
ZXCalculus.ZXW.print_spider
ZXCalculus.ZXW.Parameter
ZXCalculus.ZXW.nqubits
ZXCalculus.set_qubit!
ZXCalculus.ZXW.insert_wtrig!
ZXCalculus.ZXW.concat!
ZXCalculus.ZXW.rem_spiders!
ZXCalculus.ZXW.insert_spider!
ZXCalculus.set_loc!
ZXCalculus.spiders
ZXCalculus.split_edge!
ZXCalculus.ZXW.import_edges!
ZXCalculus.get_outputs
ZXCalculus.ZXW.get_inputs
ZXCalculus.ZXW.import_non_in_out!
ZXCalculus.ZXW.set_phase!
ZXCalculus.ZXW.nout
```

# Planar Multigraph
```@docs
ZXCalculus.PlanarMultigraph
ZXCalculus.is_boundary
ZXCalculus.trace_face
ZXCalculus.new_edge
ZXCalculus.ϕ
ZXCalculus.nqubits
ZXCalculus.erase_facet!
ZXCalculus.create_face!
ZXCalculus.surrounding_half_edge
ZXCalculus.add_facet_to_boarder!
ZXCalculus.split_facet!
ZXCalculus.split_vertex!
ZXCalculus.add_vertex_and_facet_to_boarder!
ZXCalculus.create_edge!
ZXCalculus.join_facet!
ZXCalculus.create_vertex!
ZXCalculus.σ_inv
ZXCalculus.σ
ZXCalculus.make_hole!
ZXCalculus.gc_vertex!
ZXCalculus.HalfEdge
ZXCalculus.out_half_edge
ZXCalculus.n_conn_comp
ZXCalculus.join_vertex!
```

# ZW-diagrams
```@docs
ZXCalculus.ZW.ZWDiagram
ZXCalculus.ZW.insert_spider!
ZXCalculus.ZW.get_output_idx
ZXCalculus.ZW.nqubits
ZXCalculus.ZW.round_phases!
ZXCalculus.ZW.nout
ZXCalculus.ZW.get_input_idx
ZXCalculus.ZW.set_phase!
ZXCalculus.ZW.get_outputs
ZXCalculus.ZW.add_spider!
ZXCalculus.ZW.parameter
ZXCalculus.ZW.print_spider
ZXCalculus.ZW.spider_type
```

5 changes: 4 additions & 1 deletion docs/src/tutorials.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
# Tutorials
```@meta
CurrentModule= ZXCalculus.ZX
```

ZX-diagrams are the basic objects in ZX-calculus. In our implementation, each ZX-diagram consists of a multigraph and vertices information including the type of vertices and the phase of vertices. [`ZXDiagram`](@ref) is the data structure for representing
ZX-diagrams.
Expand All @@ -11,7 +14,7 @@ In each `ZXDiagram`, there is a `layout` for storing layout information for the

As we usually focus on quantum circuits, the recommended way to construct `ZXDiagram`s is by the following function.
```@docs
ZXDiagram(nbit::T) where T<:Integer
ZXDiagram(nbits::T) where T<:Integer
```
Then one can use `push_gate!` to push quantum gates at the end of a quantum circuit, or use `pushfirst_gate!` to push gates at the beginning of a quantum circuit.
```@docs
Expand Down

0 comments on commit cf20e85

Please sign in to comment.