User:Tom Allen/TensorExperimentsR16
Jump to navigation
Jump to search
... charge negative (_0.5) ...
vSgDd2M=.[([(0{])@rfE1cn xRef@hkxR03),:@(S03xH{]) vSgDd2 =.gXR(-@(([([(0{])@ch2k xRef@hkxR03),:@(S03xH{]))+/"1@((<0 2)|:])@((0|:[)smx])(]*/])@(S02d1L{]))+vSgDd2M)] Initds2=.(gXR([(0{])@mcv xRef@hkxR03),:@Initx)+/^:2@:*(]*/])@Initdx Initds =.%:@|@Initds2 gXRAll=:,:@(0.05 1 2 8 1 1 1 _0.1 0 _0.5"_) Initx =: 1.1100 , 0.5p1 , 0.25p1 , 0p1 "_ Initdx=: (0 , 0 , 0.001 , 0.01"_)*%@(1"_) vS00xL =:Initx vS01dxL =:0,0,0,0: vS02d1L =:Initd1 vS06ds =:Initds vS07count =:(0,6283"_)*1"_ pdDH =:vSgD@vS'' pdDH arrayPut 'pdDH' arrayClose 'pdDH'
NB. ... execute (ijx) ... arrayOpen 'pdDH' pdDH=:6284 8 4 arrayGet 'pdDH' NB. ... shape required ... arrayClose 'pdDH'
load 'plot' pd ((1.1100*cos@]"0);1.1100*sin@]"0) pTsteps _ 0p1 2p1 160 pd vSgDplot pdDH pd 'aspect 1' pd 'pdf' pd 'show'
... charge neutral (0) ...
vSgDd2M=.[([(0{])@rfE1cn xRef@hkxR03),:@(S03xH{]) vSgDd2 =.gXR(-@(([([(0{])@ch2k xRef@hkxR03),:@(S03xH{]))+/"1@((<0 2)|:])@((0|:[)smx])(]*/])@(S02d1L{]))+vSgDd2M)] Initds2=.(gXR([(0{])@mcv xRef@hkxR03),:@Initx)+/^:2@:*(]*/])@Initdx Initds =.%:@|@Initds2 gXRAll=:,:@(0.05 1 2 8 1 1 1 _0.1 0 0"_) Initx =: 1.1100 , 0.5p1 , 0.25p1 , 0p1 "_ Initdx=: (0 , 0 , 0.001 , 0.01"_)*%@(1"_) vS00xL =:Initx vS01dxL =:0,0,0,0: vS02d1L =:Initd1 vS06ds =:Initds vS07count =:(0,6283"_)*1"_ pdDI =:vSgD@vS'' pdDI arrayPut 'pdDI' arrayClose 'pdDI'
NB. ... execute (ijx) ... arrayOpen 'pdDI' pdDI=:6284 8 4 arrayGet 'pdDI' NB. ... shape required ... arrayClose 'pdDI'
load 'plot' pd vSgDplot pdDI pd ((1.1100*cos@]"0);1.1100*sin@]"0) pTsteps _ 0p1 2p1 160 pd 'aspect 1' pd 'pdf' pd 'show'
... charge positive (0.5) ...
vSgDd2M=.[([(0{])@rfE1cn xRef@hkxR03),:@(S03xH{]) vSgDd2 =.gXR(-@(([([(0{])@ch2k xRef@hkxR03),:@(S03xH{]))+/"1@((<0 2)|:])@((0|:[)smx])(]*/])@(S02d1L{]))+vSgDd2M)] Initds2=.(gXR([(0{])@mcv xRef@hkxR03),:@Initx)+/^:2@:*(]*/])@Initdx Initds =.%:@|@Initds2 gXRAll=:,:@(0.05 1 2 8 1 1 1 _0.1 0 0.5"_) Initx =: 1.1100 , 0.5p1 , 0.25p1 , 0p1 "_ Initdx=: (0 , 0 , 0.001 , 0.01"_)*%@(1"_) vS00xL =:Initx vS01dxL =:0,0,0,0: vS02d1L =:Initd1 vS06ds =:Initds vS07count =:(0,6283"_)*1"_ pdDJ =:vSgD@vS'' pdDJ arrayPut 'pdDJ' arrayClose 'pdDJ'
NB. ... execute (ijx) ... arrayOpen 'pdDJ' pdDJ=:6284 8 4 arrayGet 'pdDJ' NB. ... shape required ... arrayClose 'pdDJ'
load 'plot' pd ((1.1100*cos@]"0);1.1100*sin@]"0) pTsteps _ 0p1 2p1 160 pd ((1.1100*cos@]"0);1.1100*sin@]"0) pTsteps _ 0p1 2p1 160 pd vSgDplot pdDJ pd 'aspect 1' pd 'pdf' pd 'show'