KerMor  0.9
Model order reduction for nonlinear dynamical systems and nonlinear approximation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
DEIMEstimatorAnalyzer.m
Go to the documentation of this file.
1 
2 
3 /* (Autoinserted by mtoc++)
4  * This source code has been filtered by the mtoc++ executable,
5  * which generates code that can be processed by the doxygen documentation tool.
6  *
7  * On the other hand, it can neither be interpreted by MATLAB, nor can it be compiled with a C++ compiler.
8  * Except for the comments, the function bodies of your M-file functions are untouched.
9  * Consequently, the FILTER_SOURCE_FILES doxygen switch (default in our Doxyfile.template) will produce
10  * attached source files that are highly readable by humans.
11  *
12  * Additionally, links in the doxygen generated documentation to the source code of functions and class members refer to
13  * the correct locations in the source code browser.
14  * However, the line numbers most likely do not correspond to the line numbers in the original MATLAB source files.
15  */
16 
17 function varargout = DEIMEstimatorAnalyzer(varargin) {
18 
19 
20 /* Edit the above text to modify the response to help DEIMEstimatorAnalyzer */
21 
22 /* Last Modified by GUIDE v2.5 12-Oct-2012 13:53:00 */
23 
24 /* Begin initialization code - DO NOT EDIT */
25 gui_Singleton = 0;
26 gui_State = struct(" gui_Name ", mfilename, ...
27  " gui_Singleton ", gui_Singleton, ...
28  " gui_OpeningFcn ", @DEIMEstimatorAnalyzer_OpeningFcn, ...
29  " gui_OutputFcn ", @DEIMEstimatorAnalyzer_OutputFcn, ...
30  " gui_LayoutFcn ", [] , ...
31  " gui_Callback ", []);
32 if nargin && ischar(varargin[1])
33  gui_State.gui_Callback= str2func(varargin[1]);
34 end
35 
36 if nargout
37  [varargout[1:nargout]] = gui_mainfcn(gui_State, varargin[:]);
38 else
39  gui_mainfcn(gui_State, varargin[:]);
40 end
41 /* End initialization code - DO NOT EDIT */
42 
43 
44 /* --- Executes just before DEIMEstimatorAnalyzer is made visible. */
45 }
78 
79 /* Choose default command line output for DEIMEstimatorAnalyzer */
80 handles.output= hObject;
81 
82 /* Update handles structure */
83 guidata(hObject, handles);
84 
85 /* Parse inputs */
86 
87 ip.addRequired('Model',@(r)isa(r," models.ReducedModel "));
88 ip.addParamValue('StartIdx',4,@isposintscalar);
89 ip.parse(varargin[:]);
90 res = ip.Results;
91 r = res.Model;
92 setappdata(handles.main," startidx ",res.StartIdx);
93 
94 mu = r.System.mu;
95 if isempty(mu)
96  mu = r.ParamSamples(:,1);
97 end
98 setappdata(handles.main," mu ",mu);
99 in = [];
100 if r.System.InputCount > 0
101  in = 1;
102 end
103 setappdata(handles.main," inputidx ",in);
104 
105 /* Care condition: dont simulate very expensive by default! */
106 e = r.ErrorEstimator;
107 if ~isempty(e) && e.JacSimTransMaxSize > 0 && e.JacSimTransSize == 0
108  e.JacSimTransSize= 1;
109 end
110 setappdata(handles.main," r ",r);
111 createModelParamSliders(handles,r);
112 modelToGUI(handles, r);
113 
114 extra = ;
115 sr = r.FullModel.SpaceReducer;
116 if sr.IncludeTrajectoryFxiData
117  extra = " InclFxiData:yes ";
118 end
119 if sr.IncludeFiniteDifferences
120  extra = [extra " InclFinDiff:yes "];
121 end
122 n = sprintf(" Model '%s', %d-dim, reduced %d-dim, %s ",...
123  r.Name,r.FullModel.Dimension,size(r.V,2),extra);
124 set(hObject," Name ",n);
125 set(handles.rbgAlpha," SelectionChangeFcn ",@(s,e)rbgAlpha_SelectionChanged(handles,s,e));
126 set(handles.rbgBeta," SelectionChangeFcn ",@(s,e)rbgBeta_SelectionChanged(handles,s,e));
127 set(handles.rbg_Param," SelectionChangeFcn ",@(s,e)rbgParam_SelectionChanged(handles,s,e));
128 
129 reSimulate(handles);
130 
131 }
132 
134 if r.System.ParamCount > 0
135  /* Setup training sample slider */
136  set(h.slTrainParam," Min ",1," Max ",size(r.ParamSamples,2)," Value ",1);
137  /* Create model parameter slides */
138  parent = h.rbg_Param;
139  set(parent," Units "," pixels ");
140  pos = get(parent," Position ");
141  set(parent," Units "," normalized ");
142  dist = 22;/* px */
143 
144  pcnt = 0;
145  pdata = struct;
146  pdata.sl= zeros(r.System.ParamCount,1);
147  pdata.lbl= zeros(r.System.ParamCount,1);
148  mu = getappdata(h.main," mu ");
149  for pidx = 1:r.System.ParamCount
150  p = r.System.Params(pidx);
151  if p.HasRange
152  /* Top location */
153  top = pos(4)-pcnt*dist-40-2*dist;
154 
155  /* % Create name labels */
156  label = uicontrol(" Tag ",sprintf(" lblP%d ",pidx)," Style "," text ",...
157  " Parent ",parent," HorizontalAlignment "," left ");
158  set(label," String ",[p.Name " : "]," Units "," pixels ",...
159  " Position ",[10 top 60 14]);
160  set(label," Units "," normalized ");
161 
162  /* % Labels for min/max values */
163  label = uicontrol(" Tag ",[" runtime_lbll " num2str(pidx)]," Style "," text ",...
164  " Parent ",parent," HorizontalAlignment "," right ");
165  set(label," String ",sprintf(" %g ",p.MinVal)," Units "," pixels ",...
166  " Position ",[70 top 40 14]);
167  set(label," Units "," normalized ");
168  label = uicontrol(" Tag ",[" runtime_lblr " num2str(pidx)]," Style "," text ",...
169  " Parent ",parent," HorizontalAlignment "," left ");
170  set(label," String ",sprintf(" %g ",p.MaxVal)," Units "," pixels ",...
171  " Position ",[290 top 40 14]);
172  set(label," Units "," normalized ");
173 
174  /* % Create slider */
175  ctrl = uicontrol(" Tag ",sprintf(" slP%d ",pidx)," Parent ",...
176  parent," Style "," slider "," UserData ",pidx);
177  /* Position */
178  set(ctrl," Units "," pixels "," Position ",...
179  [110 top 170 16]);
180  set(ctrl," Units "," normalized ");
181  /* Range etc */
182  set(ctrl," Min ",p.MinVal," Max ",p.MaxVal," Value ",mu(pidx));
183  set(ctrl," SliderStep ",[0.01 0.1]);
184  /* Set callback & string */
185  set(ctrl," Callback ",@(~,~)(updateUserParam(h)));
186  pdata.sl(pidx) = ctrl;
187 
188  /* % Create value labels */
189  label = uicontrol(" Tag ",sprintf(" lblPV%d ",pidx)," Style "," text ",...
190  " Parent ",parent," HorizontalAlignment "," left ");
191  set(label," String ",sprintf(" %g ",mu(pidx))," Units "," pixels ",...
192  " Position ",[340 top 40 14]);
193  set(label," Units "," normalized ");
194  pdata.lbl(pidx) = label;
195 
196  /* increase position counter */
197  pcnt = pcnt + 1;
198  end
199  end
200  setappdata(h.main," pdata ",pdata);
201 end
202 
203 }
204 
206 r = getappdata(h.main," r ");
207 pdata = getappdata(h.main," pdata ");
208 pc = r.System.ParamCount;
209 if pc > 0
210  set(h.rbCustomParam," Value ",1);
211  mu = zeros(pc,1);
212  for pidx = 1:pc
213  if r.FullModel.System.Params(pidx).HasRange
214  mu(pidx) = get(pdata.sl(pidx)," Value ");
215  else
216  mu(pidx) = r.FullModel.System.Params(pidx).MinVal;
217  end
218  s = sprintf(" %g ",r.System.Params(pidx).Name,mu(pidx));
219  set(pdata.lbl(pidx)," String ",s);
220  end
221  setappdata(h.main," mu ",mu);
222 end
223 reSimulate(h);
224 
225 }
226 
228 
229  set(h.slM," Min ",1," Max ",r.System.f.MaxOrder," Value ", r.System.f.Order(1));
230  set(h.lblM," String ",sprintf(" %d ",r.System.f.Order(1)));
231 
232  /* m' estimates */
233  e = r.ErrorEstimator;
234  if ~isempty(e) && e.UseTrueDEIMErr
235  set(h.rbTrueDEIM," Value ",1);
236  else
237  set(h.rbMD," Value ",1);
238  end
239  mv = r.System.f.MaxOrder-r.System.f.Order(1);
240  if mv ~= 0, en=" on "; else en=" off "; end
241  set(h.slMD," Min ",0," Max ",max(mv,1)," Enable ",en," Value ", r.System.f.Order(2));
242  set(h.lblMD," String ",sprintf(" %d ",r.System.f.Order(2)));
243 
244  /* mj JacMDEIM */
245  if ~isempty(e)
246  set(h.slJM," Min ",1," Max ",e.JacMatDEIMMaxOrder," Value ", e.JacMatDEIMOrder);
247  set(h.lblJM," String ",sprintf(" %d ",e.JacMatDEIMOrder));
248  /* simtrans k */
249  set(h.slK," Min ",0," Max ",e.JacSimTransMaxSize," Value ", e.JacSimTransSize);
250  set(h.lblK," String ",sprintf(" %d ",e.JacSimTransSize));
251  if e.UseTrueLogLipConst
252  set(h.rbtrueloclip," Value ",1);
253  elseif e.UseJacobianLogLipConst
254  set(h.rbjacloclip," Value ",1);
255  elseif e.UseFullJacobian
256  set(h.rbfulljac," Value ",1);
257  else
258  set(h.rbjmst," Value ",1);
259  end
260  end
261 
262 }
263 
265 drawnow;
266 fprintf(" Simulating... ");
267 r = getappdata(h.main," r ");
268 mu = getappdata(h.main," mu ");
269 in = getappdata(h.main," inputidx ");
270 s = struct;
271 [~, s.y, s.tf, s.x] = r.FullModel.simulate(mu,in);
272 [s.t, s.yr, s.tr, s.xr] = r.simulate(mu,in);
273 setappdata(h.main," s ",s);
274 rePlot(h);
275 
276 }
277 
279 fprintf(" plotting... ");
280 r = getappdata(h.main," r ");
281 s = getappdata(h.main," s ");
282 esterr = zeros(size(r.Times));
283 if get(h.rbOutput," Value ") /* Output error plot */
284 
285  Cn = normest(r.FullModel.System.C.C);
286  err = Cn*1e-7*Norm.L2(s.x-r.V*s.xr);
287  /* err2 = Norm.L2(r.FullModel.System.computeOutput(s.x-r.V*s.xr));
288  *trajnorm = Norm.L2(s.y-s.yr); */
289  trajnorm = Norm.L2(s.y);
290  if ~isempty(r.ErrorEstimator)
291  esterr = r.ErrorEstimator.OutputError;
292  end
293 else /* State space error plot */
294 
295  err = Norm.L2(s.x-r.V*s.xr);
296  trajnorm = Norm.L2(s.x);
297  if ~isempty(r.ErrorEstimator)
298  esterr = r.ErrorEstimator.StateError;
299  end
300 end
301 doPlot(h.axerr,r.Times,err," b ");
302 doPlot(h.axrel,r.Times,err./trajnorm," b ");
303 if ~isempty(r.ErrorEstimator) && r.ErrorEstimator.Enabled
304  hold(h.axerr," on ");
305  doPlot(h.axerr,r.Times,esterr," r ");
306  hold(h.axerr," off ");
307  /* Relative error */
308  hold(h.axrel," on ");
309  doPlot(h.axrel,r.Times,esterr./trajnorm," r ");
310  hold(h.axrel," off ");
311  /* Effectivities */
312  doPlot(h.axeff,r.Times,esterr./err," g ");
313  eest = esterr(end);
314 else
315  cla(h.axeff);
316  eest = -1;
317 end
318 str = sprintf(" Times: Full %gs, Red.: %gs, Speedup: %g\n ",s.tf,s.tr,s.tf/s.tr);
319 str = [str sprintf(" Errors(T=%g): True: %g, Est.: %g,\nRel: %g, Est.Rel.: %g, Eff.:%g ",...
320  r.Times(end),err(end),eest,err(end)/trajnorm(end),eest/trajnorm(end),eest/err(end))];
321 set(h.lblRes," String ",str);
322 if ~isempty(r.ErrorEstimator)
323  doPlot(h.axhlp,r.Times,r.ErrorEstimator.LastAlpha," m ");
324  doPlot(h.axhlp2,r.Times,r.ErrorEstimator.LastBeta," c ");
325  axis(h.axerr," tight ");
326  if r.ErrorEstimator.Enabled
327  axis(h.axeff," tight ");
328  axis(h.axhlp," tight ");
329  axis(h.axhlp2," tight ");
330  end
331 end
332 fprintf(" done.\n ");
333 
334 }
335 
337 startidx = getappdata(get(h," Parent ")," startidx ");
338 LogPlot.cleverPlot(h,x(startidx:end),y(startidx:end),varargin[:]);
339 
340 }
341 
343 r = getappdata(h.main," r ");
344 s = getappdata(h.main," s ");
345 mu = getappdata(h.main," mu ");
346 [ef,er,fxno] = testing.DEIM.getApproxErrorFullRed(r, s.xr, s.t, mu, r.V);
347 pm = PlotManager;
348 pm.LeaveOpen= true;
349 ax = pm.nextPlot(" deimerr "," True and projected approximation error on current trajectory "," time "," error ");
350 if max(ef)/min(ef) < 100 || max(er)/min(er) < 100
351  plotfun = @plot;
352 else
353  plotfun = @semilogy;
354 end
355 plotfun(ax,r.Times,ef," b ",r.Times,er," r ");
356 legend(" Full "," Projected ");
357 pm.done;
358 
359 /* --- Outputs from this function are returned to the command line. */
360 }
361 
362 function varargout = DEIMEstimatorAnalyzer>DEIMEstimatorAnalyzer_OutputFcn(hObject,eventdata,handles) {
363 
364 /* Get default command line output from handles structure */
365 varargout[1] = handles.output;
366 
367 }
368 
370 rb = get(source," SelectedObject ");
371 r = getappdata(h.main," r ");
372 e = r.ErrorEstimator;
373 switch get(rb," UserData ")
374  case 1
375  e.UseTrueDEIMErr= true;
376  e.Enabled= true;
377  case 2
378  e.UseTrueDEIMErr= false;
379 end
380 reSimulate(h);
381 
382 }
383 
385 rb = get(source," SelectedObject ");
386 r = getappdata(h.main," r ");
387 e = r.ErrorEstimator;
388 e.UseTrueLogLipConst= false;
389 e.UseJacobianLogLipConst= false;
390 e.UseFullJacobian= false;
391 e.UseJacobianNorm= false;
392 switch get(rb," UserData ")
393  case 1
394  e.UseTrueLogLipConst= true;
395  case 2
396  e.UseJacobianLogLipConst= true;
397  case 3
398  e.UseFullJacobian= true;
399  case 4
400  e.UseJacobianNorm= true;
401 end
402 reSimulate(h);
403 
404 }
405 
407 rb = get(source," SelectedObject ");
408 switch get(rb," UserData ")
409  case 1
410  slTrainParam_Callback(h.slTrainParam, [], h);
411  case 2
412  updateUserParam(h);
413 end
414 
415 /* --- Executes on slider movement. */
416 }
417 
418 function DEIMEstimatorAnalyzer>slMD_Callback(hObject,eventdata,handles) {
419 r = getappdata(handles.main," r ");
420 md = round(get(hObject," Value "));
421 if r.System.f.Order(2) ~= md
422  fprintf(" Setting m "" =%d... ",md);
423  r.System.f.Order= [r.System.f.Order(1) md];
424  r.ErrorEstimator.Enabled= md > 0;
425  set(handles.lblMD," String ",sprintf(" %d ",md));
426  set(handles.rbMD," Value ",1);
427  reSimulate(handles);
428 end
429 
430 /* --- Executes during object creation, after setting all properties. */
431 }
432 
433 function DEIMEstimatorAnalyzer>slMD_CreateFcn(hObject,eventdata,handles) {
434 if isequal(get(hObject," BackgroundColor "), get(0," defaultUicontrolBackgroundColor "))
435  set(hObject," BackgroundColor ",[.9 .9 .9]);
436 end
437 
438 
439 /* --- Executes on slider movement. */
440 }
441 
442 function DEIMEstimatorAnalyzer>slJM_Callback(hObject,eventdata,handles) {
443 r = getappdata(handles.main," r ");
444 jm = round(get(hObject," Value "));
445 if r.ErrorEstimator.JacMatDEIMOrder ~= jm
446  fprintf(" Setting m_j=%d... ",jm);
447  r.ErrorEstimator.JacMatDEIMOrder= jm;
448  set(handles.lblJM," String ",sprintf(" %d ",jm));
449  reSimulate(handles);
450 end
451 
452 /* --- Executes during object creation, after setting all properties. */
453 }
454 
455 function DEIMEstimatorAnalyzer>slJM_CreateFcn(hObject,eventdata,handles) {
456 if isequal(get(hObject," BackgroundColor "), get(0," defaultUicontrolBackgroundColor "))
457  set(hObject," BackgroundColor ",[.9 .9 .9]);
458 end
459 
460 /* --- Executes on slider movement. */
461 }
462 
463 function DEIMEstimatorAnalyzer>slK_Callback(hObject,eventdata,handles) {
464 r = getappdata(handles.main," r ");
465 k = round(get(hObject," Value "));
466 if r.ErrorEstimator.JacSimTransSize ~= k
467  fprintf(" Setting k=%d... ",k);
468  r.ErrorEstimator.JacSimTransSize= k;
469  set(handles.lblK," String ",sprintf(" %d ",k));
470  reSimulate(handles);
471 end
472 
473 /* --- Executes during object creation, after setting all properties. */
474 }
475 
476 function DEIMEstimatorAnalyzer>slK_CreateFcn(hObject,eventdata,handles) {
477 if isequal(get(hObject," BackgroundColor "), get(0," defaultUicontrolBackgroundColor "))
478  set(hObject," BackgroundColor ",[.9 .9 .9]);
479 end
480 
481 
482 /* --- Executes on slider movement. */
483 }
484 
485 function DEIMEstimatorAnalyzer>slM_Callback(hObject,eventdata,handles) {
486 r = getappdata(handles.main," r ");
487 m = round(get(hObject," Value "));
488 if r.System.f.Order(1) ~= m
489  fprintf(" Setting m=%d... ",m);
490  r.System.f.Order= [m min(r.System.f.Order(2),r.System.f.MaxOrder-m)];
491  set(handles.lblM," String ",sprintf(" %d ",m));
492 
493  /* Update range for m' values */
494  mv = r.System.f.MaxOrder-m;
495  if mv ~= 0, en=" on "; else en=" off "; end
496  set(handles.slMD," Min ",0," Max ",max(mv,1)," Enable ",en," Value ", r.System.f.Order(2));
497  set(handles.lblMD," String ",sprintf(" %d ",r.System.f.Order(2)));
498  reSimulate(handles);
499 end
500 
501 /* --- Executes during object creation, after setting all properties. */
502 }
503 
504 function DEIMEstimatorAnalyzer>slM_CreateFcn(hObject,eventdata,handles) {
505 if isequal(get(hObject," BackgroundColor "), get(0," defaultUicontrolBackgroundColor "))
506  set(hObject," BackgroundColor ",[.9 .9 .9]);
507 end
508 
509 
510 /* --- Executes on button press in btnDEIMErr. */
511 }
512 
513 function DEIMEstimatorAnalyzer>btnDEIMErr_Callback(hObject,eventdata,handles) {
514 getDEIMErrorsOnTraj(handles);
515 
516 
517 /* --- Executes on button press in btnRedSummary. */
518 }
519 
520 function DEIMEstimatorAnalyzer>btnRedSummary_Callback(hObject,eventdata,h) {
521 r = getappdata(h.main," r ");
522 ma = ModelAnalyzer(r);
523 pm = ma.plotReductionOverview;
524 pm.setFigureNames(sprintf(" Reduction summary of '%s' ",get(h.main," Name ")));
525 
526 
527 /* --- Executes on slider movement. */
528 }
529 
530 function DEIMEstimatorAnalyzer>slTrainParam_Callback(hObject,unused1,h) {
531 
532 /* Hints: get(hObject,'Value') returns position of slider
533  * get(hObject,'Min') and get(hObject,'Max') to determine range of slider */
534 r = getappdata(h.main," r ");
535 pidx = round(get(hObject," Value "));
536 mu = r.ParamSamples(:,pidx);
537 if ~isequal(getappdata(h.main," mu "),mu)
538  setappdata(h.main," mu ",mu);
539  set(h.rbTrainParam," Value ",1);
540  pdata = getappdata(h.main," pdata ");
541  for pidx = 1:length(mu)
542  set(pdata.sl(pidx)," Value ",mu(pidx));
543  set(pdata.lbl(pidx)," String ",sprintf(" %g ",mu(pidx)));
544  end
545  drawnow;
546  reSimulate(h);
547 end
548 
549 /* --- Executes during object creation, after setting all properties. */
550 }
551 
552 function DEIMEstimatorAnalyzer>slTrainParam_CreateFcn(hObject,eventdata,handles) {
553 
554 /* Hint: slider controls usually have a light gray background. */
555 if isequal(get(hObject," BackgroundColor "), get(0," defaultUicontrolBackgroundColor "))
556  set(hObject," BackgroundColor ",[.9 .9 .9]);
557 end
558 
559 
560 /* --- Executes on button press in btnVisResult. */
561 }
562 
563 function DEIMEstimatorAnalyzer>btnVisResult_Callback(hObject,eventdata,h) {
564 r = getappdata(h.main," r ");
565 m = r.FullModel;
566 s = getappdata(h.main," s ");
567 pm = [];
568 if get(h.rbOutput," Value ")
569  vr = s.yr;
570  v = s.y;
571  pm = PlotManager(false,1,2);
572  pm.LeaveOpen= true;
573  pfun = @(t,y)r.plot(t,y,pm);
574  pfunm = @(t,y)m.plot(t,y,pm);
575 else
576  vr = r.V*s.xr;
577  v = s.x;
578  pfun = @r.plotState;
579  pfunm = @r.plotState;
580 end
581 if get(h.chkAbsErr," Value ")
582  pfun(s.t,vr);
583  set(gcf," Name "," Results of reduced simulation ");
584  pfunm(s.t,abs(v-vr));
585  set(gcf," Name "," Absolute errors ");
586 else
587  pfunm(s.t,v);
588  set(gcf," Name "," Results of full simulation ");
589  pfun(s.t,vr);
590  set(gcf," Name "," Results of reduced simulation ");
591 end
592 if ~isempty(pm)
593  pm.done;
594 end
595 
596 
597 /* --- Executes on button press in pushbutton5. */
598 }
599 
600 function DEIMEstimatorAnalyzer>pushbutton5_Callback(hObject,eventdata,h) {
601 r = getappdata(h.main," r ");
602 s = getappdata(h.main," s ");
603 v = Norm.L2(s.x-r.V*(r.V^t*s.x));
604 pm = PlotManager;
605 pm.LeaveOpen= true;
606 h = pm.nextPlot(," Trajectory subspace projection L2(state) error "," time "," error ");
607 LogPlot.cleverPlot(h,s.t,v," r "," LineWidth ",2);
608 pm.done;
609 
610 
611 /* --- Executes on button press in btnApproxLogNorm. */
612 }
613 
614 function DEIMEstimatorAnalyzer>btnApproxLogNorm_Callback(hObject,eventdata,h) {
615 r = getappdata(h.main," r ");
616 /* m = r.FullModel; */
617 s = getappdata(h.main," s ");
618 x = s.xr;
619 use = 20;
620 sel = round(linspace(1,size(x,2),min(use,size(x,2))));
621 x = x(:,sel);
622 mui = r.getRandomParam(400,1);
623 res = testing.LogNorm.getApproxLogNormsAtPos(r, x, r.scaledTimes(sel),mui);
624 pm = PlotManager;
625 pm.LeaveOpen= true;
626 testing.LogNorm.getApproxLogNormsAtPos_plots(res, pm);
627 pm.done;
628 
629 
630 /* --- Executes on button press in rbState. */
631 }
632 
633 function DEIMEstimatorAnalyzer>rbState_Callback(hObject,eventdata,h) {
634 if get(hObject," Value ")
635  set(h.rbOutput," Value ",0);
636 end
637 rePlot(h);
638 
639 /* --- Executes on button press in rbOutput. */
640 }
641 
642 function DEIMEstimatorAnalyzer>rbOutput_Callback(hObject,eventdata,h) {
643 if get(hObject," Value ")
644  set(h.rbState," Value ",0);
645 end
646 rePlot(h);
647 
648 }
649 
ModelAnalyzer: Analysis tools for reduced models and approximations.
Definition: ModelAnalyzer.m:17
function varargout = DEIMEstimatorAnalyzer(varargin)
DEIMESTIMATORANALYZER MATLAB code for DEIMEstimatorAnalyzer.fig DEIMESTIMATORANALYZER, by itself, creates a new DEIMESTIMATORANALYZER or raises the existing singleton*.
function DEIMEstimatorAnalyzer>slM_Callback(hObject, eventdata, handles)
LogPlot: Class with static functions for logarithmic plotting.
Definition: LogPlot.m:17
function DEIMEstimatorAnalyzer>reSimulate(h)
function DEIMEstimatorAnalyzer>rbOutput_Callback(hObject, eventdata, h)
function DEIMEstimatorAnalyzer>createModelParamSliders(h, r)
function varargout = DEIMEstimatorAnalyzer>DEIMEstimatorAnalyzer_OutputFcn(hObject, eventdata, handles)
function DEIMEstimatorAnalyzer>slM_CreateFcn(hObject, eventdata, handles)
function DEIMEstimatorAnalyzer>rbState_Callback(hObject, eventdata, h)
function DEIMEstimatorAnalyzer>slMD_Callback(hObject, eventdata, handles)
function DEIMEstimatorAnalyzer>slK_CreateFcn(hObject, eventdata, handles)
function DEIMEstimatorAnalyzer>modelToGUI(h, r)
function DEIMEstimatorAnalyzer>getDEIMErrorsOnTraj(h)
PlotManager: Small class that allows the same plots generated by some script to be either organized a...
Definition: PlotManager.m:17
function DEIMEstimatorAnalyzer>btnDEIMErr_Callback(hObject, eventdata, handles)
function DEIMEstimatorAnalyzer>slK_Callback(hObject, eventdata, handles)
function DEIMEstimatorAnalyzer>doPlot(h,colvec< double > x,matrix< double > y, varargin)
static function handle p = cleverPlot(handle ax,rowvec< double > x,rowvec< double > y, varargin)
Calls corresponding plot routines depending on the scale of data.
Definition: LogPlot.m:158
function DEIMEstimatorAnalyzer>updateUserParam(h)
logical LeaveOpen
Flag indicating if the plots should be left open once the PlotManager is deleted (as variable) ...
Definition: PlotManager.m:213
A variable number of input arguments.
function DEIMEstimatorAnalyzer>DEIMEstimatorAnalyzer_OpeningFcn(hObject, eventdata, handles, varargin)
function DEIMEstimatorAnalyzer>slTrainParam_CreateFcn(hObject, eventdata, handles)
function DEIMEstimatorAnalyzer>slTrainParam_Callback(hObject, unused1, h)
function DEIMEstimatorAnalyzer>btnApproxLogNorm_Callback(hObject, eventdata, h)
function DEIMEstimatorAnalyzer>btnVisResult_Callback(hObject, eventdata, h)
function DEIMEstimatorAnalyzer>rbgBeta_SelectionChanged(h, source, eventdata)
function DEIMEstimatorAnalyzer>slJM_CreateFcn(hObject, eventdata, handles)
function res = isposintscalar(value)
isposintscalar: Backwards-compatibility function for matlab versions greater than 2012a ...
function DEIMEstimatorAnalyzer>rbgAlpha_SelectionChanged(h, source, unused1)
static function rowvec< double > n = L2(matrix< double > x)
Returns the discrete norm for each column vector in x.
Definition: Norm.m:39
function DEIMEstimatorAnalyzer>rbgParam_SelectionChanged(h, source, unused1)
function DEIMEstimatorAnalyzer>btnRedSummary_Callback(hObject, eventdata, h)
Norm: Static class for commonly used norms on sets of vectors.
Definition: Norm.m:17
function DEIMEstimatorAnalyzer>slJM_Callback(hObject, eventdata, handles)
function DEIMEstimatorAnalyzer>slMD_CreateFcn(hObject, eventdata, handles)
function DEIMEstimatorAnalyzer>rePlot(h)
function DEIMEstimatorAnalyzer>pushbutton5_Callback(hObject, eventdata, h)
A variable number of output arguments.