added trialfun for linear track