Tight-binding Hamiltonian file format

See template, template2, template3.

This file should be readable by BasicTools/ReadRecord command, so the file structure is as follows (ordering of entries and empty lines are ignored):

# comment lines

SG=P21/c symmetry group recognized by SymmetryGroup command

orbs=[[1,3],[2,4]] optionally orbits of all sites (can be regenerated)

M=Matrix(3,3,[ matrix of translation vectors as columns
 a,0,cx,
 0,b,0,
 0,0,cz])

P=Matrix(3,ns,[ matrix of ns site positions in lattice coordinates as columns
 2/3,1/3,x3,...
 1/3,2/3,y3,...
 0,0,z3,...])

geoparams=[ table of geometrical parameter sets, missing parameters are considered as zero
"cryst-b_PBE-D3paw600" ==[ a=7.708771, b=20.410479, cx=+0.743021, c=25.106085, x=0.735272, y=-0.497682, z=-0.018511],
"cryst-bx_PBE-D3paw600"==[ a=8.565262, b=20.081321, cx=-0.490141, c=25.555564, x=0.709776, y=-0.490029, z=-0.024840],
...
NULL]

params=[ table of Hamiltonian parameter sets, missing parameters are considered as zero
 # optional description
"identifier" ==[ E0=-3.778, e1=-1.111, e2=2.222, t1=-2.887, t2=0.218, t3=-0.239, t3b=0.004, t4=0.046, t4b=-0.015, t5=0.001, t5c=-0.029, t5b=0.004],
 # optional description 2
id2          ==list(equation), E0 is optional onsite energy offset
...
NULL]

H=[ translationally unique matrix elements of the Hamiltonian (preferably fully unfolded by symmetry)
(s1,s2,t1,t2,t3,o1,o2 )==H6, matrix element between orbital o1 of site [s1,0,0,0] and orbital o2 of site [s2,t1,t2,t3],
( 1, 2,-1,-2, 1, 1, 2 )==H3, here s1,s2 enumerate sites in the unit cell and t1,t2,t3 define translations
( 1, 1, 0, 0, 0, 1, 1 )==eA1,
( 1, 1, 0, 0, 0, 1, 2 )==eAB1,
( 1, 1, 1, 0, 0, 1, 2 )==tAB11a, A,B,C,... correspond to orbitals 1,2,3,...
( 1, 1,-1, 0, 0, 1, 2 )==-tAB11a, symbolic expressions are allowed to enforce proper symmetry
( 1, 2, 0, 0, 0 )==t12, o1,o2 can be omitted if there is only one orbital per site
( 1, 2, 1, 1, 1 )==t12abc, a,b,c encode forward translations
( 2, 1,-1,-1,-1 )==t12ijk, i,j,k encode backward translations
( 2, 1, 2, 2,-3 )==t12aab2k3, aa=a2, b2=bb, k3=kkk
...
NULL]