Mar 01, 2006 16:38
k=8.99*10^9;
q1=10*10^(-6);
q2=q1;q3=q1;
d=.0001:.00001:.01;
theta1=tan(2);
theta2=pi-theta1;
r1=sqrt(((d.^2)/4)+ d.^2);
r2=r1; r3=2.*d;
e1=(k*q1)./(r1.^2);
e2=(k*q2)./(r2.^2);
e3=(k*q2)./(r3.^2);
ex1=e1*cos(theta1);
ex2=e2*cos(theta2);
ex3=0;
ey1=e1*sin(theta1);
ey2=e2*sin(theta2);
ey3=e3;
Extot=ex1+ex2+ex3;
Eytot=ey1+ey2+ey3;
Enet=sqrt(Extot.^2+Eytot.^2);
Test=2.039*(k*q1./(d.^2));
plot(d, Enet);
grid on