****************************************************************************************************************** ************************************************ OHMIC EFIELD PROFILE ******************************************** ****************************************************************************************************************** Create the local file OHM_id_equil.mat by Y.Peysson CEA-DRFC <yves.peysson@cea.fr> and Joan Decker MIT-RLE (jodecker@mit.edu)
0001 %****************************************************************************************************************** 0002 %************************************************ OHMIC EFIELD PROFILE ******************************************** 0003 %****************************************************************************************************************** 0004 % Create the local file OHM_id_equil.mat 0005 % 0006 %by Y.Peysson CEA-DRFC <yves.peysson@cea.fr> and Joan Decker MIT-RLE (jodecker@mit.edu) 0007 % 0008 clear all 0009 % 0010 id_ohm = 'OHM_p005_flat'; 0011 % 0012 id_equil = 'TScirc';%For loading the plasma equilibrium 0013 path_equil = '../EQUIL_files/';%if nothing is specified, the working directory is first used and then MatLab is looking in all the path 0014 % 0015 % Normlized Ohmic electric field profile calculation 0016 % (WARNING: norm_ref = 0 by default when multiple radial positions are studied simultaneously, whatever the value in this file 0017 % -> normalization with pth_ref*nhuth_ref/e) 0018 % 0019 epsi0 = 0.05;%Flux surface averaged core Ohmic electric field (pth_ref*nhuth_ref/e or pth*nhuth/e) 0020 epsia = 0.05;%Flux surface averaged edge Ohmic electric field (pth_ref*nhuth_ref/e or pth*nhuth/e) 0021 eepsi = 0;%Exponent for Ohmic electric field (WARNING: psi coordinate and not rho) 0022 % 0023 norm_ref = 1;%Normalization procedure for the ohmic electric field: (0) from local values Te and ne, (1) from reference values Te_ref and ne_ref 0024 % 0025 %***************************************************************************************************************** 0026 % 0027 if exist([path_equil,'EQUIL_',id_equil,'.mat']) == 0,%Magnetic equilibrium 0028 info_dke_yp(2,[path_equil,'EQUIL_',id_equil,'.mat does not exist']); 0029 return 0030 else 0031 eval(['load ',path_equil,'EQUIL_',id_equil,'.mat']); 0032 info_dke_yp(2,'Structure ''equil'' successfully loaded'); 0033 end 0034 % 0035 [ohm] = ohm_profile_yp(equil,epsi0,epsia,eepsi,norm_ref); 0036 % 0037 eval(['save OHM_',id_equil,'_',id_ohm,'.mat ohm']); 0038 0039