qrunch.quantum.operators.second_quantization.fermion.sums
A compact representation of a fermionic operator consisting only of single and double excitations.
Classes
Compact representation of the full second quantization fermionic hermitian sum. |
|
Protocol for representation of a second quantization fermionic hermitian sum. |
- class FermionHermitianSum
Bases:
FermionHermitianSumProtocol,HasCustomEncodingCompact representation of the full second quantization fermionic hermitian sum.
This operator consists of single- and double-excitations of fermion second-quantization operators.
- __init__(single_excitations: ndarray[Any, dtype[float64]] | ndarray[Any, dtype[complex128]] | Array, double_excitations: ndarray[Any, dtype[float64]] | ndarray[Any, dtype[complex128]] | Array) None
Initialize the full operator.
- Parameters:
- Return type:
None
- classmethod decode(data: dict[str, Any]) FermionHermitianSum
Decode a dictionary to an instance of TensorHyperContractionIntegrals.
- Parameters:
data (dict[str, Any]) – The dictionary representation of a TensorHyperContractionIntegrals instance.
- Return type:
- property double_excitations: Array
Return the double excitation part of the operator (physics ordering).
- encode() dict[str, Any]
Encode the instance into a dictionary.
- Return type:
dict[str, Any]
- static is_hardcore_bosonic() Literal[False]
Return True, if it is hard core bosonic.
- Return type:
Literal[False]
- rotate(rotation_matrices: tuple[ndarray[Any, dtype[float64]], ...]) FermionHermitianSum
Rotate the excitations.
- Parameters:
rotation_matrices (tuple[ndarray[Any, dtype[float64]], ...]) – The matrix to rotate with.
- Return type:
- rotation_matrix_structure() list[RotationBlockDefinition]
Get information on which blocks should be non-zero in the rotation matrix.
- Return type:
list[RotationBlockDefinition]
- class FermionHermitianSumProtocol
Bases:
ProtocolProtocol for representation of a second quantization fermionic hermitian sum.
This operator consists of single- and double-excitations of fermion second-quantization operators.
- __init__(*args, **kwargs)
- static is_hardcore_bosonic() Literal[False]
Return True, if it is hardcore bosonic.
- Return type:
Literal[False]
- rotate(rotation_matrices: tuple[ndarray[Any, dtype[float64]], ...]) Self
Rotate the excitations.
- Parameters:
rotation_matrices (tuple[ndarray[Any, dtype[float64]], ...]) – The matrix to rotate with.
- Return type:
Self
- rotation_matrix_structure() list[RotationBlockDefinition]
Get information on which blocks should be non-zero in the rotation matrix.
- Return type:
list[RotationBlockDefinition]