# Charge density required to create an electric field

Tags:
1. Mar 29, 2017

### Cepterus

1. The problem statement, all variables and given/known data
Given an electric field $$\vec E(x,y,z)=\begin{pmatrix}ax^2+bz\\cy\\bx\end{pmatrix},$$with nonzero constants $a,b,c$, I am supposed to find the charge density $\rho(x,y,z)$ which is necessary to create this field $\vec E$.

2. Relevant equations
$\rho=\frac{\mathrm dq}{\mathrm dV}$

3. The attempt at a solution
I know that electric fields are created by charges, but I don't understand the connection between charge density and an electric field. As far as I understand the above formula, charge density is simply the amount of charge in a certain volume. How does this relate to electric fields?

2. Mar 29, 2017

### BvU

You will need a different relevant equation: something like $\rho =\varepsilon_0\, \nabla \cdot \vec E$

3. Mar 29, 2017

### Cepterus

Thanks! I get the result $\rho(x,y,z)=\epsilon_0(2ax+c)$. If this is correct, what does it actually mean? Like, to create $\vec E$, should I start with zero charge on the $yz$-plane and then place linearly more and more charges in space the larger my distance to the $yz$-plane gets? (with the right sign, of course)