// // LinearWindow.h // FastDTW-x // // Created by Melo Yao on 12/5/13. // Copyright (c) 2013 melo.yao. All rights reserved. // #ifndef __FastDTW_x__LinearWindow__ #define __FastDTW_x__LinearWindow__ #include "Foundation.h" #include "SearchWindow.h" #include "TimeSeries.h" #include #include "FDMath.h" FD_NS_START class LinearWindow : public SearchWindow { public: template LinearWindow(const TimeSeries& tsI, const TimeSeries& tsJ, JInt searchRadius):SearchWindow(tsI.size(),tsJ.size()) { JDouble ijRatio = tsI.size()/(JDouble)tsJ.size(); JBool isIlargest = tsI.size() >= tsJ.size(); for (JInt i = 0; i