Skip to content

Commit

Permalink
updating documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
willjmax committed Sep 13, 2024
1 parent 4580d9e commit c35f19c
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions pennylane/fermi/fermionic.py
Original file line number Diff line number Diff line change
Expand Up @@ -326,12 +326,18 @@ def to_mat(self, n_orbitals=None, format="dense", buffer_size=None):

def shift_operator(self, initial_position, final_position):
r"""Shifts an operator in the FermiWord from ``initial_position`` to ``final_position`` by applying the fermionic anti-commutation relations.
There are four anti-commutator relations:
1) a(0)a(1) = -a(1)a(0)
2) a⁺(0)a⁺(1) = -a⁺(1)a⁺(0)
3) a(0)a⁺(1) = -a⁺(1)a(0)
4) a(0)a⁺(0) = 1 - a⁺(0)a(0)
See https://en.wikipedia.org/wiki/Creation_and_annihilation_operators#Creation_and_annihilation_operators_in_quantum_field_theories for more information.
.. math::
a_0 a_1 = -a_1 a_0
a^{\dagger}_0 a^{\dagger}_1 = -a^{\dagger}_1 a^{\dagger}_0
a_0 a^{\dagger}_1 = -a^{\dagger}_1 a_0
a_0 a^{\dagger}_0 = 1 - a^{\dagger}_0 a_0
For more details see `Wikipedia <https://en.wikipedia.org/wiki/Creation_and_annihilation_operators#Creation_and_annihilation_operators_in_quantum_field_theories>`.
Args:
Expand Down

0 comments on commit c35f19c

Please sign in to comment.