Replace weightNum with $weightNum
Merge branch 'LGC' into halfwidth