Consider the following function $f(x)$ on $[a,c]$ for $a,c \in \mathbb{R}$
\begin{cases} h (x) &a< x<b \\ g(x) & b\leq x<c \end{cases} Assume h and g are $C^1$ on their intervals.
I wonder which condition need to be satisfied such that $f$ is in $H^1([a,c])$.
Actually there should be no problems since the functions are $C^1$ so the weak derivative coincides with the classical one. Is there a issue with my argumentation here?