public static int calcMinEditDist(String original, String target) {
		int[][] minDistMap = new int[original.length() + 1][target.length() + 1];
		
		for(int i = 0; i <= original.length(); i++) {
			minDistMap[i][0] = costDelete * i;
		}
		
		for(int j = 0; j <= target.length(); j++) {
			minDistMap[0][j] = costInsert * j;
		}
		
		for(int i = 1; i <= original.length(); i++) {
			for(int j = 1; j <= target.length(); j++) {
				int minimum = Math.min(minDistMap[i - 1][j] + costDelete,
						minDistMap[i][j - 1] + costInsert);
				
				char c1 = original.charAt(i - 1);
				char c2 = target.charAt(j - 1);
				
				minimum = Math.min(minimum, 
						minDistMap[i - 1][j - 1] + getReplaceCost(c1, c2));
				
				minDistMap[i][j] = minimum;
			}
		}
		
		return minDistMap[original.length()][target.length()];
	}