The first part of the book is devoted to the transport equation for a given vector field, exploiting the lagrangian structure of solutions. It also treats the regularity of solutions of some degenerate elliptic equations, which appear in the eulerian counterpart of some transport models with congestion. The second part of the book deals with the lagrangian structure of solutions of the Vlasov-Poisson system, which describes the evolution of a system of particles under the self-induced gravitational/electrostatic field, and the existence of solutions of the semigeostrophic system, used in meteorology to describe the motion of large-scale oceanic/atmospheric flows.