Let $n \in \mathbb N$, let $U \subset \mathbb R^n$ be open, and let $f: U \to \mathbb R$ be a function. Then $f \in C^2(U)$ if and only if for every $x \in U$ there exists an [open set](/page/Open%20Set) $V_x \subset U$ with $x \in V_x$ such that $f|_{V_x} \in C^2(V_x)$.