Click or drag to resize
Gate Class
A quantum gate.
Inheritance Hierarchy
SystemObject
  Microsoft.Research.LiquidGate

Namespace: Microsoft.Research.Liquid
Assembly: Liquid1 (in Liquid1.dll) Version: 1.0.5981.24943 (1.0.*)
Syntax
F#
[<SerializableAttribute>]
type Gate =  class end

The Gate type exposes the following members.

Constructors
  NameDescription
Public methodGate
Creates a new gate from scratch.
Top
Properties
  NameDescription
Public propertyArity
Get arity of the gate (based on Qubits or Mat/Kraus size).
Public propertyStatic memberCacheDisable
Whether or not the gate cache is disabled. The cache is used if this property is false. The cache should be disabled if gates are being built in parallel.
Public propertyDraw
The drawing instructions for this gate.
Public propertyHelp
The help string for this gate.
Public propertyKraus
The Kraus operator matrix list for this gate (if op type is Channel). If the gate is not a channel, this will be an empty list.
Public propertyMat
The unitary matrix for this gate. If the gate is not defined by a single unitary, this will be a 0x0 matrix.
Public propertyName
The name of this gate.
Public propertyOp
This gate's operation.
Public propertyParent
This gate's parent, if any.
Public propertyQubits
The arity of this gate; that is, the number of qubits the gate operates on.
Public propertyUser
The user info associated with this gate, if any.
Top
Methods
  NameDescription
Public methodAddControl
Creates a new gate by adding one or more control qubits to an existing unitary gate.
Public methodStatic memberBuild
Gets the definition of a gate, using the cache. If the gate is already in the cache, the cached definition is returned. Otherwise, a new gate will be created, added to the cache, and returned.
Public methodStatic memberCacheClear
Clears out the gate cache.
Public methodStatic memberCacheStats
Gets gate cache statistics.
Public methodDump
Dumps the full gate information to the consol and/or log.
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodNewMat
Makes a new gate based on this gate but with new unitary matrix.
Public methodOptimizeKraus
Optimze a Channel gate with Kraus operators (checks correctness and orders by magnitude)
Public methodRun
Run this gate. The details depend on the current value of Ket.Mode:
  • RunMode: Apply this gate operation to the supplied qubits.
  • GateMode: Stores this gate definition into the current Ket. This is for internal use.
  • CircMode: Compiles this gate into a Circuit. This is for internal use.
Public methodStatic memberShowMem(Int32, FSharpFuncUnit, String, FSharpOptionFSharpListCircuit, FSharpOptionBoolean, FSharpOptionBoolean)
Outputs memory and garbage collection statistics to the log and console.
Public methodStatic memberShowMem(Int32, String, FSharpOptionFSharpListCircuit, FSharpOptionBoolean, FSharpOptionBoolean)
Outputs memory and garbage collection statistics to the log and console.
Public methodToString
Returns a string representation of this gate, based on the gate's name, help string, and type.
(Overrides ObjectToString.)
Top
See Also