  We discuss the notion of basic cohomology for Dirac structures and, more
generally, Lie algebroids. We then use this notion to characterize the
obstruction to a variational formulation of Dirac dynamics.
