The voltage $v$ across a device and the current $i$ through it are
\[v(t)=5 \cos 2 t \mathrm{V}, \quad i(t)=10\left(1-e^{-0.5 t}\right) \mathrm{A}\]
Calculate:
(a) the total charge in the device at $t=1$ s
(b) the power consumed by the device at $t=1$ s.