[proofplan]
We first prove the result in the minimal case $u\in W^{1,1}(0,T;X)$, the Bochner-[Sobolev space](/page/Sobolev%20Space). Starting from the [weak derivative](/page/Weak%20Derivative) $v=\dot u$, we form the Bochner integral primitive $F(t)=\int_{[0,t]}v\,d\mathcal{L}^1$, which is absolutely continuous and has weak derivative $v$. The difference $u-F$ therefore has zero weak derivative; a localization and mollification argument shows that every $X$-valued locally integrable function with zero weak derivative is almost everywhere constant. Replacing the original equivalence class by the absolutely continuous representative $F+c$ gives the identity for all times, and the $W^{1,p}$ case follows from $L^p\subset L^1$ on finite measure intervals.
[/proofplan]
[step:Build the primitive of the weak derivative]
Throughout the proof, let $\mathcal{L}^1$ denote one-dimensional [Lebesgue measure](/page/Lebesgue%20Measure) on $\mathbb{R}$, and let $|x|$ denote the norm of a vector $x\in X$. The space $L^1(0,T;X)$ denotes the Bochner space of strongly measurable maps $f:(0,T)\to X$ satisfying
\begin{align*}
\int_{(0,T)} |f(r)|\,d\mathcal{L}^1(r)<\infty.
\end{align*}
The test-function space $C_c^\infty(0,T)$ denotes the space of smooth scalar functions $\varphi:(0,T)\to\mathbb{R}$ with compact support in $(0,T)$.
Let
\begin{align*}
v:(0,T)\to X
\end{align*}
denote the weak derivative of $u$, so $v=\dot u$ in $L^1(0,T;X)$. Define the Bochner primitive as the map
\begin{align*}
F:[0,T]\to X.
\end{align*}
For each $t\in[0,T]$, set
\begin{align*}
F(t)=\int_{[0,t]} v(r)\,d\mathcal{L}^1(r).
\end{align*}
By the absolute [continuity theorem](/theorems/1145) for the Bochner integral, whose scalar majorant is the absolute continuity theorem for the [Lebesgue integral](/page/Lebesgue%20Integral) applied to $|v|\in L^1(0,T)$, $F$ is absolutely continuous as an $X$-valued map: if $\{(a_j,b_j)\}_{j=1}^N$ is a finite pairwise disjoint family of subintervals of $[0,T]$, then
\begin{align*}
\sum_{j=1}^N |F(b_j)-F(a_j)| \leq \sum_{j=1}^N \int_{(a_j,b_j)} |v(r)|\,d\mathcal{L}^1(r)
= \int_{\bigcup_{j=1}^N(a_j,b_j)} |v(r)|\,d\mathcal{L}^1(r).
\end{align*}
Since $|v|\in L^1(0,T)$, the right-hand side is small whenever the total length of the union is small.
We also record that $F$ has [weak derivative](/page/Weak%20Derivative) $v$. Indeed, for every scalar [test function](/page/Test%20Function)
\begin{align*}
\varphi:(0,T)\to\mathbb{R}, \qquad \varphi\in C_c^\infty(0,T),
\end{align*}
define the indicator map
\begin{align*}
\mathbb{1}_{[0,t]}:(0,T)\to\{0,1\}
\end{align*}
by setting $\mathbb{1}_{[0,t]}(r)=1$ when $r\in[0,t]$ and $\mathbb{1}_{[0,t]}(r)=0$ otherwise. The map $(r,t)\mapsto \mathbb{1}_{[0,t]}(r)\varphi'(t)v(r)$ is Bochner integrable on $(0,T)\times(0,T)$ because
\begin{align*}
\int_{(0,T)}\int_{(0,T)} \mathbb{1}_{[0,t]}(r)|\varphi'(t)|\,|v(r)|\,d\mathcal{L}^1(r)\,d\mathcal{L}^1(t)
\leq T\|\varphi'\|_{\infty}\int_{(0,T)}|v(r)|\,d\mathcal{L}^1(r)<\infty.
\end{align*}
Thus the Bochner-[Fubini theorem](/theorems/513) for Bochner-integrable functions on product measure spaces applies, since the displayed scalar majorant is integrable, and gives
\begin{align*}
\int_{(0,T)} F(t)\varphi'(t)\,d\mathcal{L}^1(t)
= \int_{(0,T)}\left(\int_{[0,t]}v(r)\,d\mathcal{L}^1(r)\right)\varphi'(t)\,d\mathcal{L}^1(t).
\end{align*}
Changing the order of integration gives
\begin{align*}
\int_{(0,T)} F(t)\varphi'(t)\,d\mathcal{L}^1(t)
= \int_{(0,T)} v(r)\left(\int_{[r,T]}\varphi'(t)\,d\mathcal{L}^1(t)\right)d\mathcal{L}^1(r).
\end{align*}
Because $\varphi$ has compact support in $(0,T)$, $\varphi(T)=0$, and the scalar [Fundamental Theorem of Calculus](/theorems/632) gives
\begin{align*}
\int_{[r,T]}\varphi'(t)\,d\mathcal{L}^1(t)=-\varphi(r).
\end{align*}
Hence
\begin{align*}
\int_{(0,T)} F(t)\varphi'(t)\,d\mathcal{L}^1(t)
= -\int_{(0,T)} v(r)\varphi(r)\,d\mathcal{L}^1(r).
\end{align*}
Thus the weak derivative of $F$ is $v$.
[guided]
The object we want is the time integral of the weak derivative. Since $v=\dot u$ belongs to $L^1(0,T;X)$, the Bochner integral over every measurable subinterval of $(0,T)$ is defined. We therefore define the map
\begin{align*}
F:[0,T]\to X.
\end{align*}
For each $t\in[0,T]$, set
\begin{align*}
F(t)=\int_{[0,t]} v(r)\,d\mathcal{L}^1(r).
\end{align*}
Why is this the right candidate? If the theorem is true, then after choosing the correct representative one should have $u(t)-u(0)=\int_{[0,t]}\dot u(r)\,d\mathcal{L}^1(r)$. Thus $F$ is the part of $u$ determined by its derivative.
First, $F$ is absolutely continuous. Let $\{(a_j,b_j)\}_{j=1}^N$ be pairwise disjoint subintervals of $[0,T]$. The additivity of the Bochner integral and the triangle inequality in $X$ give
\begin{align*}
\sum_{j=1}^N |F(b_j)-F(a_j)| \leq \sum_{j=1}^N \int_{(a_j,b_j)} |v(r)|\,d\mathcal{L}^1(r).
\end{align*}
Since the intervals are disjoint, the sum on the right is the integral over their union:
\begin{align*}
\sum_{j=1}^N |F(b_j)-F(a_j)|
\leq \int_{\bigcup_{j=1}^N(a_j,b_j)} |v(r)|\,d\mathcal{L}^1(r).
\end{align*}
The scalar function $|v|$ is integrable on $(0,T)$, so the absolute continuity theorem for the Lebesgue integral applies to $|v|$ and implies that the last expression is small whenever the union has sufficiently small $\mathcal{L}^1$-measure. This is exactly absolute continuity of $F$ as an $X$-valued function.
Next we verify that the weak derivative of $F$ is $v$. Let
\begin{align*}
\varphi:(0,T)\to\mathbb{R}
\end{align*}
be a test function with $\varphi\in C_c^\infty(0,T)$. We compute the [distributional derivative](/page/Distributional%20Derivative) by testing against $\varphi'$. By definition of $F$,
\begin{align*}
\int_{(0,T)} F(t)\varphi'(t)\,d\mathcal{L}^1(t)
= \int_{(0,T)}\left(\int_{[0,t]}v(r)\,d\mathcal{L}^1(r)\right)\varphi'(t)\,d\mathcal{L}^1(t).
\end{align*}
The integrand is Bochner integrable because $\varphi'$ is bounded and $v\in L^1(0,T;X)$. More explicitly,
\begin{align*}
\int_{(0,T)}\int_{(0,T)} \mathbb{1}_{[0,t]}(r)|\varphi'(t)|\,|v(r)|\,d\mathcal{L}^1(r)\,d\mathcal{L}^1(t)
\leq T\|\varphi'\|_{\infty}\int_{(0,T)}|v(r)|\,d\mathcal{L}^1(r)<\infty.
\end{align*}
Therefore the Bochner-Fubini theorem permits us to reverse the order of integration:
\begin{align*}
\int_{(0,T)} F(t)\varphi'(t)\,d\mathcal{L}^1(t)
= \int_{(0,T)} v(r)\left(\int_{[r,T]}\varphi'(t)\,d\mathcal{L}^1(t)\right)d\mathcal{L}^1(r).
\end{align*}
Since $\varphi$ has compact support in $(0,T)$, its value at the endpoint $T$ is zero. The scalar [Fundamental Theorem of Calculus](/theorems/632) therefore gives
\begin{align*}
\int_{[r,T]}\varphi'(t)\,d\mathcal{L}^1(t)=\varphi(T)-\varphi(r)=-\varphi(r).
\end{align*}
Substituting this identity gives
\begin{align*}
\int_{(0,T)} F(t)\varphi'(t)\,d\mathcal{L}^1(t)
= -\int_{(0,T)} v(r)\varphi(r)\,d\mathcal{L}^1(r).
\end{align*}
This is precisely the definition of having weak derivative $v$.
[/guided]
[/step]
[step:Show that the difference has zero weak derivative]
Define the map
\begin{align*}
w:(0,T)\to X.
\end{align*}
For each $t\in(0,T)$, set
\begin{align*}
w(t)=u(t)-F(t),
\end{align*}
where $u$ denotes any representative of its $L^1(0,T;X)$ equivalence class. Since $u,F\in L^1(0,T;X)$, the map $w$ belongs to $L^1(0,T;X)$. The weak derivative of $u$ is $v$, and the previous step shows that the weak derivative of $F$ is also $v$. Therefore, for every $\varphi\in C_c^\infty(0,T)$,
\begin{align*}
\int_{(0,T)} w(t)\varphi'(t)\,d\mathcal{L}^1(t)=0.
\end{align*}
Thus $w$ has zero weak derivative on $(0,T)$.
[/step]
[step:Prove that an $X$-valued function with zero weak derivative is constant almost everywhere]
We prove the following auxiliary fact.
[claim:Zero weak derivative implies local constancy almost everywhere]
Let $I\subset\mathbb{R}$ be an open interval and let
\begin{align*}
z:I\to X
\end{align*}
belong to $L^1_{\mathrm{loc}}(I;X)$, where $L^1_{\mathrm{loc}}(I;X)$ denotes the space of strongly measurable maps whose restriction to every compact subinterval of $I$ belongs to $L^1$ with respect to $\mathcal{L}^1$. If
\begin{align*}
\int_I z(t)\psi'(t)\,d\mathcal{L}^1(t)=0
\end{align*}
for every $\psi\in C_c^\infty(I)$, then there exists $c\in X$ such that $z(t)=c$ for $\mathcal{L}^1$-a.e. $t\in I$.
[/claim]
[proof]
Let $J=(\alpha,\beta)$ be an open interval with compact closure contained in $I$. Choose $\varepsilon_0>0$ such that $(\alpha-\varepsilon_0,\beta+\varepsilon_0)\subset I$. Let
\begin{align*}
\eta:\mathbb{R}\to[0,\infty)
\end{align*}
be a standard smooth mollifier with $\eta\in C_c^\infty((-1,1))$ and
\begin{align*}
\int_{\mathbb{R}}\eta(r)\,d\mathcal{L}^1(r)=1.
\end{align*}
For $0<\varepsilon<\varepsilon_0$, define the map
\begin{align*}
\eta_\varepsilon:\mathbb{R}\to[0,\infty).
\end{align*}
For each $r\in\mathbb{R}$, set
\begin{align*}
\eta_\varepsilon(r)=\varepsilon^{-1}\eta(r/\varepsilon).
\end{align*}
Define the mollified function as the map
\begin{align*}
z_\varepsilon:J\to X.
\end{align*}
For each $t\in J$, set
\begin{align*}
z_\varepsilon(t)=\int_I \eta_\varepsilon(t-r)z(r)\,d\mathcal{L}^1(r).
\end{align*}
The integral is over a compact subset of $I$ because $\eta_\varepsilon(t-\cdot)$ is supported in $(t-\varepsilon,t+\varepsilon)\subset I$ for $t\in J$.
For $t\in J$, differentiation under the Bochner integral is justified by the Bochner-valued [dominated convergence theorem](/theorems/4) applied to the difference quotients of the smooth compactly supported kernel. Indeed, for $h$ sufficiently small, the supports of $r\mapsto \eta_\varepsilon(t+h-r)$ and $r\mapsto \eta_\varepsilon(t-r)$ lie in a fixed compact subinterval of $I$, while the scalar difference quotients are bounded there by $\|\eta_\varepsilon'\|_\infty |z(r)|$, which is integrable on that compact subinterval because $z\in L^1_{\mathrm{loc}}(I;X)$. Hence
\begin{align*}
z_\varepsilon'(t)=\int_I \eta_\varepsilon'(t-r)z(r)\,d\mathcal{L}^1(r).
\end{align*}
For fixed $t\in J$, define the scalar function
\begin{align*}
\psi_t:I\to\mathbb{R}.
\end{align*}
For each $r\in I$, set
\begin{align*}
\psi_t(r)=-\eta_\varepsilon(t-r).
\end{align*}
Then $\psi_t$ belongs to $C_c^\infty(I)$ and satisfies $\psi_t'(r)=\eta_\varepsilon'(t-r)$. The zero-derivative hypothesis applied to $\psi_t$ gives
\begin{align*}
z_\varepsilon'(t)=\int_I z(r)\psi_t'(r)\,d\mathcal{L}^1(r)=0.
\end{align*}
Hence $z_\varepsilon$ is constant on $J$ for every $0<\varepsilon<\varepsilon_0$.
We justify the Bochner-valued mollifier approximation on $J$. Choose an open interval $J'\subset I$ such that $\overline{J}\subset J'$ and $\overline{J'}\subset I$. Since $z\in L^1_{\mathrm{loc}}(I;X)$, the restricted map $z|_{J'}$ belongs to $L^1(J';X)$. Extend $z|_{J'}$ by zero to a map $\bar z:\mathbb{R}\to X$. The Bochner-valued mollifier approximation theorem applies because $\bar z\in L^1(\mathbb{R};X)$ and $\eta_\varepsilon$ is a standard approximate identity; it gives
\begin{align*}
\eta_\varepsilon * \bar z\to \bar z
\end{align*}
in $L^1(\mathbb{R};X)$ as $\varepsilon\downarrow0$. For all sufficiently small $\varepsilon$, the support of $r\mapsto \eta_\varepsilon(t-r)$ is contained in $J'$ for every $t\in J$, so $z_\varepsilon(t)=(\eta_\varepsilon *\bar z)(t)$ on $J$. Restricting the convergence from $\mathbb{R}$ to $J$ gives
\begin{align*}
z_\varepsilon\to z
\end{align*}
in $L^1(J;X)$ as $\varepsilon\downarrow0$. Since each $z_\varepsilon$ is constant on $J$, there are vectors $c_\varepsilon\in X$ with $z_\varepsilon(t)=c_\varepsilon$ for all $t\in J$. The convergence in $L^1(J;X)$ implies that $(c_\varepsilon)$ is a Cauchy net in $X$ along $\varepsilon\downarrow0$, because
\begin{align*}
|c_\varepsilon-c_\delta|
= \frac{1}{\mathcal{L}^1(J)}\int_J |z_\varepsilon(t)-z_\delta(t)|\,d\mathcal{L}^1(t).
\end{align*}
Since $X$ is complete, $c_\varepsilon\to c_J$ for some $c_J\in X$. Therefore
\begin{align*}
\int_J |z_\varepsilon(t)-c_J|\,d\mathcal{L}^1(t)=\mathcal{L}^1(J)|c_\varepsilon-c_J|\to0.
\end{align*}
Thus $z_\varepsilon\to c_J$ in $L^1(J;X)$. By [uniqueness of limits](/theorems/625) in the normed space $L^1(J;X)$, $z=c_J$ in $L^1(J;X)$, hence $z(t)=c_J$ for $\mathcal{L}^1$-a.e. $t\in J$.
Exhaust $I$ by an increasing sequence of open intervals $J_m$ with compact closure in $I$. The constants obtained on overlaps agree because the overlaps have positive measure and both constants equal $z$ almost everywhere there. Hence a single vector $c\in X$ satisfies $z(t)=c$ for $\mathcal{L}^1$-a.e. $t\in I$.
[/proof]
Applying the claim with $I=(0,T)$ and $z=w$, there exists $c\in X$ such that
\begin{align*}
w(t)=c
\end{align*}
for $\mathcal{L}^1$-a.e. $t\in(0,T)$.
[/step]
[step:Choose the continuous representative and prove the integral identity]
Define the map
\begin{align*}
\widetilde u:[0,T]\to X.
\end{align*}
For each $t\in[0,T]$, set
\begin{align*}
\widetilde u(t)=c+F(t).
\end{align*}
Since $F$ is absolutely continuous, $\widetilde u$ is absolutely continuous and therefore continuous on $[0,T]$. The previous step gives
\begin{align*}
u(t)=\widetilde u(t)
\end{align*}
for $\mathcal{L}^1$-a.e. $t\in(0,T)$, so $\widetilde u$ is a representative of the original Bochner-Sobolev equivalence class. We replace $u$ by this representative.
For $0\le s\le t\le T$, additivity of the Bochner integral gives
\begin{align*}
u(t)-u(s)
= F(t)-F(s)
= \int_{[0,t]}v(r)\,d\mathcal{L}^1(r)-\int_{[0,s]}v(r)\,d\mathcal{L}^1(r).
\end{align*}
Therefore
\begin{align*}
u(t)-u(s)=\int_{[s,t]}v(r)\,d\mathcal{L}^1(r).
\end{align*}
Since $v=\dot u$, this is exactly
\begin{align*}
u(t)-u(s)=\int_{[s,t]}\dot u(r)\,d\mathcal{L}^1(r).
\end{align*}
[/step]
[step:Deduce the statement for $W^{1,p}(0,T;X)$]
Let $1\le p\le\infty$ and suppose $u\in W^{1,p}(0,T;X)$. For $1\le p<\infty$, the space $L^p(0,T;X)$ denotes the Bochner space of strongly measurable maps $f:(0,T)\to X$ with $\int_{(0,T)}|f(r)|^p\,d\mathcal{L}^1(r)<\infty$. The space $L^\infty(0,T;X)$ denotes the Bochner space of strongly measurable maps whose essential supremum norm is finite. Then $u\in L^p(0,T;X)$ and $\dot u\in L^p(0,T;X)$. Because $\mathcal{L}^1((0,T))=T<\infty$, Hölder's inequality applies to the scalar functions $|\dot u|$ and $1$. For $1<p<\infty$, define the conjugate exponent $p'$ by
\begin{align*}
p'=\frac{p}{p-1}.
\end{align*}
Then
\begin{align*}
\int_{(0,T)} |\dot u(r)|\,d\mathcal{L}^1(r)
\leq \|\dot u\|_{L^p(0,T;X)}\|1\|_{L^{p'}(0,T)}
= T^{1-1/p}\|\dot u\|_{L^p(0,T;X)}.
\end{align*}
For $p=1$, the same estimate is the identity
\begin{align*}
\int_{(0,T)} |\dot u(r)|\,d\mathcal{L}^1(r)=\|\dot u\|_{L^1(0,T;X)}.
\end{align*}
For $p=\infty$,
\begin{align*}
\int_{(0,T)} |\dot u(r)|\,d\mathcal{L}^1(r)
\leq T\|\dot u\|_{L^\infty(0,T;X)}.
\end{align*}
Thus $\dot u\in L^1(0,T;X)$, and similarly $u\in L^1(0,T;X)$. Hence $u\in W^{1,1}(0,T;X)$, and the result already proved applies. The representative obtained above is absolutely continuous, belongs to $C([0,T];X)$, and satisfies
\begin{align*}
u(t)-u(s)=\int_{[s,t]}\dot u(r)\,d\mathcal{L}^1(r)
\end{align*}
for every $0\le s\le t\le T$.
[/step]