netket.symmetry.Representation#
- class netket.symmetry.Representation[source]#
Bases:
objectA representation of a group.
This is the central object for symmetrizing wavefunctions. The character table of the group of the representation indicates the various subspaces on which the wavefunction can be projected. A variational state
vstatecan be projected on the subspace associated to the characterkby callingrepresentation.project(vstate, k), which returns the new, projected variational state.For more details on the theory of representations of finite group and its application in variational Monte Carlo, we refer to Representation theory in NetKet.
For a tutorial of symmetrizing variational states in practice, we refer to the Symmetries, Representations and Projectors for arbitrary NQS.
- Inheritance

- __init__(group, representation_dict)[source]#
Construct a Representation.
- Parameters:
group (
FiniteGroup) – The group being represented.representation_dict (
dict[Element,DiscreteJaxOperator]) – The dictionary that defines the representation. Its keys must be the elements ofgroup. The value this dictionary associates to a group element is the operator that the representation maps this group element onto.
- Attributes
- character#
The vector storing the character of the representation.
Corresponds to
[op.trace() for (_, op) in self].Requires that each operator of the representation implements the trace method.
- representation_dict#
Dictionary associating every group element to a representation
Equivalent to {el: rep for (el, rep) in (self.group.elems, self.operators)}
- Methods
- irrep_subspace_dims()[source]#
Return the dimension of the subspace associated to each irreducible representation.
Requires that each operator of the representation implements the trace method.
- Return type:
- project(state, character_index=None, *, atol=1e-15, **kwargs)[source]#
Return the state projected onto the subspace associated to the irreducible representation specified by character_index.
Additional keyword arguments are forwarded to
projector(), so subclasses that acceptlabel=,k=, etc. can be used here too.
- projector(character_index, *, atol=1e-15)[source]#
Build the projection operator corresponding to a given irreducible representation.
As there might be some terms in the projector whose character is 0, we drop them by default according to a given absolute tolerance.
- Parameters:
- Return type:
- Returns:
A netket.operator.DiscreteJaxOperator that projects on the relevant subspace.
- symmetry_adapted_basis()[source]#
Return a tuple (mat, irrep_dims), where mat is the change of basis matrix associated to a symmetry adapted basis, and irrep_dims is an array giving the dimension of the subspace associated to each irreducible representation.
The basis vectors of mat are ordered by the index of their irreducible representation.