What is the electric field inside the sphere a radius r (the sphere has a radius a), and outside the sphere $R>a$? Given a sphere of volume: $$V=\frac{4}{3}\pi r^3$$
The sphere has a radius of $r=a$, calculate the electric field some radius $r$ within the sphere. Since it has uniform charge density I assume this: $$dQ=\rho \ dV$$
Then I use the following integral to make do of my calculations: $$E= k \int_\limits{r}^{a} \frac{dQ}{r^2}$$ I make this necessary substitution which leads me into the following: $$E=k\int_\limits{r}^{a}\frac{\rho}{r^2}dV$$ Afterwards I make usage of this $dV= 4 \pi r^2 \ dr$
Leading me to reduce my expression farther into this expression: $$E=k\int_\limits{r}^{a}\frac{4 \rho \pi r^2 }{r^2}dr $$
Which reduces to the following: $$E=k\int_\limits{r}^{a}4 \rho \pi \ dr$$
I assume this to be the answer:
$$E= 4k\rho \pi(a-r)$$
Using this method I calculated a radius R outside the sphere using the similar method which got me: $$E = 4 k \rho (R-a)$$
Consider a single point charge situated at the point ${\bf r_0}$. Its field: $$ {\bf E}({\bf r})=k\frac{{\bf r}-{\bf r_0}}{|{\bf r}-{\bf r_0}|^3} $$ is prominent by its unique property being divergenceless everywhere except for the origin: $$ \nabla\cdot {\bf E}({\bf r})=4\pi k\delta({\bf r}-{\bf r_0}). $$
Therefore by the divergence theorem the flux of the field through a closed surface is proportional to the charge contained inside the surface.
From the symmetry of your problem the field at a point is directed along the line connecting the point with the center of the sphere and depends only on the distance from the center $r$:
$$\begin{cases} r<a:& 4\pi r^2 E(r)=4\pi k\dfrac{4\pi}3 r^3 \rho \implies E(r)=k\dfrac{4\pi\rho}{3}r,\\ r>a:& 4\pi r^2 E(r)=4\pi k\dfrac{4\pi}3 a^3 \rho \implies E(r)=k\dfrac{4\pi\rho }{3}\dfrac{a^3}{r^2}. \end{cases} $$