lattice¶
This module provides functions to define the 3D lattice
Functions
|
computes matrix elements for three-body onsite contact |
|
computes 1-body kinetic energy matrix elements. |
|
computes matrix elements for 2-body onsite contacts |
|
builds a 3D lattice |
|
builds a 3D lattice for nucleons with spin isospin degrees of freedom |
|
moves a site to the left in 1D, respecting periodic boundary conditions |
|
Takes position in x, y, and z on the lattice as well as the spin and isospin and returns a state |
|
computes matrix elements for 1-body momentum operator p_x. |
|
computes matrix elements for 1-body momentum operator p_y. |
|
computes matrix elements for 1-body momentum operator p_z. |
|
returns the energy unit from basic units |
|
moves a site to the right in 1D, respecting periodic boundary conditions |
|
given a site list [i,j,k] this function returns the index of that state in the list returned by get_lattice |
|
given a state list [i,j,k,tz,sz] this function returns the index of that state in the list returned by get_sp_basis |
|
Takes a list of hole states and returns the hole and particle spaces |
- lattice.phys_unit(a_lat)¶
returns the energy unit from basic units
- Parameters:
a_lat (float) – lattice spacing in fm
- Returns:
factor to scale the lattice units to energy units
- Return type:
float
- lattice.get_sp_basis(myL, spin=2, isospin=2)¶
builds a 3D lattice for nucleons with spin isospin degrees of freedom
- Parameters:
myL (int) – number of lattice sites in each direction
spin (int) – Optional; number of spin degrees of freedom
isospin (int) – Optional; number of isospin degrees of freedom
- Returns:
List of integer list [i,j,k,tz,sz] where lattice sites are labelled by i, j, k (from 0 to myL-1) in direction 1, 2, 3; tz=0, 1 and sz=0,1 correspond to isospin tz-1/2 and spin sz-1/2, respectively
- Return type:
list[(int, int, int, int, int)]
- lattice.state2index(state, myL, spin=2, isospin=2)¶
given a state list [i,j,k,tz,sz] this function returns the index of that state in the list returned by get_sp_basis
- Parameters:
state (list[(int, int, int, int, int)]) – the list [i,j,k,tz,sz]
myL (int) – number of lattice sites in each direction
spin (int) – Optional; number of spin degrees of freedom
isospin (int) – Optional; number of isospin degrees of freedom
- Returns:
index as an integer
- Return type:
int
- lattice.get_lattice(myL)¶
builds a 3D lattice
- Parameters:
myL (int) – number of lattice sites in each direction
- Returns:
List of integer lists [i,j,k] of lattice sites are labelled by i, j, k (from 0 to myL-1) in direction 1, 2, 3
- Return type:
list[(int, int, int)]
- lattice.site2index(site, myL)¶
given a site list [i,j,k] this function returns the index of that state in the list returned by get_lattice
- Parameters:
state (list[(int, int, int)]) – the list [i,j,k]
myL (int) – number of lattice sites in each direction
- Returns:
index as an integer
- Return type:
int
- lattice.right(site, myL)¶
moves a site to the right in 1D, respecting periodic boundary conditions
- Parameters:
site (int) – integer location of the site
myL (int) – number of lattice sites in each direction
- Returns:
index of site one to the right of site with index site
- Return type:
int
- lattice.left(site, myL)¶
moves a site to the left in 1D, respecting periodic boundary conditions
- Parameters:
site (int) – integer location of the site
myL (int) – number of lattice sites in each direction
- Returns:
index of site one to the left of site with index site
- Return type:
int
- lattice.Tkin(lattice, myL, spin=2, isospin=2)¶
computes 1-body kinetic energy matrix elements. Really: the negative dimensionless laplacian
- Parameters:
lattice (list[(int, int, int)]) – list of lattice sites returned by get_lattice
myL (int) – number of lattice sites in each direction
spin (int) – Optional; number of spin degrees of freedom
isospin (int) – Optional; number of isospin degrees of freedom
- Returns:
list of tuples [i, j, value] where i and j are indices in the single-particle basis, and value is the value of the matrix element Tij
- Return type:
list[(int, int, float)]
- lattice.contacts(vT1, vS1, lattice, myL, spin=2, isospin=2)¶
computes matrix elements for 2-body onsite contacts
- Parameters:
vT1 (float) – strength of T=1 coupling
vS1 (float) – strength of S=1 coupling
lattice (list[(int, int, int)]) – list of lattice sites returned by get_lattice
myL (int) – number of lattice sites in each direction
spin (int) – Optional; number of spin degrees of freedom
isospin (int) – Optional; number of isospin degrees of freedom
- Returns:
list of lists [i, j, k, l, value] where i, j and k, l are indices of two particles in the single-particle basis, and value is the value of the matrix element <ij||kl>. All elements have i<j and k<l
- Return type:
list[(int, int, int, int, float)]
- lattice.NNNcontact(v3NF, lattice, myL, spin=2, isospin=2)¶
computes matrix elements for three-body onsite contact
- Parameters:
v3NF (float) – strength of the 3 nucleon force
lattice (list[(int, int, int)]) – list of lattice sites returned by get_lattice
myL (int) – number of lattice sites in each direction
spin – Optional; number of spin degrees of freedom
isospin (int) – Optional; number of isospin degrees of freedom
- Returns:
list of tuples [i1, i2, i3, j1, j2, j3, value] where i1, i2, i3 and j1, j2, j3 are indices of three particles in the single-particle basis, and value is one (unit strength) for the matrix element <i1 i2 i3||j1 j2 j3>. All elements have i1<i2<i3 and j1<j2<j3
- Return type:
list[(int, int, int, int, int, int, float)]
- lattice.p_x(lattice, myL, spin=2, isospin=2)¶
computes matrix elements for 1-body momentum operator p_x. Really: -i times d_x
- Parameters:
lattice (list[(int, int, int)]) – list of lattice sites returned by get_lattice
myL (int) – number of lattice sites in each direction
spin – Optional; number of spin degrees of freedom
isospin (int) – Optional; number of isospin degrees of freedom
- Returns:
list of tuples [i, j, value] where i and j are indices in the single-particle basis, and value is the value of the matrix element Tij
- Return type:
list[(int, int, float)]
- lattice.p_y(lattice, myL, spin=2, isospin=2)¶
computes matrix elements for 1-body momentum operator p_y. Really: -i times d_y
- Parameters:
lattice (list[(int, int, int)]) – list of lattice sites returned by get_lattice
myL (int) – number of lattice sites in each direction
spin – Optional; number of spin degrees of freedom
isospin (int) – Optional; number of isospin degrees of freedom
- Returns:
list of tuples [i, j, value] where i and j are indices in the single-particle basis, and value is the value of the matrix element Tij
- Return type:
list[(int, int, float)]
- lattice.p_z(lattice, myL, spin=2, isospin=2)¶
computes matrix elements for 1-body momentum operator p_z. Really: -i times d_z
- Parameters:
lattice (list[(int, int, int)]) – list of lattice sites returned by get_lattice
myL (int) – number of lattice sites in each direction
spin – Optional; number of spin degrees of freedom
isospin (int) – Optional; number of isospin degrees of freedom
- Returns:
list of tuples [i, j, value] where i and j are indices in the single-particle basis, and value is the value of the matrix element Tij
- Return type:
list[(int, int, float)]
- lattice.states2PHSpace(holeList, myL)¶
Takes a list of hole states and returns the hole and particle spaces
- Parameters:
holeList (list[(int, int, int, int, int)]) – list of holes and their sites as [i, j, k, tz, sz]
myL (int) – number of lattice sites in each direction
- Returns:
hole and particle space
- Return type:
tuple(int), tuple(int)
- lattice.makeState(x, y, z, tz, sz)¶
Takes position in x, y, and z on the lattice as well as the spin and isospin and returns a state
- Parameters:
x (int) – x position in lattice
y (int) – y position in lattice
z (int) – z position in lattice
tz (0.5 | -0.5) – isospin
sz (0.5 | -0.5) – spin
- Returns:
a particle state on the lattice as a list
- Return type:
list[(int, int, int, int, int)]