torsion/TD code now in wavefunction RHS