Prove that if the partition $\textbf{P}'$ is finer than $\textbf{P}$, then $f$ keeps piecewise constant Let $I$ be a bounded interval, let $\textbf{P}$ be a partition of $I$, and let $f:I\to\textbf{R}$ be a function which is piecewise constant with respect to $\textbf{P}$. Let $\textbf{P}'$ be a partition of $I$ which is finer than $\textbf{P}$. Then $f$ is also piecewise constant with respect to $\textbf{P}'$.
MY ATTEMPT
Let $\textbf{P} = \{J_{1},J_{2},\ldots,J_{m}\}$ be a partition of $I$. Since $\textbf{P}'$ is finer than $\textbf{P}$, each bounded interval $J_{i}$ can be written as the disjoint union of bounded intervals
\begin{align*}
J_{i} = \bigcup_{j=1}^{n_{i}}K_{ij}
\end{align*}
where $\textbf{P}' = \{K_{11},\ldots,K_{1n_{1}},\ldots,K_{m1},\ldots,K_{mn_{m}}\}$. Thus, if $x\in K_{ij}$, then $x\in J_{i}$. Consequently, $f|_{K_{ij}} = f|_{J_{i}} = c_{i}$. That's to say, $f$ is also piecewise constant with respect to $\textbf{P}'$, and we are done.
Is there any theoretical flaw in my reasoning? Please let me know if it is the case.

How about proving it by using just definitions of piecewise constant function and refinement partitions?
Let P and $P'$ be partitions of I such that P' is finer than P.
Suppose $f : I \to R$ is a piecewise constant function with respect to P. So, $\forall$ K $\in$ $P'$ $\exists$ a $J\in P$ such that K$\subseteq$J.
Since f is a constant function on J and K$\subseteq$J, f is also constant on K $\forall$ $K\in P'$. Therefore, f is also piecewise constant with respect to $P'$.
