Bravais
BoundedBravais
BoundedBravais(parent: Optional[Builder] = None)
Bases: AtomArrangement
Source code in .venv/lib/python3.12/site-packages/bloqade/analog/builder/base.py
10 11 12 13 14 |
|
__match_args__
class-attribute
instance-attribute
__match_args__ = ('shape', 'lattice_spacing')
Base classe for Bravais lattices
[AtomArrangement
][bloqade.ir.location.base.AtomArrangement].
- [
Square
][bloqade.ir.location.bravais.Square] - [
Chain
][bloqade.ir.location.bravais.Chain] - [
Honeycomb
][bloqade.ir.location.bravais.Honeycomb] - [
Triangular
][bloqade.ir.location.bravais.Triangular] - [
Lieb
][bloqade.ir.location.bravais.Lieb] - [
Kagome
][bloqade.ir.location.bravais.Kagome] - [
Rectangular
][bloqade.ir.location.bravais.Rectangular]
n_atoms
cached
property
n_atoms: int
number of atoms (filled sites) in the register.
n_dims
property
n_dims
dimension of the lattice
Returns:
Name | Type | Description |
---|---|---|
int |
dimension of the lattice |
n_sites
property
n_sites: int
number of sites in the register.
n_vacant
property
n_vacant: int
number of vacant sites in the register.
coordinates
coordinates(index: List[int]) -> NDArray
calculate the coordinates of a cell in the lattice given the cell index.
Source code in .venv/lib/python3.12/site-packages/bloqade/analog/ir/location/bravais.py
113 114 115 116 117 118 119 120 121 122 |
|
enumerate
enumerate() -> Generator[LocationInfo, None, None]
enumerate all locations in the register.
Source code in .venv/lib/python3.12/site-packages/bloqade/analog/ir/location/bravais.py
124 125 126 127 128 |
|
scale
scale(factor: ScalarType) -> BoundedBravais
Scale the current location with a factor.
(x,y) -> factor*(x,y)
Parameters:
Name | Type | Description | Default |
---|---|---|---|
factor
|
str | Real | Decimal | Scalar
|
scale factor |
required |
Returns:
Name | Type | Description |
---|---|---|
BoundedBravais |
BoundedBravais
|
The lattice with the scaled locations |
Source code in .venv/lib/python3.12/site-packages/bloqade/analog/ir/location/bravais.py
136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 |
|
Chain
Chain(
L: int,
*,
lattice_spacing: ScalarType = 1.0,
vertical_chain: bool = False
)
Bases: BoundedBravais
Chain lattice.
- 1D lattice
- primitive (cell) vector(s)
- a1 = (1,0).
- unit cell (1 atom(s))
- loc (0,0)
Parameters:
Name | Type | Description | Default |
---|---|---|---|
L
|
int
|
number of sites in the chain |
required |
lattice_spacing
|
(Scalar, Real)
|
lattice spacing. Defaults to 1.0. |
1.0
|
- Possible Next:
continue with
.
to see possible next step in auto-prompt supported setting (IPython, IDE ...)
Source code in .venv/lib/python3.12/site-packages/bloqade/analog/ir/location/bravais.py
183 184 185 186 187 188 189 190 |
|
Honeycomb
Honeycomb(
L1: int,
L2: Optional[int] = None,
*,
lattice_spacing: ScalarType = 1.0
)
Bases: BoundedBravais
Honeycomb lattice.
- 2D lattice
- primitive (cell) vector(s)
- a1 = (1, 0)
- a2 = (1/2, sqrt(3)/2)
- unit cell (2 atom(s))
- loc1 (0, 0)
- loc2 (1/2, 1/(2*sqrt(3))
Parameters:
Name | Type | Description | Default |
---|---|---|---|
L1
|
int
|
number of unit cells in linear direction. n_atoms = L1 * L1 * 2. |
required |
L2
|
Optional[int]
|
number of unit cells in direction a2. n_atoms = L1 * L2 * 2, default is L1. |
None
|
lattice_spacing
|
(Scalar, Real)
|
lattice spacing. Defaults to 1.0. |
1.0
|
- Possible Next:
continue with
.
to see possible next step in auto-prompt supported setting (IPython, IDE ...)
Source code in .venv/lib/python3.12/site-packages/bloqade/analog/ir/location/bravais.py
420 421 422 423 424 425 426 427 428 429 430 431 |
|
Kagome
Kagome(
L1: int,
L2: Optional[int] = None,
*,
lattice_spacing: ScalarType = 1.0
)
Bases: BoundedBravais
Kagome lattice.
- 2D lattice
- primitive (cell) vector(s)
- a1 = (1, 0)
- a2 = (1/2, sqrt(3)/2)
- unit cell (3 atom(s))
- loc1 (0, 0)
- loc2 (0.5, 0)
- loc3 (0.25 ,0.25sqrt(3))
Parameters:
Name | Type | Description | Default |
---|---|---|---|
L1
|
int
|
number of sites in linear direction. n_atoms = 3 * L1 * L1. |
required |
L2
|
Optional[int]
|
number of unit cells along a2 direction, n_atoms = 3 * L1 * L2, default is L1. |
None
|
lattice_spacing
|
(Scalar, Real)
|
lattice spacing. Defaults to 1.0. |
1.0
|
- Possible Next:
continue with
.
to see possible next step in auto-prompt supported setting (IPython, IDE ...)
Source code in .venv/lib/python3.12/site-packages/bloqade/analog/ir/location/bravais.py
589 590 591 592 593 594 595 596 597 598 599 |
|
Lieb
Lieb(
L1: int,
L2: Optional[int] = None,
*,
lattice_spacing: ScalarType = 1.0
)
Bases: BoundedBravais
Lieb lattice.
- 2D lattice
- primitive (cell) vector(s)
- a1 = (1, 0)
- a2 = (0, 1)
- unit cell (3 atom(s))
- loc1 (0, 0)
- loc2 (0.5, 0)
- loc3 (0 ,0.5)
Parameters:
Name | Type | Description | Default |
---|---|---|---|
L1
|
int
|
number of unit cells in linear direction. n_atoms = 3* L1 * L1. |
required |
L2
|
Optional[int]
|
number of unit cells along a2 direction, n_atoms = 3 * L1 * L2, default is L1. |
None
|
lattice_spacing
|
(Scalar, Real)
|
lattice spacing. Defaults to 1.0. |
1.0
|
- Possible Next:
continue with
.
to see possible next step in auto-prompt supported setting (IPython, IDE ...)
Source code in .venv/lib/python3.12/site-packages/bloqade/analog/ir/location/bravais.py
534 535 536 537 538 539 540 541 542 |
|
Rectangular
Rectangular(
width: int,
height: int,
*,
lattice_spacing_x: ScalarType = 1.0,
lattice_spacing_y: ScalarType = 1.0
)
Bases: BoundedBravais
Rectangular lattice.
- 2D lattice
- primitive (cell) vector(s)
- a1 = (1,0)
- a2 = (0,1)
- unit cell (1 atom(s))
- loc (0,0)
Parameters:
Name | Type | Description | Default |
---|---|---|---|
width
|
int
|
number of sites in x direction. |
required |
height
|
int
|
number of sites in y direction. |
required |
lattice_spacing_x
|
(Scalar, Real)
|
lattice spacing. Defaults to 1.0. |
1.0
|
lattice_spacing_y
|
(Scalar, Real)
|
lattice spacing in y direction. optional. |
1.0
|
- Possible Next:
continue with
.
to see possible next step in auto-prompt supported setting (IPython, IDE ...)
Source code in .venv/lib/python3.12/site-packages/bloqade/analog/ir/location/bravais.py
297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 |
|
Square
Square(
L1: int,
L2: Optional[int] = None,
*,
lattice_spacing: ScalarType = 1.0
)
Bases: BoundedBravais
Square lattice.
- 2D lattice
- primitive (cell) vector(s)
- a1 = (1,0)
- a2 = (0,1)
- unit cell (1 atom(s))
- loc (0,0)
Parameters:
Name | Type | Description | Default |
---|---|---|---|
L1
|
int
|
number of sites in linear direction. n_atoms = L1 * L1. |
required |
L2
|
Optional[int]
|
number of sites in direction a2. n_atoms = L1 * L2, default is L1 |
None
|
lattice_spacing
|
(Scalar, Real)
|
lattice spacing. Defaults to 1.0. |
1.0
|
- Possible Next:
continue with
.
to see possible next step in auto-prompt supported setting (IPython, IDE ...)
Source code in .venv/lib/python3.12/site-packages/bloqade/analog/ir/location/bravais.py
240 241 242 243 244 245 246 247 248 249 |
|
Triangular
Triangular(
L1: int,
L2: Optional[int] = None,
*,
lattice_spacing: ScalarType = 1.0
)
Bases: BoundedBravais
Triangular lattice.
- 2D lattice
- primitive (cell) vector(s)
- a1 = (1, 0)
- a2 = (1/2, sqrt(3)/2)
- unit cell (1 atom(s))
- loc (0, 0)
Parameters:
Name | Type | Description | Default |
---|---|---|---|
L
|
int
|
number of sites in linear direction. n_atoms = L * L. |
required |
L2
|
Optional[int]
|
number of sites along a2 direction, n_atoms = L1 * L2, default is L1. |
None
|
lattice_spacing
|
(Scalar, Real)
|
lattice spacing. Defaults to 1.0. |
1.0
|
- Possible Next:
continue with
.
to see possible next step in auto-prompt supported setting (IPython, IDE ...)
Source code in .venv/lib/python3.12/site-packages/bloqade/analog/ir/location/bravais.py
477 478 479 480 481 482 483 484 485 486 487 |
|