Degrees of freedom
QuantumLattices.DegreesOfFreedom.ˢᵗ — Constantconst ˢᵗ = ⁿᵈ = ʳᵈ = ᵗʰ = Ordinal(1)Constant ordinals.
QuantumLattices.DegreesOfFreedom.Boundary — TypeBoundary{Names}(values::AbstractVector{<:Number}, vectors::AbstractVector{<:AbstractVector{<:Number}}) where NamesBoundary twist of operators.
QuantumLattices.DegreesOfFreedom.Boundary — Method(bound::Boundary)(operator::Operator; origin::Union{AbstractVector, Nothing}=nothing) -> OperatorGet the boundary twisted operator.
QuantumLattices.DegreesOfFreedom.CompositeIndex — TypeCompositeIndex{I<:Index} <: OperatorIndexAbstract type of a composite index.
QuantumLattices.DegreesOfFreedom.CompositeInternal — TypeCompositeInternal{T<:OneAtLeast{SimpleInternal}, I<:OneOrMore{InternalIndex}} <: Internal{I}Abstract type of the composition (i.e., direct sum or direct product) of several simple internal spaces.
QuantumLattices.DegreesOfFreedom.CoordinatedIndex — TypeCoordinatedIndex{I<:Index, V<:SVector} <: CompositeIndex{I}Coordinated index, i.e., index with coordinates in the unitcell.
QuantumLattices.DegreesOfFreedom.CoordinatedIndex — MethodCoordinatedIndex(index::Index, rcoordinate, icoordinate)
CoordinatedIndex(index::Index; rcoordinate, icoordinate)Construct a coordinated index.
QuantumLattices.DegreesOfFreedom.Coupling — TypeCoupling{V, P<:Pattern} <: OperatorPack{V, P}Coupling among internal degrees of freedom at different or same lattice points.
QuantumLattices.DegreesOfFreedom.Coupling — MethodCoupling(index::Index, indexes::Index...)
Coupling(value::Number, index::Index, indexes::Index...)
Coupling(value::Number, indexes::OneAtLeast{Index})Construct a coupling with the input indexes as the pattern.
QuantumLattices.DegreesOfFreedom.Coupling — MethodCoupling(value, pattern::Pattern)
Coupling(pattern::Pattern)Construct a coupling.
QuantumLattices.DegreesOfFreedom.Coupling — MethodCoupling{F}(sites::Union{NTuple{N, Ordinal}, Colon}, fields::Union{NTuple{N}, Colon}...) where {N, F}
Coupling{F}(value::Number, sites::Union{NTuple{N, Ordinal}, Colon}, fields::Union{NTuple{N}, Colon}...) where {N, F}Construct a Coupling by a function that can construct an Index with the input sites and the fields of a kind of internal index.
QuantumLattices.DegreesOfFreedom.Coupling — MethodCoupling{I}(sites::Union{NTuple{N, Ordinal}, Colon}, fields::Union{NTuple{N}, Colon}...) where {N, I<:InternalIndex}
Coupling{I}(value::Number, sites::Union{NTuple{N, Ordinal}, Colon}, fields::Union{NTuple{N}, Colon}...) where {N, I<:InternalIndex}Construct a Coupling with the input sites and the fields of a kind of internal index.
QuantumLattices.DegreesOfFreedom.Hilbert — TypeHilbert{I<:Internal} <: CompositeDict{Int, I}Hilbert space at a lattice.
QuantumLattices.DegreesOfFreedom.Hilbert — MethodHilbert(internal::Internal, num::Integer)Construct a Hilbert space with all same internal spaces.
QuantumLattices.DegreesOfFreedom.Hilbert — MethodHilbert(internals::Internal...)
Hilbert(internals::OneAtLeast{Internal})
Hilbert(internals::AbstractVector{<:Internal})Construct a Hilbert space with the given internal spaces.
QuantumLattices.DegreesOfFreedom.Hilbert — MethodHilbert(ps::Pair...)
Hilbert(kv)Construct a Hilbert space the same way as an OrderedDict.
QuantumLattices.DegreesOfFreedom.Index — TypeIndex(site::Union{Int, Ordinal, Colon}, internal::InternalIndex)Index of a degree of freedom, which consist of the spatial part (i.e., the site index) and the internal part (i.e., the internal index).
QuantumLattices.DegreesOfFreedom.Index — MethodIndex(index::OperatorIndex)Get the Index part of an OperatorIndex.
QuantumLattices.DegreesOfFreedom.Internal — TypeInternal{I<:OneOrMore{InternalIndex}} <: VectorSpace{I}Internal space at a single point.
QuantumLattices.DegreesOfFreedom.InternalIndex — TypeInternalIndex <: OperatorIndexInternal index of an internal degree of freedom.
QuantumLattices.DegreesOfFreedom.InternalIndex — MethodInternalIndex(index::OperatorIndex)Get the InternalIndex part of an OperatorIndex.
QuantumLattices.DegreesOfFreedom.InternalProd — TypeInternalProd{T<:OneAtLeast{SimpleInternal}, I<:OneAtLeast{InternalIndex}} <: CompositeInternal{T, I}Direct product of several single internal spaces.
QuantumLattices.DegreesOfFreedom.InternalSum — TypeInternalSum{T<:OneAtLeast{SimpleInternal}, I<:InternalIndex} <: CompositeInternal{T, I}Direct sum of several single internal spaces.
QuantumLattices.DegreesOfFreedom.MatrixCoupling — TypeMatrixCoupling{I<:InternalIndex, S<:Union{Ordinal, Colon}, C<:OneAtLeast{MatrixCouplingComponent}, E<:Coupling} <: VectorSpace{E}Matrix coupling, i.e., a set of couplings whose coefficients are specified by matrices acting on separated internal spaces.
QuantumLattices.DegreesOfFreedom.MatrixCoupling — MethodMatrixCoupling{I}(sites::Union{NTuple{2, Ordinal}, NTuple{2, Colon}, Colon}, contents::MatrixCouplingComponent...) where {I<:InternalIndex}
MatrixCoupling{I}(sites::Union{NTuple{2, Ordinal}, NTuple{2, Colon}, Colon}, contents::OneAtLeast{MatrixCouplingComponent}) where {I<:InternalIndex}Construct a MatrixCoupling.
QuantumLattices.DegreesOfFreedom.MatrixCouplingComponent — TypeMatrixCouplingComponent{T₁, T₂, V<:AbstractVector{T₁}} <: VectorSpace{Tuple{T₁, T₁, T₂}}A component of a matrix coupling, i.e., a matrix acting on a separated internal space.
QuantumLattices.DegreesOfFreedom.MatrixCouplingProd — TypeMatrixCouplingProd{V<:Number, C<:OneAtLeast{MatrixCoupling}, E<:Coupling} <: VectorSpace{E}Product of matrix couplings together with an overall coefficient.
QuantumLattices.DegreesOfFreedom.MatrixCouplingProd — MethodMatrixCouplingProd(value::Number, contents::OneAtLeast{MatrixCoupling})
MatrixCouplingProd(content::MatrixCoupling, contents::MatrixCoupling...)
MatrixCouplingProd(value::Number, content::MatrixCoupling, contents::MatrixCoupling...)Construct a MatrixCouplingProd.
QuantumLattices.DegreesOfFreedom.MatrixCouplingSum — TypeMatrixCouplingSum{C<:MatrixCouplingProd, N, E<:Coupling} <: VectorSpace{E}Sum of the products of matrix couplings.
QuantumLattices.DegreesOfFreedom.MatrixCouplingSum — MethodMatrixCouplingSum(contents::OneAtLeast{Union{MatrixCoupling, MatrixCouplingProd}})
MatrixCouplingSum(content::Union{MatrixCoupling, MatrixCouplingProd}, contents::Union{MatrixCoupling, MatrixCouplingProd}...)Construct a MatrixCouplingSum.
QuantumLattices.DegreesOfFreedom.Metric — TypeMetric <: FunctionRules for measuring an operator index so that different operator indexes can be compared.
As a function, every instance should accept only one positional argument, i.e. the operator index to be measured.
QuantumLattices.DegreesOfFreedom.OperatorIndexToTuple — TypeOperatorIndexToTuple{Fields} <: MetricA rule that converts an operator index into a tuple based on the specified type parameter Fields.
Here, Fields must be a tuple of Union{Symbol, Function}, which determines the elements of the converted tuple on an element-by-element basis.
For the ith element of Fields:
- If it is a Symbol, it represents the name of a single index of an
OperatorIndex, and its value will become the corresponding element in the converted tuple. - If it is a Function, it should be a trait function of an
OperatorIndex, and its return value will become the corresponding element in the converted tuple.
QuantumLattices.DegreesOfFreedom.OperatorIndexToTuple — Method(operatorunittotuple::OperatorIndexToTuple)(index::Index) -> TupleConvert an index to a tuple.
QuantumLattices.DegreesOfFreedom.OperatorIndexToTuple — MethodOperatorIndexToTuple(::Type{I}) where {I<:Index}Construct the metric rule from the information of the Index type.
QuantumLattices.DegreesOfFreedom.Ordinal — TypeOrdinalOrdinal of an Int.
QuantumLattices.DegreesOfFreedom.Pattern — TypePattern(indexes::OneAtLeast{Index}, constraint::Function, representation::String=string(constraint))
Pattern{P}(indexes::OneAtLeast{Index}, constraints::NTuple{N, Function}, representations::NTuple{N, String}=map(string, constraints)) where {P, N}Construct a coupling pattern with 1) only one constraint function, and 2) several constraint functions.
QuantumLattices.DegreesOfFreedom.Pattern — TypePattern{I, P, N, C<:OneAtLeast{Function}} <: QuantumOperatorCoupling pattern.
QuantumLattices.DegreesOfFreedom.Pattern — MethodPattern(indexes::OneAtLeast{Index})
Pattern(index::Index, indexes::Index...)Construct a coupling pattern subject to the "diagonal" constraint for a homogeneous set of indexes.
QuantumLattices.DegreesOfFreedom.SimpleInternal — TypeSimpleInternal{I<:InternalIndex} <: Internal{I}Simple internal space at a single point.
QuantumLattices.DegreesOfFreedom.Table — TypeTable(indexes::AbstractVector{<:OperatorIndex}, by::Metric=OperatorIndexToTuple(eltype(indexes)))Convert a set of operator units to the corresponding table of operator index vs. sequence pairs.
The input operator units are measured by the input by function with the duplicates removed. The resulting unique values are sorted, which determines the sequence of the input indexes. Note that two operator units have the same sequence if their converted values are equal to each other.
QuantumLattices.DegreesOfFreedom.Table — TypeTable(hilbert::Hilbert, by::Metric=OperatorIndexToTuple(typeof(hilbert))) -> TableGet the index-sequence table of a Hilbert space.
QuantumLattices.DegreesOfFreedom.Table — TypeTable{I, B<:Metric} <: CompositeDict{I, Int}Table of operator index v.s. sequence pairs.
QuantumLattices.DegreesOfFreedom.Term — TypeTerm{K, I, V, B, C<:TermCoupling, A<:TermAmplitude}Term of a quantum lattice system.
QuantumLattices.DegreesOfFreedom.Term — MethodTerm{K}(id::Symbol, value, bondkind, coupling, ishermitian::Bool; amplitude::Union{Function, Nothing}=nothing, ismodulatable::Bool=true) where KConstruct a term.
QuantumLattices.DegreesOfFreedom.TermAmplitude — TypeTermAmplitude{F} <: FunctionFunction for the amplitude of a term.
QuantumLattices.DegreesOfFreedom.TermCoupling — TypeTermCoupling{C<:Coupling, F} <: FunctionFunction for the coupling of a term.
QuantumLattices.DegreesOfFreedom.@pattern — Macro@pattern index₁ index₂ ...
@pattern(index₁, index₂, ...; constraint=...)Construct a coupling pattern according to the pattern of the input indexes and an optional constraint.
Base.:* — Method*(cp₁::Coupling, cp₂::Coupling) -> CouplingGet the multiplication between two coupling.
Base.:* — Method*(mc₁::MatrixCoupling, mc₂::MatrixCoupling) -> MatrixCouplingProd
*(mc::MatrixCoupling, mcp::MatrixCouplingProd) -> MatrixCouplingProd
*(mcp::MatrixCouplingProd, mc::MatrixCoupling) -> MatrixCouplingProd
*(mcp₁::MatrixCouplingProd, mcp₂::MatrixCouplingProd) -> MatrixCouplingProd
*(mc::MatrixCoupling, factor::Number) -> MatrixCouplingProd
*(factor::Number, mc::MatrixCoupling) -> MatrixCouplingProd
*(factor::Number, mcp::MatrixCouplingProd) -> MatrixCouplingProd
*(mcp::MatrixCouplingProd, factor::Number) -> MatrixCouplingProd
*(mcs::MatrixCouplingSum, element::Union{Number, MatrixCoupling, MatrixCouplingProd}) -> MatrixCouplingSum
*(element::Union{Number, MatrixCoupling, MatrixCouplingProd}, mcs::MatrixCouplingSum) -> MatrixCouplingSum
*(mcs₁::MatrixCouplingSum, mcs₂::MatrixCouplingSum) -> MatrixCouplingSumProduct between MatrixCouplings and MatrixCouplingProds.
Base.:+ — Method+(mc₁::Union{MatrixCoupling, MatrixCouplingProd}, mc₂::Union{MatrixCoupling, MatrixCouplingProd}) -> MatrixCouplingSum
+(mc::Union{MatrixCoupling, MatrixCouplingProd}, mcs::MatrixCouplingSum) -> MatrixCouplingSum
+(mcs::MatrixCouplingSum, mc::Union{MatrixCoupling, MatrixCouplingProd}) -> MatrixCouplingSum
+(mcs₁::MatrixCouplingSum, mcs₂::MatrixCouplingSum) -> MatrixCouplingSumAddition between MatrixCouplings and MatrixCouplingProds.
Base.:/ — Method/(mcp::MatrixCouplingProd, factor::Number) -> MatrixCouplingProd
/(mcs::MatrixCouplingSum, factor::Number) -> MatrixCouplingSum
/(mc::MatrixCoupling, factor::Number) -> MatrixCouplingProd
//(mcp::MatrixCouplingProd, factor::Number) -> MatrixCouplingProd
//(mcs::MatrixCouplingSum, factor::Number) -> MatrixCouplingSum
//(mc::MatrixCoupling, factor::Number) -> MatrixCouplingProd
-(mc::MatrixCoupling) -> MatrixCouplingProd
-(mcp::MatrixCouplingProd) -> MatrixCouplingProd
-(mcs::MatrixCouplingSum) -> MatrixCouplingSum
-(mc₁::Union{MatrixCoupling, MatrixCouplingProd}, mc₂::Union{MatrixCoupling, MatrixCouplingProd}) -> MatrixCouplingSum
-(mc::Union{MatrixCoupling, MatrixCouplingProd}, mcs::MatrixCouplingSum) -> MatrixCouplingSum
-(mcs::MatrixCouplingSum, mc::Union{MatrixCoupling, MatrixCouplingProd}) -> MatrixCouplingSum
-(mcs₁::MatrixCouplingSum, mcs₂::MatrixCouplingSum) -> MatrixCouplingSumDefine right-division, minus and subtraction operator for a MatrixCoupling/MatrixCouplingProd/MatrixCouplingSum.
Base.:^ — Method^(mc::Union{MatrixCoupling, MatrixCouplingProd, MatrixCouplingSum}, n::Integer) -> Union{MatrixCoupling, MatrixCouplingProd, MatrixCouplingSum}Get the nth power of a MatrixCoupling/MatrixCouplingProd/MatrixCouplingSum.
Base.adjoint — Methodadjoint(index::CoordinatedIndex) -> typeof(index)Get the adjoint of a coordinated index.
Base.adjoint — Methodadjoint(index::Index) -> typeof(index)Get the adjoint of an index.
Base.filter — Methodfilter(index::InternalIndex, internal::CompositeInternal) -> Union{Nothing, SimpleInternal, CompositeInternal}
filter(::Type{I}, internal::CompositeInternal) where {I<:InternalIndex} -> Union{Nothing, SimpleInternal, CompositeInternal}Filter the composite internal space and select those that match the input internal index or the type of an internal index.
Base.filter — Methodfilter(index::InternalIndex, internal::SimpleInternal) -> Union{Nothing, typeof(internal)}
filter(::Type{I}, internal::SimpleInternal) where {I<:InternalIndex} -> Union{Nothing, typeof(internal)}Filter a simple internal space with respect to the input internal index or the type of an internal index.
Base.filter — Methodfilter(index::InternalIndex, ::Type{CI}) where {CI<:CompositeInternal}
filter(::Type{I}, ::Type{CI}) where {I<:InternalIndex, CI<:CompositeInternal}Filter the type of a composite internal space and select those that match the input internal index or the type of an internal index.
Base.filter — Methodfilter(index::InternalIndex, ::Type{SI}) where {SI<:SimpleInternal}
filter(::Type{I}, ::Type{SI}) where {I<:InternalIndex, SI<:SimpleInternal}Filter the type of a simple internal space with respect to the input internal index or the type of an internal index.
Base.findall — Methodfindall(select::Function, hilbert::Hilbert, table::Table) -> Vector{Int}Find all the sequences of indexes contained in a Hilbert space according to a table and a select function.
Base.getindex — Methodgetindex(pattern::Pattern, slice)Get the indexes specified by slice in a coupling pattern.
Base.getindex — Methodgetindex(table::Table, index::OperatorIndex) -> IntInquiry the sequence of an operator index.
Base.haskey — Methodhaskey(table::Table, index::OperatorIndex) -> Bool
haskey(table::Table, indexes::ZeroAtLeast{OperatorIndex}) -> ZeroAtLeast{Bool}Judge whether a single operator index or a set of operator indexes have been assigned with sequences in table.
Base.keys — Methodkeys(bound::Boundary) -> ZeroAtLeast{Symbol}
keys(::Type{<:Boundary{Names}}) where Names -> NamesGet the names of the boundary parameters.
Base.keys — Methodkeys(::OperatorIndexToTuple{Fields}) where Fields -> Fields
keys(::Type{<:OperatorIndexToTuple{Fields}}) where Fields -> FieldsGet the values of the type parameter Fields.
Base.match — Methodmatch(index::InternalIndex, internal::SimpleInternal) -> Bool
match(::Type{I}, internal::SimpleInternal) where {I<:InternalIndex} -> Bool
match(index::InternalIndex, ::Type{SI}) where {SI<:SimpleInternal} -> Bool
match(::Type{I}, ::Type{SI}) where {I<:InternalIndex, SI<:SimpleInternal} -> BoolJudge whether a simple internal space or the type of a simple internal space matches an internal index or the type of an internal index.
Here, "match" means that the eltype of the simple internal space is consistent with the type of the internal index, which usually means that they share the same type name.
Base.match — Methodmatch(pattern::Pattern, indexes::OneAtLeast{InternalIndex}) -> BoolJudge whether a set of internal indexes satisfies a coupling pattern.
Base.merge! — Methodmerge!(bound::Boundary, another::Boundary) -> typeof(bound)Merge the values and vectors of the twisted boundary condition from another one.
Base.one — Methodone(term::Term) -> TermGet a unit term.
Base.replace — Methodreplace(bound::Boundary; values=bound.values, vectors=bound.vectors) -> BoundaryReplace the values or vectors of a twisted boundary condition and get the new one.
Base.replace — Methodreplace(term::Term, value) -> TermReplace the value of a term.
Base.string — Methodstring(term::Term, bond::Bond, hilbert::Hilbert) -> StringGet the string representation of a term on a bond with a given Hilbert space.
Base.union — Methodunion(tables::Table...) -> TableUnite several operator index vs. sequence tables.
Base.valtype — Methodvaltype(term::Term)
valtype(::Type{<:Term)Get the value type of a term.
Base.valtype — Methodvaltype(terms::OneAtLeast{Term})
valtype(::Type{<:T}) where {T<:OneAtLeast{Term}}Get the common value type of a set of terms.
Base.valtype — Methodvaltype(::Type{<:OperatorIndexToTuple}, ::Type{<:Index})Get the valtype of applying an OperatorIndexToTuple rule to an Index.
Base.zero — Methodzero(term::Term) -> TermGet a zero term.
LaTeXStrings.latexstring — Methodlatexstring(coupling::Coupling) -> StringConvert a coupling to the latex format.
LaTeXStrings.latexstring — Methodlatexstring(pattern::Pattern) -> StringConvert a coupling pattern to the latex format.
LinearAlgebra.rank — Methodrank(internal::CompositeInternal) -> Int
rank(::Type{<:CompositeInternal{T}}) where {T<:OneAtLeast{SimpleInternal}} -> IntGet the number of simple internal spaces in a composite internal space.
LinearAlgebra.rank — Methodrank(coupling::Coupling) -> Int
rank(::Type{M}) where {M<:Coupling} -> IntGet the rank of a coupling.
LinearAlgebra.rank — Methodrank(pattern::Pattern, i::Integer) -> Int
rank(::Type{P}, i::Integer) where {P<:Pattern} -> IntGet the ith rank of the coupling pattern where the ith constraint can apply.
LinearAlgebra.rank — Methodrank(pattern::Pattern) -> Int
rank(::Type{P}) where {P<:Pattern} -> IntGet the total rank of the coupling pattern.
LinearAlgebra.rank — Methodrank(term::Term) -> Int
rank(::Type{<:Term) -> IntGet the rank of a term.
QuantumLattices.:⊕ — Method⊕(internal::SimpleInternal, internals::SimpleInternal...) -> InternalSum
⊕(internal::SimpleInternal, internals::InternalSum) -> InternalSum
⊕(internals::InternalSum, internal::SimpleInternal) -> InternalSum
⊕(internals₁::InternalSum, internals₂::InternalSum) -> InternalSumDirect sum between simple internal spaces and composite internal spaces.
QuantumLattices.:⊗ — Method⊗(pattern₁::Pattern, pattern₂::Pattern) -> PatternGet the combination of two coupling patterns.
QuantumLattices.:⊗ — Method⊗(internal::SimpleInternal, internals::SimpleInternal...) -> InternalProd
⊗(internal::SimpleInternal, internals::InternalProd) -> InternalProd
⊗(internals::InternalProd, internal::SimpleInternal) -> InternalProd
⊗(internals₁::InternalProd, internals₂::InternalProd) -> InternalProdDirect product between simple internal spaces and composite internal spaces.
QuantumLattices.DegreesOfFreedom.coordinatedindextype — Methodcoordinatedindextype(I::Type{<:SimpleInternal}, P::Type{<:Point})Get the compatible type of the coordinated index based on the type of an internal space and the type of a point.
QuantumLattices.DegreesOfFreedom.diagonalfields — Methoddiagonalfields(::Type{I}) where {I<:InternalIndex} -> ZeroAtLeast{Symbol}Get the field names that can be subject to all-equal constraint based on the type of an internal index.
QuantumLattices.DegreesOfFreedom.indextype — Methodindextype(index::OperatorIndex)
indextype(::Type{I}) where {I<:OperatorIndex}Get the type of the Index part of an OperatorIndex.
QuantumLattices.DegreesOfFreedom.indextype — Methodindextype(I::Type{<:SimpleInternal})Get the compatible type of the index based on the type of an internal space.
QuantumLattices.DegreesOfFreedom.internalindextype — Methodinternalindextype(index::OperatorIndex)
internalindextype(::Type{I}) where {I<:OperatorIndex}Get the type of the InternalIndex part of an OperatorIndex.
QuantumLattices.DegreesOfFreedom.isdefinite — Methodisdefinite(index::Index) -> Bool
isdefinite(::Type{<:Index{I}}) where {I<:InternalIndex} -> BoolDetermine whether an index denotes a definite degree of freedom.
QuantumLattices.DegreesOfFreedom.isdefinite — Methodisdefinite(index::InternalIndex) -> Bool
isdefinite(::Type{<:InternalIndex}) -> BoolJudge whether an internal index or a type of an internal index denotes a definite internal degree of freedom.
QuantumLattices.DegreesOfFreedom.isdefinite — Methodisdefinite(indexes::OneAtLeast{Index}) -> Bool
isdefinite(::Type{T}) where {T<:OneAtLeast{Index}} -> BoolDetermine whether a tuple of indexes denotes a definite degree of freedom.
QuantumLattices.DegreesOfFreedom.isdefinite — Methodisdefinite(indexes::OneAtLeast{InternalIndex}) -> Bool
isdefinite(::Type{T}) where {T<:OneAtLeast{InternalIndex}} -> BoolJudge whether all of a set of internal indexes denote definite internal degrees of freedom.
QuantumLattices.DegreesOfFreedom.isdiagonal — Methodisdiagonal(indexes::OneAtLeast{InternalIndex}, ::Val{fields}) where fields -> BoolJudge whether a set of homogenous internal indexes is subject to the "diagonal" constraint.
QuantumLattices.DegreesOfFreedom.partition — Methodpartition(pattern::Pattern) -> OneAtLeast{Int}
partition(::Type{<:Pattern{I, P} where I}) where P -> PGet the partition of the coupling pattern.
QuantumLattices.DegreesOfFreedom.patternrule — Functionpatternrule(value, ::Val{Name}, args...; kwargs...) where NameBy overriding this function, a named rule for the value of some attributes in a pattern can be defined so that the value can be transformed into the desired one.
In most cases, such overridden functions define the default rules for the attributes in a pattern when they take on the default value :.
QuantumLattices.DegreesOfFreedom.patternrule — Methodpatternrule(value, ::Val, args...; kwargs...)-> typeof(value)Default pattern rule unless otherwise specified.
QuantumLattices.DegreesOfFreedom.patternrule — Methodpatternrule(sites::OneAtLeast{Colon}, ::Val, bondlength::Integer) -> OneAtLeast{Ordinal}Define the default rule for the sites of a set of indexes in a coupling pattern.
QuantumLattices.DegreesOfFreedom.patternrule — Methodpatternrule(indexes::OneAtLeast{InternalIndex}, ::Val{Name}) where Name -> OneAtLeast{InternalIndex}Define the default rule for the internal index in a coupling pattern.
QuantumLattices.DegreesOfFreedom.plain — FunctionplainPlain boundary condition without any twist.
QuantumLattices.DegreesOfFreedom.showablefields — Methodshowablefields(index::InternalIndex) -> ZeroAtLeast{Symbol}
showablefields(::Type{I}) where {I<:InternalIndex} -> ZeroAtLeast{Symbol}Get the showable fields of an internal index or a type of internal index.
QuantumLattices.DegreesOfFreedom.statistics — Methodstatistics(index::CompositeIndex) -> Symbol
statistics(::Type{I}) where {I<:CompositeIndex} -> SymbolGet the statistics of a composite index.
QuantumLattices.DegreesOfFreedom.statistics — Methodstatistics(index::Index) -> Symbol
statistics(::Type{I}) where {I<:Index} -> SymbolGet the statistics of an index.
QuantumLattices.DegreesOfFreedom.statistics — Methodstatistics(index::InternalIndex) -> SymbolGet the statistics of an internal index.
QuantumLattices.DegreesOfFreedom.statistics — Methodstatistics(internal::SimpleInternal) -> Symbol
statistics(::Type{<:SimpleInternal{I}}) where {I<:InternalIndex} -> SymbolGet the statistics of a simple internal space.
QuantumLattices.QuantumOperators.operatortype — Methodoperatortype(::Type{B}, ::Type{H}, ::Type{T}) where {B<:Bond, H<:Hilbert, T<:Term}Get the compatible Operator type from the type of a term, a Hilbert space and a bond.
QuantumLattices.QuantumOperators.script — Methodscript(index::CoordinatedIndex, ::Val{:integercoordinate}; vectors, kwargs...)Get the integer coordinate script of a coordinated index.
QuantumLattices.QuantumOperators.script — Methodscript(index::CoordinatedIndex, ::Val{:rcoordinate}; kwargs...) -> String
script(index::CoordinatedIndex, ::Val{:icoordinate}; kwargs...) -> StringGet the rcoordinate/icoordinate script of a coordinated index.
QuantumLattices.QuantumOperators.script — Methodscript(index::Index, ::Val{:site}; kwargs...) -> String
script(index::Index, attr::Val; kwargs...) -> StringGet the required script of an index.
QuantumLattices.QuantumOperators.script — Methodscript(index::CompositeIndex, ::Val{attr}; kwargs...) where attrGet the attr script of a composite index.
QuantumLattices.Spatials.icoordinate — Methodicoordinate(opt::Operator{<:Number, <:ZeroAtLeast{CoordinatedIndex}}) -> SVectorGet the whole icoordinate of an operator.
QuantumLattices.Spatials.nneighbor — Methodnneighbor(term::Term) -> Int
nneighbor(terms::OneAtLeast{Term}) -> IntGet the
- order of neighbor in a single term;
- highest order of neighbors in a set of terms.
QuantumLattices.Spatials.rcoordinate — Methodrcoordinate(opt::Operator{<:Number, <:ZeroAtLeast{CoordinatedIndex}}) -> SVectorGet the whole rcoordinate of an operator.
QuantumLattices.dimension — Methoddimension(internal::Internal) -> IntGet the dimension of an internal space at a single point.
QuantumLattices.expand! — Methodexpand!(operators::Operators, term::Term, bond::Bond, hilbert::Hilbert; half::Bool=false) -> Operators
expand!(operators::Operators, term::Term, bonds, hilbert::Hilbert; half::Bool=false) -> OperatorsExpand the operators of a term on a bond/set-of-bonds with a given Hilbert space.
The half parameter determines the behavior of generating operators, which falls into the following two categories
true: "Hermitian half" of the generated operatorsfalse: "Hermitian whole" of the generated operators
QuantumLattices.expand — Methodexpand(term::Term, bond::Bond, hilbert::Hilbert; half::Bool=false) -> Operators
expand(term::Term, bonds, hilbert::Hilbert; half::Bool=false) -> OperatorsExpand the operators of a term on a bond/set-of-bonds with a given Hilbert space.
QuantumLattices.expand — Methodexpand(coupling::Coupling, ::Val{Rule}, bond::Bond, hilbert::Hilbert) where RuleExpand a coupling with the given bond and Hilbert space under a given named pattern rule.
QuantumLattices.id — Methodid(term::Term) -> Symbol
id(::Type{<:Term) -> SymbolGet the id of a term.
QuantumLattices.kind — Methodkind(term::Term) -> Symbol
kind(::Type{<:Term) -> SymbolGet the kind of a term.
QuantumLattices.permute — Methodpermute(index₁::CoordinatedIndex, index₂::CoordinatedIndex) -> ZeroAtLeast{Operator}Get the permutation of two coordinated indexes.
QuantumLattices.permute — Methodpermute(index₁::Index, index₂::Index) -> ZeroAtLeast{Operator}Get the permutation of two indexes.
QuantumLattices.reset! — Methodreset!(table::Table, indexes::AbstractVector{<:OperatorIndex}) -> TableReset a table by a new set of indexes.
QuantumLattices.reset! — Methodreset!(table::Table, hilbert::Hilbert) -> TableReset a table by a Hilbert space.
QuantumLattices.shape — Methodshape(internal::SimpleInternal, index::InternalIndex) -> OrdinalRange{Int, Int}Get the shape of a simple internal space when a labeled internal index is considered.
It can be overloaded to restrict the shape of a simple internal space based on the input internal index to significantly improve efficiency, but this is not necessary.
QuantumLattices.update! — Methodupdate!(bound::Boundary; parameters...) -> BoundaryUpdate the values of the boundary twisted phase.
QuantumLattices.update! — Methodupdate!(term::Term, args...; kwargs...) -> TermUpdate the value of a term if it is ismodulatable.
QuantumLattices.value — Methodvalue(term::Term) -> valtype(term)Get the value of a term.