  In this article, we generalize the theory of discrete Lagrangian mechanics
and variational integrators in two principal directions. First, we show that
Lagrangian submanifolds of symplectic groupoids give rise to discrete dynamical
systems, and we study the properties of these systems, including their
regularity and reversibility, from the perspective of symplectic and Poisson
geometry. Next, we use this framework -- along with a generalized notion of
generating function due to Sniatycki and Tulczyjew -- to develop a theory of
discrete constrained Lagrangian mechanics. This allows for systems with
arbitrary constraints, including those which are non-integrable (in an
appropriate discrete, variational sense). In addition to characterizing the
dynamics of these constrained systems, we also develop a theory of reduction
and Noether symmetries, and study the relationship between the dynamics and
variational principles. Finally, we apply this theory to discretize several
concrete examples of constrained systems in mechanics and optimal control.
