openfermion.transforms.commutator_ordered_diagonal_coulomb_with_two_body_operator
Compute the commutator of two-body operators provided that both are normal-ordered and that the first only has diagonal Coulomb interactions.
openfermion.transforms.commutator_ordered_diagonal_coulomb_with_two_body_operator(
operator_a, operator_b, prior_terms=None
)
Args |
operator_a
|
The first FermionOperator argument of the commutator.
All terms must be normal-ordered, and furthermore either hopping
operators (i^ j) or diagonal Coulomb operators (i^ i or i^ j^ i j).
|
operator_b
|
The second FermionOperator argument of the commutator.
operator_b can be any arbitrary two-body operator.
|
prior_terms
|
optional
The initial FermionOperator to add to.
|
Returns |
The commutator, or the commutator added to prior_terms if provided.
|
Notes |
The function could be readily extended to the case of arbitrary
two-body operator_a given that operator_b has the desired form;
however, the extra check slows it down without desirable added utility.
|
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-04-26 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-04-26 UTC."],[],[]]