private String ShortenDirection(String d) throws Exception {
		String lowerD = d.toLowerCase().replaceAll("[^a-zA-Z0-9]","");
		if (lowerD.charAt(0) == 'n') {
			return "N";
		} else if (lowerD.charAt(0) == 's') {
			return "S";
		} else if  (lowerD.charAt(0) == 'e') {
			return "E";
		} else if (lowerD.charAt(0) == 'w') {
			return "W";
		} else {
			throw new Exception("Invalid direction");
		}
	}