The Gauss–Ostrogradsky Formula for the Space of Configurations