grogupy._core.setup_from_range

grogupy._core.setup_from_range(dh: Hamiltonian, R: float, subset: None | int | str | list[int] | list[list[int]] | list[str] | list[list[str]] = None, **kwargs) tuple[list[dict], list[dict]][source]

Generates all the pairs and magnetic entities from atoms in a given radius.

It takes all the atoms from the unit cell and generates all the corresponding pairs and magnetic entities in the given radius. It can generate pairs for a subset of of atoms, which can be given by the subset parameter.

  1. If subset is None all atoms can create pairs

2. If subset is a list of integers, then all the possible pairs will be generated using these atoms, from and outside the unit cell.

3. If subset is two list, then the first list is the list of atoms in the unit cell (Ri), that can create pairs and the second list is the list of atoms outside the unit cell that can create pairs (Rj)

The keyword arguments can be l, orb or a tag of an atom, l and orb are passed to the atoms for wich the tag was not given. If a tag was passed to an atom, then it should contain a dictionary in the same format as the magnetic entity dictionary, which will be only passed to the specific atoms.

Parameters

dhsisl.physics.Hamiltonian

The sisl Hamiltonian that contains the geometry and atomic information

Rfloat

The radius where the pairs are found

subsetUnion[None, int ,str, list[int], list[list[int]], list[str], list[list[str]]], optional

The subset of atoms that contribute to the pairs, by default None

Other Parameters

kwargs: otpional

These are passed to the magnetic entity dictionary

Returns

magnetic_entitieslist[dict]

The magnetic entities dictionaries

pairslist[dict]

The pair dictionaries