public void removeProduction(Production production) {
		myProductions.remove(production);
		GrammarChecker gc = new GrammarChecker();
		/**
		 * Remove any variables that existed only in the production being
		 * removed.
		 */
		String[] variablesInProduction = production.getVariables();
		for (int k = 0; k < variablesInProduction.length; k++) {
			if (!GrammarChecker.isVariableInProductions(this,
					variablesInProduction[k])) {
				removeVariable(variablesInProduction[k]);
			}
		}

		/**
		 * Remove any terminals that existed only in the production being
		 * removed.
		 */
		String[] terminalsInProduction = production.getTerminals();
		for (int i = 0; i < terminalsInProduction.length; i++) {
			if (!GrammarChecker.isTerminalInProductions(this,
					terminalsInProduction[i])) {
				removeTerminal(terminalsInProduction[i]);
			}
		}
	}