Click or drag to resize
Spin Class
Hamiltonian for spin systems, such as the Ising model or a spin glass.
Inheritance Hierarchy

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

The Spin type exposes the following members.

Constructors
Properties
  NameDescription
Public propertycurrentCirc
The last (grown) circuit that was run.
Public propertydecohereModel
The decoherence model for this Hamiltonian.
(Inherited from Hamiltonian.)
Public propertyKet
Gets the Ket vector associated with this Hamiltonian
(Inherited from Hamiltonian.)
Public propertylastAnneal
The last set of annealing coefficients that were applied.
Public propertylastRawCirc
The last (ungrown) circuit that was run.
Public propertyrunMode
The run mode. Note that setting this property will force a new circuit to be generated.
Public propertytime
The current simulation time. Note that setting this property will force a new circuit to be generated.
Public propertytrotterN
The Trotter number. Note that setting this property will force a new circuit to be generated.
Top
Methods
  NameDescription
Public methodCopy
Returns an instance of Spin with the same Hamiltonian parameters as this instance. Simulation parameters such as run time and Trotter number are not copied.
Public methodEnergyExpectation
Finds the expectation value of the Hamiltonian. That is, given a state vector |psi>, this method computes <psi|H|psi>.
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Public methodStatic memberFerro
Test adiabatic evolution with a ferro-magnetic chain
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodPeek
Peeks at the current Hamiltonian matrix. This is based on the most recently grown circuit.
Public methodPrep
Prepares the qubit state for a run. All qubits are resets and initialized to the ground state.
Public methodRun
Runs the simulation. This is a highly optimized implementation.
Public methodStep
Performs a single timestep of simulation.
Public methodStatic memberTest(String, Int32, Int32, FSharpListTupleInt32, Double, Int32, Spin, FSharpOptionBoolean, FSharpOptionFSharpListTupleFSharpFuncQubit, Unit, Double)
Executes a set of simulation runs for a spin Hamiltonian.
Public methodStatic memberTest(String, Int32, Int32, DictionaryInt32, Double, DictionaryTupleInt32, Int32, Double, FSharpListTupleInt32, Double, Double, Int32, FSharpOptionBoolean, FSharpOptionFSharpListTupleFSharpFuncQubit, Unit, Double)
Executes a set of simulation runs for a spin Hamiltonian.
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Top
See Also