From 0936485b774cfb0ff53b87f677d53cc5483d178b Mon Sep 17 00:00:00 2001 From: Olivier Sauter <olivier.sauter@epfl.ch> Date: Mon, 29 Jan 2007 08:37:59 +0000 Subject: [PATCH] add firrat git-svn-id: https://spcsvn.epfl.ch/repos/TCV/gdat/trunk@1908 d63d8f72-b253-0410-a779-e742ad2e26cf --- TCV/loadTCVdata.m | 23 +++++++++++++++++++---- 1 file changed, 19 insertions(+), 4 deletions(-) diff --git a/TCV/loadTCVdata.m b/TCV/loadTCVdata.m index b7839880..02cce761 100644 --- a/TCV/loadTCVdata.m +++ b/TCV/loadTCVdata.m @@ -433,12 +433,24 @@ switch TCVkeywrdcase{index} case {'nerho','terho'} % ne or Te from Thomson data on rho=sqrt(psi_normalised) mesh: (rho,t) mdsopen(shot); + time=mdsdata('\results::thomson:times'); if strcmp(TCVkeywrdcase{index},'nerho') nodenameeff='\results::thomson:ne'; - nodenameeff='\results::thomson:ne; error_bar ; fir_thom_rat'; tracetdi=tdi(nodenameeff); + nodenameeff='\results::thomson:ne; error_bar ; fir_thom_rat; (ne,std)*fir_thom_rat'; tracestd=tdi('\results::thomson:ne:error_bar'); - tracefirrat=tdi('\results::thomson:fir_thom_rat'); + if shot>=23801 + tracefirrat=tdi('\results::thomson.profiles.auto:fir_thom_rat'); %time base not same!! + if isempty(tracefirrat.data) + disp('problem with \results::thomson.profiles.auto:fir_thom_rat: empty') + end + else + tracefirrat=tdi('\results::thomson:fir_thom_rat'); + tracefirrat.dim{1}=time; + end + itim=iround(time,tracefirrat.dim{1}); + tracefirrat_data=NaN*ones(size(tracetdi.dim{1})); + tracefirrat_data(itim)=tracefirrat.data; else nodenameeff='\results::thomson:te'; tracetdi=tdi(nodenameeff); @@ -447,10 +459,13 @@ switch TCVkeywrdcase{index} end trace.data=tracetdi.data'; % Thomson data as (t,z) trace.std=tracestd.data'; - trace.firrat=tracefirrat.data'; + if strcmp(TCVkeywrdcase{index},'nerho') + trace.firrat=tracefirrat_data; + trace.data_abs=trace.data*diag(tracefirrat_data); + trace.std_abs=trace.std*diag(tracefirrat_data); + end trace.name=[num2str(shot) ';' nodenameeff]; % add correct dimensions - time=mdsdata('\results::thomson:times'); % construct rho mesh psi_max=tdi(['\results::thomson:psi_max' liuqe_ext]); psiscatvol=tdi(['\results::thomson:psiscatvol' liuqe_ext]); -- GitLab