The self financing portfolio is given by:
$V_t$ = $a_t$$S_t$ + $b_t$$\beta_t$
where $dS_t$ = 2$S_t$dt + 4$S_t$d$B_t$ and $a_t$ = -t and $b_t$ = $\int_0^tS_u du$ and $\beta_t$ = 1 hence
$V_t$ = -t$S_t$ + $\int_0^tS_u du$
I believe we are suppose to use the chain rule and get the answer:
d$V_t$ = -t d$S_t$ - $S_t$dt + $S_t$dt
But I am not sure how to use the chain rule here and differentiate the integral.
Recall the the product rule and Fundamental Theorem of Calculus.
We have:
$$\frac {dV_t}{dt} = \frac {d}{dt}(-tS_t)+\frac {d}{dt}\int_0^tS_udu=\left(-S_t-t\frac{dS_t}{dt}\right) + S_t$$
Giving:
$$dV_t = -tdS_t-S_tdt+S_tdt$$