In [3]:
# dependencies should be installed
import numpy as np
import pandas as pd
In [4]:
from tensormoments import io
from tensormoments import tools
In [5]:
# read the elk output file and transform it into a pandas data frame
df = io.makeDataframe(io.readVaspOutput('TENSMOM.R1.OUT'))
In [7]:
# transform from (complex) spherical harmonics to real spherical harmonics
real_df = tools.transformFrameToReal(df)
In [11]:
# filter for a specific component
# one can leave out any of the arguments except for the first
tools.filterTmoms(real_df, l1=1, l2=2, nu=1, k=1, p=1, r=0)
Out[11]:
In [12]:
# look at toroidal moment of first atom
tools.filterTmoms(real_df, l1=1, l2=2, nu=1, k=1, p=1, r=1, atom=1)
Out[12]:
In [13]:
# look at quadrupole of first atom
tools.filterTmoms(real_df, l1=1, l2=2, nu=1, k=1, p=1, r=2, atom=1)
Out[13]:
In [ ]: