-- | Invert a typed graph morphism
invert :: TypedGraphMorphism a b -> TypedGraphMorphism a b
invert tgm =
  TypedGraphMorphism { domainGraph = codomainGraph tgm
                     , codomainGraph = domainGraph tgm
                     , mapping = GM.invertGraphMorphism (mapping tgm)
                     }
invert :: TypedGraphMorphism a b -> TypedGraphMorphism a b
invert tgm =
  TypedGraphMorphism { domainGraph = codomainGraph tgm
                     , codomainGraph = domainGraph tgm
                     , mapping = GM.invertGraphMorphism (mapping tgm)
                     }
invert tgm =
  TypedGraphMorphism { domainGraph = codomainGraph tgm
                     , codomainGraph = domainGraph tgm
                     , mapping = GM.invertGraphMorphism (mapping tgm)
                     }