(14 points)
Find a context-free grammar equivalent to the grammar G below, such that the new grammar has no useless symbols. The symbol S is the start symbol of G.
S → AB | CD | EF | DE
A → aA | Aa
B → b | bB
C → c | cC
D → dC
E → eD | De
F → eA | Ae
H → gE | Eg