Mathematica8の機能のみを使い電気力線を描く

関数の定義

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

reg = 2;

正負の等量電荷の電気力線

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

points=Table[{0.20 Cos [θ]+h, 0.20 Sin[θ]},{θ,0,2 π-0.001`,(π/6)} ];(*指定点が原点に近すぎるとうまくいかない*)
w0=StreamPlot[{-Vx, -Vy},{x,0, reg}, {y, -reg, reg},
StreamPoints->points,
StreamStyle->{Black,Arrowheads[{{0.08, 0.5}}]},(*流線の真ん中を矢印とする．0.04は鏃の大きさ．*)
StreamScale->Full,
PlotRangePadding->None,
Frame->False,
AspectRatio->2.0,
PerformanceGoal->"Quality"
]

w1=StreamPlot[{-Vx, -Vy},{x,-reg, reg}, {y, -reg, reg},
StreamPoints->points,
StreamStyle->{Black,Arrowheads[{{0.04, 0.5}}]},(*流線の真ん中を矢印とする．0.04は鏃の大きさ．*)
StreamScale->Full,
PlotRangePadding->None,
Frame->False,
PerformanceGoal->"Quality"
]

points=Table[{0.2 Cos [θ]-h, 0.2 Sin[θ]},{θ,(π/2)+(π/6),((3 π)/2)-(π/6)+0.001`,(π/6)} ];
w3=StreamPlot[{-Vx, -Vy},{x,-reg, reg}, {y, -reg, reg},
StreamPoints->points,
StreamStyle->{Black,Arrowheads[{{0.04, 0.5}}]},(*流線の真ん中を矢印とする．0.04は鏃の大きさ．*)
StreamScale->Full,
PlotRangePadding->None,
Frame->False,
PerformanceGoal->"Quality"
]

w5=Show[w1,w3,  PlotRange->{{-reg,reg},{-reg,reg}}]

contorpoints=Table[n,{n,-10,10,0.3}];
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]}}
]

Show[w5,w6,  PlotRange->{{-reg,reg},{-reg,reg}}]

Show[w0,w6,  
PlotRange->{{0,reg},{-reg,reg}}
]