I am trying to remove ϵ rules from the following grammar (after applying the remove redundant symbols algorithm): $G = (\{S,A,B,C\},\{0,1\},P,S)$, where the productions are
\begin{align} &S \to AB \mid C \\ & A \to 0A1 \mid \epsilon \\ &B \to 0B \mid 0 \\ &C \to 0C0 \mid B \end{align}
The result of applying the remove ϵ rules algorithm is:
\begin{align} &S \to B \mid C \mid AB \\ &A \to 0A1 \\ &B \to 0B \mid 0 \\ &C \to 0C0 \mid B \end{align}
but then, when I re-apply the remove redundant symbols algorithm (as I should do) I get:
\begin{align} &S\to B \mid C \\ &B \to 0B \mid 0 \\ &C \to 0C0 \mid B \end{align}
(as $A \Rightarrow^*$ will never result in a terminal word)
The problem is, that $010$ is generated by the original grammar but not by the latter grammar.
in fact, not a single word that contains 1 in it belongs to the latter grammar, as 1 could only have been achieved via $A$!
What have I done wrong? Why are the two grammars producing different languages? They are supposed to be the same.