Path Properties
Pauli frequency tracker
PauliPropagation.PauliFreqTracker
— TypePauliFreqTracker(coeff::Number, nsins::Int, ncos::Int, freq::Int)
Wrapper type for numerical coefficients in Pauli propagation that records the number of sin and cos factors applied via a PauliRotation
gate, and the so-called frequency, which is their sum. It appears redundant but these three properties need to be tracked separately because of how merging affects them.
PauliPropagation.PauliFreqTracker
— MethodPauliFreqTracker(coeff::Number)
Constructor for PauliFreqTracker
from only a coefficient. Initializes nsins
, ncos
, and freq
to zero.
Abstract type
PauliPropagation.PathProperties
— TypeAbstract type for wrapping coefficients and record custom path properties
Base.float
— Methodfloat(path::PathProperties)
Returns an equivalent PathProperties
object where float() is applied to the coeff
field.
PauliPropagation.tonumber
— Methodtonumber(path::PathProperties)
Get the numerical coefficient of a PathProperties
wrapper.
PauliPropagation.unwrapcoefficients
— Methodunwrapcoefficients(pstr::PauliString)
Unwrap the coefficient of a PauliString
from a PathProperties
type. Returns a PauliString
with the coeff
field of the PathProperties
object.
PauliPropagation.unwrapcoefficients
— Methodunwrapcoefficients(psum::PauliSum)
Unwrap the coefficients of a PauliSum
from a PathProperties
type. Returns a PauliSum
with coefficients being the coeff
field of the PathProperties
objects.
PauliPropagation.wrapcoefficients
— Methodwrapcoefficients(pstr::PauliString, PathPropertiesType<:PathProperties)
Wrap the coefficient of a PauliString
into a custom PathProperties
type. For anything that is not natively supported by the library, you can subtype PathProperties
. A one-argument constructor of the custom PathProperties
type from a coefficient must be defined.
PauliPropagation.wrapcoefficients
— Methodwrapcoefficients(psum::PauliSum, PathPropertiesType<:PathProperties)
Wrap the coefficients of a PauliSum
into a custom PathProperties
type. For anything that is not natively supported by the library, you can subtype PathProperties
. A one-argument constructor of the custom PathProperties
type from a coefficient must be defined.