# Piecewise Ito formula

Usually Ito's lemma is stated for $C^{1,2}(\mathbb{R}^{d+1},\mathbb{R})$ functions.

My question is does Ito still hold if the domain is restricted. That is if the semi-martingale $Z_t$ is only considered on $[t_1,t_2]\times B$ where B is an open ball in $\mathbb{R}^d$ and $f$ is $C^{1,2}$ thereon then does the Ito formula still hold?

More generally,what i need precisely is to know if $f$ is a piecewise $C^{1}$ function in the time parameter and twice differentiable in the space parameter, then does Ito still hold? If not can it be modified, if so how?

References are always welcome.

Let B a open ball of $\mathbb{R}^d$ Let I be a open time interval. Let f be $C^{1,2}(I,B)$. Let $A\subset B$ strictly in $B$ (you take margins wrt to the boundary). Let $t_1,t_2\in I$ with $t_1 <t_2$ and $x\in B$
Then define $\tau$ the exit time of $A$ starting from $t_1,x$
You can now write Ito lemma between $t_1$ and $\min (\tau ,t_2)$