The domain of the Ornstein-Uhlenbeck operator on an $L^p$ space with invariant measure