# Eigen states

For a given operator ($H$) one can calculate the $N_{psi}$ lowest eigenstates with the function “Eigensystem()”. The function “Eigensystem()” uses iterative methods and needs as an input a starting point. This either can be a set of wavefunctions or a set of restrictions. If “Eigensystem()” is called with a set of starting functions the eigenstates found are those $N_{psi}$ with the lowest energy that have a nonzero matrix element of the operator $(H+1)^\infty$ with the starting state.

Example.Quanty
-- Eigenstates of the Lz operator
-- starting from a wavefunction
NF=6
NB=0
IndexDn={0,2,4}
IndexUp={1,3,5}
psip = NewWavefunction(NF, NB, {{"100000", math.sqrt(1/2)}, {"000010", math.sqrt(1/2)}})
OppLz = NewOperator("Lz", NF, IndexUp, IndexDn)
Eigensystem(OppLz,psip)

You do not need to specify a set of starting functions, but can specify a set of starting restrictions. If you want to find the lowest 3 eigenstates with two electrons in the $p$ shell one can set restrictions such that all orbitals in the $p$ shell are included in the counting and the occupation should be minimal 2 and maximal 2.

Example.Quanty
-- Eigenstates of the Lz operator
-- starting from a set of restrictions
NF=6
NB=0
IndexDn={0,2,4}
IndexUp={1,3,5}
OppLz = NewOperator("Lz", NF, IndexUp, IndexDn)
StartRestrictions = {NF, NB, {"111111",2,2}}
Npsi = 3
psiList = Eigensystem(OppLz, StartRestrictions, Npsi)

alligned paragraph text

## Example

description text

### Input

Example.Quanty
-- some example code

## Index

Workshops

Script versions External programs Privacy

##### Tools 