train creation, insertion, accessor functions
added some time stepping