Page 1 of 1
Obtainin expectation value of number operator in BH model
Posted: 10 Mar 2025, 09:20
by mariocat
Hello everyone,
I have a simple question (I guess). I'm trying to find the expectation value of the number operatore using the BH model but I'm really stuck. Does anyone know how to do it? Thanks!
Re: Obtainin expectation value of number operator in BH model
Posted: 19 Mar 2025, 10:05
by Jakob
I assume you mean the Bose Hubbard model?
In what state do you want to take the expectation value?
If you want it in the groundstate, you can take an MPS psi resulting from DMRG and use
psi.expectation_value('N'), which gives you the particle number on every single site.
Re: Obtainin expectation value of number operator in BH model
Posted: 02 Apr 2025, 07:26
by mariocat
Hello, thanks for your reply.
Yes, I meant in the ground state! What would be the complete code line?
Re: Obtainin expectation value of number operator in BH model
Posted: 02 Apr 2025, 14:25
by Jakob
Have a look at these examples that simulate groundstate expectation values
https://tenpy.readthedocs.io/en/latest/ ... _dmrg.html