Cosmetic change.
Rewrote name2tex routine and fixed bug.
Added unitary test for name2tex routine.