Prob. 21, Sec. 17 in Munkres' TOPOLOGY, 2nd ed: Closure and complementation can result in at most 14 different sets

Solution 1:

Note also that $$iA\subseteq A\subseteq fA$$ and $$A\subseteq B\implies fA\subseteq fB,\ iA\subseteq iB.$$

From $$fgA=giA,$$ it follows that $$gfgA=ggiA=iA$$ and $$fgfgA=fiA;$$ thus the equality $$fgfgfgfgA=fgfgA$$ can be rewritten in the form $$fifiA=fiA,$$ which I will now prove.

$\underline{fifiA\subseteq fi A}$: From $$ifiA\subseteq fiA$$ it follows that $$fifiA\subseteq ffiA=fiA.$$

$\underline{fiA\subseteq fifiA}$: From $$iA\subseteq fiA$$ it follows that $$iA=iiA\subseteq ifiA$$ and $$fiA\subseteq fifiA.$$

Substituting $gA$ for $A$ in the previous identity, we have $$fgfgfgfg(gA)=fgfg(gA),$$ i.e., $$fgfgfgfA=fgfA;$$ taking complements, $$gfgfgfgfA=gfgfA.$$