grogupy.physics.Contour

class grogupy.physics.Contour(eset: int = 1000, esetp: float = 10000, emin: float | None = None, emax: float = 0, emin_shift: float = -5, emax_shift: float = 0, eigfile: None | str = None)[source]

This class contains and creates the data of the energy contour for the integration.

If the emin argument is not given the eigfile argument must be given to automatically set the energy minimum of the system.

Parameters

esetint, optional

Number of energy samples on the contour, by default 100

esetpfloat, optional

A parameters that changes the shape of the sampling, by default 10000

eminUnion[float, None]

The lower bound of the integral. When it is None it is automatically set

emaxUnion[float, None], optional

The upper bound of the integral, by default 0

emin_shiftfloat

It is added to the emin value, by default -5

emax_shiftfloat

It is added to the emax value, by default 0

eigfileUnion[str, None]

Either the path to the siesta .EIG or the .fdf file

Examples

Creating a Contour instance from the minimal amount of information.

>>> contour = Contour(eset=600, esetp=1000, emin=-20)
>>> print(contour)
<grogupy.Contour emin=-25, emax=0, eset=600, esetp=1000>

Or create it with the automatic emin finder.

>>> contour = Contour(eset=600, esetp=1000, emin=None, eigfile="/Users/danielpozsar/Downloads/Fe3GeTe2/Fe3GeTe2.fdf")
>>> print(contour)
<grogupy.Contour emin=-17.80687896, emax=0, eset=600, esetp=1000>

Methods

to_dict() :

Returns the instance data as a dictionary.

copy() :

Return a copy of this Contour

Attributes

samples: NDArray

The samples along the contour

weights: NDArray

The weights of the corresponding samples

times: grogupy.batch.timing.DefaultTimer

It contains and measures runtime

__init__(eset: int = 1000, esetp: float = 10000, emin: float | None = None, emax: float = 0, emin_shift: float = -5, emax_shift: float = 0, eigfile: None | str = None) None[source]

This functions sets up the energy integral.

If the emin argument is not given the eigfile argument must be given to automatically set the energy minimum of the system.

Parameters

esetint, optional

Number of energy samples on the contour, by default 1000

esetpfloat, optional

A parameters that changes the shape of the sampling, by default 10000

eminUnion[float, None]

The lower bound of the integral. When it is None it is automatically set

emaxUnion[float, None], optional

The upper bound of the integral, by default 0

emin_shiftfloat

It is added to the emin value, by default -5

emax_shiftfloat

It is added to the emax value, by default 0

eigfileUnion[str, None]

Either the path to the siesta .EIG or the .fdf file

Methods

__init__([eset, esetp, emin, emax, ...])

This functions sets up the energy integral.

copy()

Returns the deepcopy of the instance.

plot([marker_size, marker_opacity, width, ...])

Creates a plot from the contour sample points.

Attributes

automatic_emin

emax

Top of the contour integral.

emin

Bottom of the contour integral.

eset

Number of samples along the contour.

esetp

Assymmetry parameter of the contour generation.