Vrms and equation integration This may be a electrical question but it involves integration so I am posting it in the math form:
I know that $$V_\left(t\right) = V_p*\sin{(2\pi*f*t)}$$
question 1: Can someone explain the meaning of following equation, how is Vrms equal to the right side?
$$V_{rms} = \sqrt{\frac{1}{T}*\int_0^T V_\left(t\right)^2dt}$$
question 2: The book integrate the function above and gets:
\begin{split}
=\frac{1}{\sqrt{2}}*V_p
\end{split}
but I can't get the result of above, this is my step:
\begin{equation}
\begin{split}
V_{rms} &= \sqrt{\frac{1}{T}*\int_0^T V_\left(t\right)^2dt} \\
&= \sqrt{\frac{1}{T}*\int_0^T V_p^2\sin^2{(2\pi ft)}dt} &\quad\text{(Step.1 substitute $V_\left(t\right)$ with $V_p*sin(2\pi ft)$)} \\ 
&= \sqrt{\frac{1}{T}V_p^2\int_0^T\sin^2{(2\pi ft)}dt} &\quad\text{(Step.2 $Vp$ is a constant, so I take it out)} \\
 \int_0^T\sin^2{(2\pi ft)}dt &=\left.\left(\frac{2\pi ft}{2}-\frac{\sin(4\pi ft)}{4}\right)\right|_0^T&\quad\text{(Step.3 integrate $sin^2(x))$}\\
&=\frac{2\pi fT}{2}-\frac{\sin(4\pi fT)}{2} - \frac{2\pi f0}{2}+\frac{\sin(4\pi f0)}{4} & \quad\text{(Step.4 expand)}\\
&= \pi f T&\quad\text{(Step.5 simplify)}\\
V_{rms} &= \sqrt{\frac{1}{T}V_p^2 \pi fT}& \quad\text{(Step.6 Combine step.5 and step.2)}\\
&= V_p \sqrt{\pi f}&\quad\text{(step.7 cancel $T$)}
\end{split}
\end{equation}
Which step did I do wrong?
EDIT: Oops, Step.3 is wrong, I forgot to pull out $2\pi f$

1) This is just the definition of root mean square. In the Wikipedia page, they also link it to voltage as you do.
2) $$\require{cancel} \begin{align} V_{rms}&=\sqrt{\frac1{T} \int_0^T \left(V_p \sin (2\pi ft)\right)^2 dt} \\&= \sqrt{\frac{V_p^2}{T} \int_0^T \sin^2(2\pi ft)\, dt} \\ &=\sqrt{\frac{V_p^2}{T}\left(\frac{t}{2}-\frac{\sin(4\pi f t)}{8\pi f} \Biggr|_{t=0}^{t=T}\right)} \\ &=\sqrt{\frac{V_P^2}{T}\left( \frac{T}{2} - \underbrace{\frac{\sin(4\pi \cancelto{1}{f T})}{8\pi f}}_{0}\right)} \\ &=\sqrt{\frac{V_P^2}{\cancel{T}}\left(\frac{\cancel{T}}{2}\right)} \\ \therefore &=\sqrt{\frac{V_P^2}{2}}\end{align}$$
