電気四重極子ポテンシャル

関数の定義

h=1.0;
r[x_,y_]:=(Sqrt[(x^2)+(y^2)]);

reg = 2;

ポテンシャル

Clear[x,y];h=1.0;q=0.1;
v[x_,y_]:=(q/(r[x-h,y-h]))+(q/(r[x+h,y+h]))-(q/(r[x-h,y+h]))-(q/(r[x+h,y-h]));
Vx = D[v[x,y], x];Vy = D[v[x,y], y];

contorpoints=Table[n,{n,-2,2,0.06}];
w6=ContourPlot[v[x,y],{x,-reg, reg}, {y, -reg, reg},
Frame->False,
Contours->contorpoints,
PlotRange->{-10,10},
MaxRecursion->3,
ContourShading->None,
ContourStyle->{{RGBColor[0,0,153/256],Thickness[0.003]}}
]

zr = 1.5;
G=Plot3D[v[x,y],{x,-reg, reg}, {y, -reg, reg},MaxRecursion->3,PlotRange->{-zr reg/2,zr reg/2},BoxRatios->{2,2,zr},Axes->False]

S1=Graphics3D[{Red,Sphere[{h,h,zr reg/2+0.05},0.1]}];
S2=Graphics3D[{Red,Sphere[{-h,-h,zr reg/2+0.05},0.1]}];
S3=Graphics3D[{Blue,Sphere[{-h,+h,-zr reg/2-0.05},0.1]}];
S4=Graphics3D[{Blue,Sphere[{+h,-h,-zr reg/2-0.05},0.1]}];
Show[G, S1, S2,S3,S4,
BoxRatios->{2,2,1.2 zr},
PlotRange->{{-reg,reg},{-reg,reg},{-1.2 zr reg/2,1.2  zr reg/2}},Axes->False
]