Skip to content
Snippets Groups Projects
Commit 2c189c3c authored by Olivier Sauter's avatar Olivier Sauter
Browse files

add temporary fix for bad w_mhd

git-svn-id: https://spcsvn.epfl.ch/repos/TCV/gdat/trunk@7926 d63d8f72-b253-0410-a779-e742ad2e26cf
parent 0889fa34
Branches
Tags
No related merge requests found
......@@ -469,6 +469,7 @@ if strcmp(mapping_for_tcv.method(1:3),'tdi')
mapping_for_tcv.gdat_timedim = mapping_for_tcv.timedim;
end
gdat_data.data_fullpath=[mapping_for_tcv.expression];
gdat_data.help = aatmp.help;
% end of method "tdi"
......@@ -517,6 +518,7 @@ elseif strcmp(mapping_for_tcv.method,'expression')
end
end
gdat_data.data_fullpath=mapping_for_tcv.expression;
gdat_data.help = gdat_tmp.help;
end
% end of method "expression"
......
......@@ -100,7 +100,7 @@ switch lower(data_request)
mapping.method = 'tdiliuqe';
mapping.expression = '\results::delta_ed_bot';
mapping.expression = '\tcv_shot::top.results.equil_1.results:delta_bot';
mapping.expression = 'tcv_eq(''''delta_bot'''',''''LIUQE.M'''')';
mapping.expression = 'tcv_eq(''''delta_ed_bot'''',''''LIUQE.M'''')';
case 'delta_rho'
mapping.timedim = 1;
mapping.method = 'tdiliuqe';
......@@ -112,7 +112,7 @@ switch lower(data_request)
mapping.method = 'tdiliuqe';
mapping.expression = '\results::delta_ed_top';
mapping.expression = '\tcv_shot::top.results.equil_1.results:delta_top';
mapping.expression = 'tcv_eq(''''delta_top'''',''''LIUQE.M'''')';
mapping.expression = 'tcv_eq(''''delta_ed_top'''',''''LIUQE.M'''')';
case 'ece'
mapping.timedim = 2;
mapping.method = 'switchcase';
......@@ -362,10 +362,22 @@ switch lower(data_request)
% mapping.expression = '\results::psitbx:vol'; (if exists for liuqe2 and 3 as well)
case {'wmhd', 'w_mhd'}
mapping.timedim = 1;
mapping.method = 'tdiliuqe';
mapping.expression = '\results::total_energy';
mapping.expression = '\tcv_shot::top.results.equil_1.results:w_mhd';
mapping.expression = 'tcv_eq(''''w_mhd'''',''''LIUQE.M'''')';
if shot==57716 || shot==57732
time_for_corr = [0.5,1.03];
corr = [4e3,4.5e3];
if shot==57732; corr=[4650,4650]; end
mapping.method = 'expression';
mapping.expression = ['params_eff = gdat_data.gdat_params;params_eff.data_request=''tcv_eq(''''''''w_mhd'''''''',''''''''LIUQE.M'''''''')'';' ...
'gdat_tmp=gdat_tcv(shot,params_eff);ij=find(gdat_tmp.t>0.5&gdat_tmp.t<1.03);' ...
'aa=interp1([' num2str(time_for_corr(1)) ' ' num2str(time_for_corr(2)) ...
'],[' num2str(corr(1)) ' ' num2str(corr(2)) '],gdat_tmp.t(ij));' ...
'gdat_tmp.data(ij)=max(gdat_tmp.data(ij),aa);'];
else
mapping.method = 'tdiliuqe';
mapping.expression = '\results::total_energy';
mapping.expression = '\tcv_shot::top.results.equil_1.results:w_mhd';
mapping.expression = 'tcv_eq(''''w_mhd'''',''''LIUQE.M'''')';
end
case 'z_contour'
mapping.timedim = 2;
mapping.method = 'tdiliuqe';
......
......@@ -62,7 +62,14 @@ if all(isfield(gdat_data,{'data','t'})) && ~isempty(gdat_data.data) && ~isempty(
title(eval(['gdat_data.eqdsk' endstr '.stitle']));
elseif any(find(size(gdat_data.data)==length(gdat_data.t)))
try
plot(gdat_data.t,gdat_data.data);
if length(size(gdat_data.data))<=2
plot(gdat_data.t,gdat_data.data);
else
disp('WARNING')
disp(['size(gdat_data.data) = ' num2str(size(gdat_data.data)) ', >2D thus do not try to plot'])
disp(' ')
return
end
catch ME
if exist('ME','var')
disp('Problem in gdat_plot')
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment