We propose a power penalty method for an obstacle problem arising from the discretization of an infinite-dimensional optimization problem involving differential operators in both its objective function and constraints. In this method we approximate the mixed nonlinear complementarity problem (NCP) arising from the KKT conditions of the discretized problem by a nonlinear penalty equation. We then show the solution to the penalty equation converges exponentially to that of the mixed NCP. Numerical results will be presented to demonstrate the theoretical convergence rates of the method. © 2013 Springer-Verlag Berlin Heidelberg.