\(\(\( (*\ The\ following\ notebook\ shows\ how, \ 
      using\ the\ Groebner\ basis\ algorithm\ NCProcess, \ 
      one\ can\ prove\ that\ if\ A\ and\ B\ are\ commuting\ matrices\ and\ A\ is\ EP, \ then\ B\ commutes\ with\ the\ pseudo - 
        inverse\ of\ A\ *) \)\(
\)\(
\)\(
\)\(\ \)\( (*\ 
      next\ line\ for\ PC\ only\ *) \)\(
\)\( (*\(Get["C:\NC\SetNCPath.m"];\)\ *) \)\(
\)\(<< 
      NCGB.m\)\)\)

<< NCMakeRelations.m;

SetNonCommutative[A, B, G, Q, iA];

TpCompinv1 = {A ** B - B ** A, -1 + G ** Inv[G], -1 + 
            Inv[G] ** G, Q + B ** iA - iA ** B, 
          iA ** A - Tp[A] ** Tp[iA], -iA ** A + 
            Tp[A] ** Tp[iA], -Tp[A] ** Tp[B] + Tp[B] ** Tp[A], 
          A - Tp[G] ** Tp[A], -A + Tp[G] ** Tp[A], -1 + 
            Tp[G] ** Tp[Inv[G]], -1 + Tp[Inv[G]] ** Tp[G], 
          A ** iA - Tp[iA] ** Tp[A], -A ** iA + Tp[iA] ** Tp[A], -A + 
            A ** iA ** A, -iA + iA ** A ** iA, A ** G - Tp[A], 
          Tp[A] ** Tp[iA] ** Tp[A] - Tp[A], -A ** G + 
            Tp[A], -Tp[B] ** Tp[iA] + Tp[iA] ** Tp[B] + Tp[Q], 
          Tp[iA] ** Tp[A] ** Tp[iA] - Tp[iA]};

ClearMonomialOrderAll[];

SetMonomialOrder[{{iA, Tp[iA], A, Tp[A], B, Tp[B], G, Inv[G], Tp[G], 
            Tp[Inv[G]]}, {Q, Tp[Q]}}];

FACans1 = 
        NCProcess[TpCompinv1, 4, 0, 0, 0, "AEPTheniABeqBiA", 
          SBByCat -> False, NCCV -> False, 
          NCGBNag -> True];

FACans1[[3]]