0001 function [XXfM,ZXXD_c_pp_ipj,ZXXD_c_pp_ij,ZXXD_c_pp_imj,ZXXD_c_mm_ijp,ZXXD_c_mm_ijm,ZXXF_c_p_ipj,ZXXF_c_p_ij,ZXXF_c_p_imj] = loop_coll_dke_jd1(ir,gridDKE,Zmomcoef,Zbouncecoef,equilDKE,mksa,dkepath,dkeparam,xTe_norm,xne_norm,xzni_norm,xzTi_norm,xnloss_norm,xbetath,xlnc_e,xnhu,xrnhuth)
0002
0003
0004
0005
0006
0007
0008
0009
0010 fM = maxwellian_dke_yp(Zmomcoef.gamma(:),gridDKE.pn2(:),gridDKE.dpn(:),xne_norm,xTe_norm,ir);
0011 xfM = fM*ones(1,length(fM));
0012 XXfM = fM*ones(1,gridDKE.nmhu);
0013
0014
0015
0016 [Fei,Aei,Btei] = eicoll_dke_yp(Zmomcoef.v,equilDKE.zZi,equilDKE.zmi,xzni_norm,xzTi_norm,ir,dkeparam.coll_mode);
0017 [Feim,Aeim] = eicoll_dke_yp(Zmomcoef.vm,equilDKE.zZi,equilDKE.zmi,xzni_norm,xzTi_norm,ir,dkeparam.coll_mode);
0018 [Feip,Aeip] = eicoll_dke_yp(Zmomcoef.vp,equilDKE.zZi,equilDKE.zmi,xzni_norm,xzTi_norm,ir,dkeparam.coll_mode);
0019
0020 Feim(1) = 1;
0021
0022 XFeim = Feim'*ones(1,gridDKE.nmhu);
0023 XFei = Fei'*ones(1,gridDKE.nmhu);
0024 XFeip = Feip'*ones(1,gridDKE.nmhu);
0025
0026 Aeim(1) = 1;
0027
0028 XAeim = Aeim'*ones(1,gridDKE.nmhu);
0029 XAei = Aei'*ones(1,gridDKE.nmhu);
0030 XAeip = Aeip'*ones(1,gridDKE.nmhu);
0031
0032 XBtei = Btei'*ones(1,gridDKE.nmhu);
0033
0034
0035
0036 [Fee,Aee,Btee] = eecoll_dke_yp(dkepath,Zmomcoef.v,Zmomcoef.z,Zmomcoef.gamma,Zmomcoef.sigma,gridDKE.pn,gridDKE.pn2,gridDKE.dpn,Zmomcoef.J1,Zmomcoef.J2,dkeparam.spfac,mksa.betath_ref,xne_norm,xTe_norm,ir,dkeparam.coll_mode,dkeparam.clustermode);
0037 [Feem,Aeem] = eecoll_dke_yp(dkepath,Zmomcoef.vm,Zmomcoef.zm,Zmomcoef.gammam,Zmomcoef.sigmam,gridDKE.pnm,gridDKE.pn2m,gridDKE.dpnm,Zmomcoef.J1,Zmomcoef.J2,dkeparam.spfac,mksa.betath_ref,xne_norm,xTe_norm,ir,dkeparam.coll_mode,dkeparam.clustermode);
0038 [Feep,Aeep] = eecoll_dke_yp(dkepath,Zmomcoef.vp,Zmomcoef.zp,Zmomcoef.gammap,Zmomcoef.sigmap,gridDKE.pnp,gridDKE.pn2p,gridDKE.dpnp,Zmomcoef.J1,Zmomcoef.J2,dkeparam.spfac,mksa.betath_ref,xne_norm,xTe_norm,ir,dkeparam.coll_mode,dkeparam.clustermode);
0039
0040 Feem(1) = 1;
0041
0042 XFeem = Feem'*ones(1,gridDKE.nmhu);
0043 XFee = Fee'*ones(1,gridDKE.nmhu);
0044 XFeep = Feep'*ones(1,gridDKE.nmhu);
0045
0046 Aeem(1) = 1;
0047
0048 XAeem = Aeem'*ones(1,gridDKE.nmhu);
0049 XAee = Aee'*ones(1,gridDKE.nmhu);
0050 XAeep = Aeep'*ones(1,gridDKE.nmhu);
0051
0052 XBtee = Btee'*ones(1,gridDKE.nmhu);
0053
0054
0055
0056 ZXXD_c_pp_ipj = XAeep + XAeip;
0057 ZXXD_c_pp_ij = XAee + XAei;
0058 ZXXD_c_pp_imj = XAeem + XAeim;
0059
0060 ZXXD_c_mm_ijp = (XBtee + XBtei).*Zbouncecoef.XXRlambda_p2m1_p(:,:,ir);
0061 ZXXD_c_mm_ijm = (XBtee + XBtei).*Zbouncecoef.XXRlambda_p2m1_m(:,:,ir);
0062
0063 ZXXF_c_p_ipj = -XFeep - XFeip;
0064 ZXXF_c_p_ij = -XFee - XFei;
0065 ZXXF_c_p_imj = -XFeem - XFeim;
0066 end