class_docstr: A class representing group homomorphisms. Instantiate using `homomorphism()`.
  
  References
  ==========
  
  .. [1] Holt, D., Eick, B. and O'Brien, E. (2005). Handbook of computational group theory.
code: def _compute_kernel(self):
      G = self.domain
      G_order = G.order()
      if G_order is S.Infinity:
          raise NotImplementedError(
              "Kernel computation is not implemented for infinite groups"
          )
      gens = []
      if isinstance(G, PermutationGroup):
          K = PermutationGroup(G.identity)
      else:
          K = FpSubgroup(G, gens, normal=True)
      i = self.image().order()
      while K.order() * i != G_order:
          r = G.random()
          k = r * self.invert(self(r)) ** -1
          if k not in K:
              gens.append(k)
              if isinstance(G, PermutationGroup):
                  K = PermutationGroup(gens)
              else:
                  K = FpSubgroup(G, gens, normal=True)
      return K
  
imports: import itertools
  from sympy.combinatorics.fp_groups import FpGroup, FpSubgroup, simplify_presentation
  from sympy.combinatorics.free_groups import FreeGroup
  from sympy.combinatorics.perm_groups import PermutationGroup
  from sympy.core.intfunc import igcd
  from sympy.ntheory.factor_ import totient
  from sympy.core.singleton import S
label_desc: Use image node_id 5 for calling the GroupHomomorphism obj's underlying member method code with example usage: obj._compute_kernel() and returns: K