Clean up on work file and Trajectories class