triqs.gfs.descriptor_base

Protocol classes for Green’s function descriptors.

A descriptor is a small object that, when called with a Green’s function G, fills G.data in place. Descriptors are used by __lshift__() and __lshift__() so that

>>> g << SemiCircular(half_bandwidth=1.0)

assigns the closed-form expression of the corresponding model Green’s function to g.

Concrete descriptors are defined in triqs.gfs.descriptors; this module provides the base classes and the special placeholders Omega / iOmega_n.

Functions

convert_scalar_to_const(expr)

Lift scalars inside a lazy expression to Const descriptors.

is_lazy(y)

Whether y is a descriptor or a lazy expression.

is_scalar(x)

Whether x is a numerical scalar or numpy array.

Module Attributes

Omega

Frequency placeholder for use in lazy expressions (real-frequency naming).

iOmega_n

Frequency placeholder for use in lazy expressions (Matsubara naming).

Classes

Base(**kargs)

Base class for every Green's function descriptor.

BaseBlock(G, *args, **kw)

Block-aware descriptor base.

Const(C)

Constant descriptor.

Function(function)

Descriptor wrapping a Python callable.

LazyCTX(G)

Evaluation context used by __lshift__().

Omega_(**kargs)

Frequency-variable placeholder descriptor.