Structure of Hochschild cohomology of path algebras and differential formulation of Euler's polyhedron formula