Teg: Grain Structure