Since Diff does not have all pullbacks, to ensure that this definition makes sense, one needs to ensure that the space of composable morphisms is an object of Diff. This is achieved either by adopting the definition of internal groupoid in the sense of Ehresmann, which includes as data the smooth manifold of composable pairs, or by taking the conventional route and demanding that the source and target maps are submersions. This ensures the pullback exists to define said manifold or composable pairs.
But for most practical purposes, the apparently evident 2-category of such internal groupoids, internal functors and internal natural transformations is not the correct 2-category to consider. One way to see this is that the axiom of choice fails in Diff, which means that an internal functor of internal groupoids which is essentially surjective and full and faithful may nevertheless not be an equivalence, in that it may not have a weak inverse in .
See the section 2-Category of Lie groupoids below.
A bit more general than a Lie groupoid is a diffeological groupoid.
Originally Lie groupoids were called (by Ehresmann) differentiable groupoids (and also one considered differentiable categories). Sometime in the 1980s there was a change of terminology to Lie groupoid and differentiable stacks. (reference?)
One definition which Ehresmann introduced in his paper Catégories topologiques et catégories différentiables (see below) is that of locally trivial groupoid. It is defined more generally for topological categories, and extends in an obvious way to topological groupoids, and Lie categories and groupoids. For a topological (resp. Lie) category , let denote the subspace (resp. submanifold) of invertible arrows . (This always exists, by general abstract nonsense - I should look up the reference, it’s in Bunge-Pare I think - DR)
A topological groupoid is locally trivial if for every point there is a neighbourhood of and a lift of the inclusion through .
Clearly for a Lie groupoid . It is simple to show from the definition that for a transitive Lie groupoid, has local sections. Ehresmann goes on to show a link between smooth principal bundles and transitive, locally trivial Lie groupoids. See locally trivial category for details.
As usual for internal categories, the naive 2-category of internal groupoids, internal functors and internal natural transformations is not quite “correct”. One sign of this is that the axiom of choice fails in Diff so that an internal functor which is an essentially surjective functor and a full and faithful functor may still not have an internal weak inverse.
Another equivalent approach is to embed Lie groupoids into the context of 2-topos theory:
The (2,1)-topos of stacks/2-sheaves on Diff may be understood as a nice 2-category of general groupoids modeled on smooth manifolds. The degreewise Yoneda embedding allows to emebed groupoids internal to into stacks on . this wider context contains for instance also diffeological groupoids.
For more comments on this, see also the beginning of ∞-Lie groupoid.
The inner automorphism 2-group is a Lie groupoid. There is an obvious morphism .
The fundamental groupoid of a smooth manifold is naturally a Lie groupoid.
An orbifold is a Lie groupoid.
The (1-categorical) pullback
is a Lie groupoid equivalent to this principal bundle .
Similarly an anafunctor from to is a connection on a bundle (see there for details).
Topological and differentiable (or smooth, “Lie”) groupoids (and more generally categories) were introduced in
Reviews and developments of the theory of Lie groupoids include
The relation to differentiable stacks is discussed/reviewed in section 2 of
Expository discussion of various kinds of groupoids is also in