added linear dtw