public int getInverse(int m, int n) {
		 if (n >= 4) {
				int j = 0;
				
				while (2 * getValue(m, j) <= n && getValue(m, j) != -1) {
					j++;
				}
				
				return j - 1;
		} else if (m >= n) {
				int i = 1;
				
				while (getValue(i, (int)Math.floor(m / n)) != -1) {
					i++;
				}
				
				return i;
		}
		
		return -1;
	}