Page 1 of 1

Adding a site to a chain perpendicularly

Posted: 17 Oct 2019, 11:26
by sergitb
I am studying a system composed of a bosonic chain of length \(L\) with a single site \( j\) with \(1<j<L\) coupled to a spin-1/2 so that the spin-1/2 only interacts with the \(j\) bosonic site, and the bosons in that site interact with the spin and, as first neighbor, with the sites in the chain \(j-1 \) and \(j+1\).

I have been trying to reproduce the geometry within TeNPy but it seems it is a feature to be implemented within IrregularLattice. However, I was wondering if there is anyway to work around it.

Reading the forum I came across the following post viewtopic.php?f=7&t=66 where deleting or adding sites is discussed and wanted to know if I could get the wanted result using something along the lines.

My idea was to build a chain with a two-site unit cell, a bosonic site and a spin-1/2 site, then take out all spin-1/2 sites except the wanted one and then using GroupedSite to group together the bosonic and spin sites into one. That being said I am not sure of how would this change the interactions within the system, or if they would change at all.
I also thought of maybe using a Ladder type lattice with boson sites on the lower part of the ladder and spin-1/2 for the other part and then removing all the unwanted spin-1/2 but I am not quite sure if it is possible to do so even by using the method using in the linked post.

So, to sum up I wanted to know if such a geometry is possible for the current version of TeNPy. These ideas are what I came up with but I have just begun to do this kinds of computations and I am for sure overlooking something. I would deeply appreciate any help or suggestions on the topic.

Thank you in advance.

Re: Adding a site to a chain perpendicularly

Posted: 29 Oct 2019, 16:04
by Johannes

indeed, the irregular lattice is still an open Issue #77. Sorry, there's so much stuff to do. I had to write and defend my PHD thesis, so I didn't have too much time to work on TeNPy lately. Hopefully, this will change again. ;)

To make sure I understand correctly, you want a geometry like this:

Code: Select all

spin -- spin -- spin -- spin -- spin -- spin
Do you want to couple the bosons to only the spin next to it?

And by the way, do you want to do time evolution, or only look at the ground state with DMRG?

Re: Adding a site to a chain perpendicularly

Posted: 30 Oct 2019, 15:56
by sergitb
Hello Johannes,

Thank you for your reply, I hope your thesis defense went well!

So the idea is basically what you wrote except swapping spins for bosons and vice versa, something like this:

Code: Select all

Boson -- Boson -- Boson -- Boson -- Boson -- Boson 
My aim is to first find the ground state of the system, then create an excitation on the ground state and make the system evolve with this new excited state.

However I have been working on the problem and I believe that it is possible to do it without doing such a explicit geometry and instead combining the sites of the spin and the boson it interacts with into a single site and turn the interactions between them into onsite operators. However, the problem remains the same, adding this extra degree of freedom in a single site without it being part of the unit cell.

Sorry if I did not explain myself well enough in my first post.

Re: Adding a site to a chain perpendicularly

Posted: 08 Jun 2020, 16:48
by Johannes
Just for your information, this is now possible in the latest version of TeNPy with the help of the tenpy.models.lattice.IrregularLattice, see example in it's docstring and ... tices.html

Re: Adding a site to a chain perpendicularly

Posted: 08 Jun 2020, 23:00
by steven_tao
The module lattice.IrregularLattice cannot be used after I upgrade TeNPy to a new version via pip install --upgrade physics-tenpy. After running the following code, the error message reads: TypeError: __init__() got an unexpected keyword argument 'remove'.

Code: Select all

import matplotlib.pyplot as plt
from tenpy.models import lattice

Lx, Ly = 3, 3
fig, axes = plt.subplots(1, 2, True, True, figsize=(6, 4))

reg_lat = lattice.Honeycomb(Lx=Lx, Ly=Ly, sites=None, bc='open')
irr_lat = lattice.IrregularLattice(reg_lat, remove=[[0, 0, 0], [-1, -1, 1]])
for lat, label, ax in zip([reg_lat, irr_lat],
                          ["regular", "irregular"],
    lat.plot_order(ax, linestyle=':')

Re: Adding a site to a chain perpendicularly

Posted: 08 Jun 2020, 23:24
by Johannes
Sorry if that wasn't clear. It's not included in version 0.6.1 on pip yet, but it's on the github master branch.
So you need to install the latest version from github. With pip:

Code: Select all

pip uninstall physics-tenpy  # if you installed it before
pip install git+git://
or download the latest version as source code, go into the top folder (where the is), and call pip install .

Re: Adding a site to a chain perpendicularly

Posted: 08 Jun 2020, 23:49
by steven_tao
I got it, thanks.