0001
0002
0003
0004 clear all
0005 clear mex
0006 clear functions
0007 close all
0008 warning off
0009 global nfig
0010
0011 permission = test_permissions_yp;
0012
0013 if ~permission
0014 disp('Please move the script to a local folder where you have write permission before to run it')
0015 return;
0016 end
0017
0018
0019
0020 id_simul = 'LH_karney_cluster';
0021 path_simul = '';
0022
0023 psin_S = [];
0024 rho_S = [0.5];
0025
0026 id_path = '';
0027 path_path = '';
0028
0029 id_equil = 'TScyl';
0030 path_equil = '';
0031
0032 id_dkeparam = 'UNIFORM10010020';
0033 path_dkeparam = '';
0034
0035 id_display = 'NO_DISPLAY';
0036 path_display = '';
0037
0038 id_ohm = '';
0039 path_ohm = '';
0040
0041 ids_wave = {''};
0042 paths_wave = {''};
0043
0044 id_transpfaste = '';
0045 path_transpfaste = '';
0046
0047 id_ripple = '';
0048 path_ripple = '';
0049
0050
0051
0052
0053
0054 [dkepath,equil,dkeparam,dkedisplay,ohm,waves,transpfaste,ripple] = load_structures_yp('dkepath',id_path,path_path,'equil',id_equil,path_equil,'dkeparam',id_dkeparam,path_dkeparam,'dkedisplay',id_display,path_display,'ohm',id_ohm,path_ohm,'waves',ids_wave,paths_wave,'transpfaste',id_transpfaste,path_transpfaste,'ripple',id_ripple,path_ripple);
0055
0056
0057
0058 wavestruct.omega_lh = [4]*2*pi*1e9;
0059
0060
0061
0062 wavestruct.opt_lh = 2;
0063
0064
0065
0066
0067 wavestruct.norm_ref = 1;
0068
0069 wavestruct.yNparmin_lh = [NaN];
0070 wavestruct.yNparmax_lh = [NaN];
0071 wavestruct.yNpar_lh = [NaN];
0072 wavestruct.ydNpar_lh = [NaN];
0073
0074
0075 wavestruct.yD0_in_c_lh = [1];
0076
0077 wavestruct.yD0_in_lh_prof = [0];
0078 wavestruct.ypeak_lh = [NaN];
0079 wavestruct.ywidth_lh = [NaN];
0080
0081 wavestruct.ythetab_lh = [0]*pi/180;
0082
0083
0084
0085
0086 if exist('dmumpsmex');dkeparam.invproc = -2;end
0087
0088
0089
0090 dkeparam.clustermode.coll_dke_jd.scheduler = 'local';
0091
0092 dkeparam.clustermode.eecoll_dke_yp.scheduler = 'local';
0093
0094 dkeparam.boundary_mode_f = 0;
0095 dkeparam.norm_mode_f = 1;
0096 dkeparam.tn = [50000,100000];
0097
0098 dkeparam.psin_S = psin_S;
0099 dkeparam.rho_S = rho_S;
0100
0101 j_r_k = '0.003732';
0102 p_r_k = '0.0001256';
0103 eta_r_k = '29.72';
0104
0105 j_nr_0_10_k = '0.05754';
0106 p_nr_0_10_k = '0.004011';
0107 eta_nr_0_10_k = '14.34';
0108
0109 j_nr_0_20_k = '0.05759';
0110 p_nr_0_20_k = '0.004012';
0111 eta_nr_0_20_k = '14.35';
0112
0113 j_nr_2_20_k = '0.07092';
0114 p_nr_2_20_k = '0.004294';
0115 eta_nr_2_20_k = '16.52';
0116
0117 iclustermode_min = 1;
0118 iclustermode_max = 4;
0119
0120 for iclustermode = iclustermode_min:iclustermode_max,
0121
0122 dkeparam.clustermode.coll_dke_jd.scheduler.mode = iclustermode-1;
0123 dkeparam.clustermode.coll_dke_jd.scheduler.memory = 500;
0124
0125 dkeparam.clustermode.eecoll_dke_yp.scheduler.mode = iclustermode-1;
0126 dkeparam.clustermode.eecoll_dke_yp.scheduler.memory = 500;
0127
0128
0129
0130 dkeparam.pnmax_S = 30;
0131
0132 wavestruct.yvparmin_lh = [4];
0133 wavestruct.yvparmax_lh = [7];
0134
0135 waves{1} = make_idealLHwave_jd(equil,wavestruct);
0136
0137 [Znorm_rel{iclustermode},Zcurr_rel{iclustermode},ZP0_rel{iclustermode}] = main_dke_yp(id_simul,dkepath,equil,dkeparam,dkedisplay,ohm,waves,transpfaste,ripple,[],[]);
0138
0139
0140
0141 [qe,me,mp,mn,e0,mu0,re,mc2] = pc_dke_yp;
0142
0143 betath = 0.001;
0144 equil.pTe = betath^2*mc2*ones(size(equil.pTe));
0145 equil.pzTi = betath^2*mc2*ones(size(equil.pzTi));
0146
0147 wavestruct.yvparmin_lh = [3];
0148 wavestruct.yvparmax_lh = [5];
0149
0150 waves{1} = make_idealLHwave_jd(equil,wavestruct);
0151
0152 dkeparam.coll_mode = 0;
0153
0154 dkeparam.nmhu_S = 101;
0155 dkeparam.np_S = 101;
0156 dkeparam.pnmax_S = 10;
0157
0158 [Znorm_nr_0_10{iclustermode},Zcurr_0_10{iclustermode},ZP0_0_10{iclustermode}] = main_dke_yp(id_simul,dkepath,equil,dkeparam,dkedisplay,ohm,waves,transpfaste,ripple,[],[]);
0159
0160 dkeparam.nmhu_S = 201;
0161 dkeparam.np_S = 201;
0162 dkeparam.pnmax_S = 20;
0163
0164 [Znorm_nr_0_20{iclustermode},Zcurr_0_20{iclustermode},ZP0_0_20{iclustermode}] = main_dke_yp(id_simul,dkepath,equil,dkeparam,dkedisplay,ohm,waves,transpfaste,ripple,[],[]);
0165
0166 dkeparam.coll_mode = 2;
0167
0168 [Znorm_nr_2_20{iclustermode},Zcurr_2_20{iclustermode},ZP0_2_20{iclustermode}] = main_dke_yp(id_simul,dkepath,equil,dkeparam,dkedisplay,ohm,waves,transpfaste,ripple,[],[]);
0169 end
0170
0171 clc
0172
0173 disp(['--------------------------------------------------------------------------------------------'])
0174
0175 format
0176
0177 delete res_karney_cluster
0178
0179 diary res_karney_cluster
0180
0181 for iclustermode = iclustermode_min:iclustermode_max,
0182 disp(' ')
0183 if iclustermode == 1,
0184 disp(['Comparison LUKE/Karney, sequential calculations'])
0185 elseif iclustermode == 2,
0186 disp(['Comparison LUKE/Karney, Matlab Distributed Computing Toolbox calculations (MDCE)'])
0187 elseif iclustermode == 3,
0188 disp(['Comparison LUKE/Karney, LUKE Distributed Computing Toolbox calculations (LDCE)'])
0189 elseif iclustermode == 4,
0190 disp(['Comparison LUKE/Karney, with PARFOR loop calculations'])
0191 elseif iclustermode == 5,
0192 disp(['Comparison LUKE/Karney, with GPU calculations'])
0193 end
0194
0195 disp(['----------------------------------------------'])
0196
0197 disp(['Relativistic case (4,7,1) : j = ',num2str(Zcurr_rel{iclustermode}.x_0),'/',j_r_k,' ; P = ',num2str(ZP0_rel{iclustermode}.x_rf_fsav),'/',p_r_k,' ; j/P = ',num2str(Zcurr_rel{iclustermode}.x_0./ZP0_rel{iclustermode}.x_rf_fsav),'/',eta_r_k])
0198 disp(['Non Relativistic case (3,5,1) pmax = 10, coll_mode = 0 : j = ',num2str(Zcurr_0_10{iclustermode}.x_0),'/',j_nr_0_10_k,' ; P = ',num2str(ZP0_0_10{iclustermode}.x_rf_fsav),'/',p_nr_0_10_k,' ; j/P = ',num2str(Zcurr_0_10{iclustermode}.x_0./ZP0_0_10{iclustermode}.x_rf_fsav),'/',eta_nr_0_10_k])
0199 disp(['Non Relativistic case (3,5,1) pmax = 20, coll_mode = 0 : j = ',num2str(Zcurr_0_20{iclustermode}.x_0),'/',j_nr_0_20_k,' ; P = ',num2str(ZP0_0_20{iclustermode}.x_rf_fsav),'/',p_nr_0_20_k,' ; j/P = ',num2str(Zcurr_0_20{iclustermode}.x_0./ZP0_0_20{iclustermode}.x_rf_fsav),'/',eta_nr_0_20_k])
0200 disp(['Non Relativistic case (3,5,1) pmax = 20, coll_mode = 2 : j = ',num2str(Zcurr_2_20{iclustermode}.x_0),'/',j_nr_2_20_k,' ; P = ',num2str(ZP0_2_20{iclustermode}.x_rf_fsav),'/',p_nr_2_20_k,' ; j/P = ',num2str(Zcurr_2_20{iclustermode}.x_0./ZP0_2_20{iclustermode}.x_rf_fsav),'/',eta_nr_2_20_k])
0201 end
0202
0203 diary off
0204
0205
0206
0207 disp(' ')
0208 eval(['save ',path_simul,'DKE_RESULTS_',id_equil,'_',id_simul,'.mat']);
0209 info_dke_yp(2,['Data saved in ',path_simul,'DKE_RESULTS_',id_equil,'_',id_simul,'.mat']);