Dynamic time warping in the modelling of chemical batch reactors