diff --git a/matlab/TCV/gdat_tcv.m b/matlab/TCV/gdat_tcv.m index 8aea44db094ae1abd3a38927294493199525fa4e..db1a668fc6dbe519d7e7a0fddf90500266c93c42 100644 --- a/matlab/TCV/gdat_tcv.m +++ b/matlab/TCV/gdat_tcv.m @@ -1581,14 +1581,16 @@ elseif strcmp(mapping_for_tcv.method,'switchcase') ec_inputs.pgyro.label = 'Power injected per launcher ; last index is total'; ec_inputs.pgyro.x = 1:numel(pgyro(1,:)); ec_inputs.pgyro.dim = {ec_inputs.pgyro.x, ec_inputs.pgyro.t}; - ec_inputs.pgyro.dimunits = {'launcher #1-9/11, total', 's'}; + launchers_label = cellfun(@num2str, num2cell(1:size(pgyro,1)-1),'UniformOutput',false); + launchers_label{end+1} = 'tot'; + ec_inputs.pgyro.dimunits = {launchers_label, 's'}; ec_inputs.launchers_active = zeros(numel(pgyro_ecrh),1); for ii =1:numel(pgyro_ecrh) if ~isempty(pgyro_ecrh{ii}.data); ec_inputs.launchers_active(ii) = 1; end end ec_inputs.gyro2launcher.data = gyro2launcher; - ec_inputs.gyro2launcher.label = 'gyrotron connected to launcher'; + ec_inputs.gyro2launcher.label = 'Gyrotron connected to launcher'; ec_inputs.freq2launcher.data = freq2launcher; ec_inputs.freq2launcher.label = 'Frequency in launcher'; @@ -1618,11 +1620,9 @@ elseif strcmp(mapping_for_tcv.method,'switchcase') end ec_help = 'from toray icdint with extracting of effective Icd for given launcher depending on nb rays used'; % All EC related quantities, each substructure should have at least fields data,x,t,units,dim,dimunits,label to be copied onto gdat_data - if size(pabs_gyro.data,1)>9 - launchers_label = {'1','2','3','4','5','6','7','8','9','10','11','tot'}; - else - launchers_label = {'1','2','3','4','5','6','7','8','9','tot'}; - end + + launchers_label = cellfun(@num2str, num2cell(1:size(pabs_gyro.data,1)),'UniformOutput',false); + launchers_label{end+1} = 'tot'; launchers_grid = [1:size(pabs_gyro.data,1)+1]'; % power deposition related: