The length of a rectangular park is twice its width. The park is surrounded by a 2​-foot-wide path. Let x denote the width of the park. Write a quadratic function to represent the total area of the park and the path.