@Test
public void testDistanceCalculationWithWindow() {

	// Input.
	double[] timeSeries3 = { 0.50, 0.87, 0.90, 0.82, 0.70 };
	double[] timeSeries4 = { 0.10, 0.10, 0.10, 0.10, 0.10 };
	// Expectation.
	double expectation = 3.29;
	DynamicTimeWarping dtw = new DynamicTimeWarping();
	double distance = dtw.distanceWithWindow(timeSeries3, timeSeries4, 10000);
	assertEquals(expectation, distance, 1.0E-5);
}