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
ModelAnalyzer Class Reference

ModelAnalyzer: Analysis tools for reduced models and approximations. More...

Detailed Description

ModelAnalyzer: Analysis tools for reduced models and approximations.

Author
Daniel Wirtz
Date
2011-11-17
Change in 0.6:
(Daniel Wirtz, 2011-11-17) Moved this class to the +tools package from visual.

This class is part of the framework

KerMor - Model Order Reduction using Kernels
Todo:
think of expressive names for methods

Definition at line 17 of file ModelAnalyzer.m.

Public Member Functions

 ModelAnalyzer (models.ReducedModel rmodel)
 
function [ matrix< double > params ,
errs ,

details ] = 
getRedErrForRandomParamSamples (integer num,integer seed, in)
 Computes the simulation errors (output) for num random model parameters. More...
 
function [ errs ,

details ] = 
getRedErrForParamSamples (integer params,integer in)
 Computes the simulation errors (output) for the given model parameters. More...
 
function  plotRedErrForParamSamples (errs, pm)
 \todo implement, so far only plotting in DEIM testing with multiple DEIM m Orders. More...
 
function [ t ,
pm ] = 
compareRedFull (mu, inputidx)
 Compares the solutions of the reduced model and the associated full model by calling the BaseModel.plot method for both solutions and again for the difference. Also some information of \(l^2\) and \(l^\infty\) errors are printed. More...
 
function [ el2 ,
elinf ,
double t ,
colvec
< double > x , fx ,
afx ] = 
getTrajApproxError (colvec< double > mu,integer inputidx)
 Computes the approximation training error on the full system's trajectory for given mu and inputidx. More...
 
function [ el2 ,
elinf ,
pm ] = 
getATDError (pm)
 Computes the approximation training error on the full system's trajectory for given mu and inputidx. More...
 
function pm = analyzeError (colvec< double > mu,integer inputidx, pm)
 
function pm = plotReductionOverview (pm)
 

Public Attributes

 SingleFigures = false
 
 UseOutput = true
 
- Public Attributes inherited from handle
 addlistener
 Creates a listener for the specified event and assigns a callback function to execute when the event occurs. More...
 
 notify
 Broadcast a notice that a specific event is occurring on a specified handle object or array of handle objects. More...
 
 delete
 Handle object destructor method that is called when the object's lifecycle ends. More...
 
 disp
 Handle object disp method which is called by the display method. See the MATLAB disp function. More...
 
 display
 Handle object display method called when MATLAB software interprets an expression returning a handle object that is not terminated by a semicolon. See the MATLAB display function. More...
 
 findobj
 Finds objects matching the specified conditions from the input array of handle objects. More...
 
 findprop
 Returns a meta.property objects associated with the specified property name. More...
 
 fields
 Returns a cell array of string containing the names of public properties. More...
 
 fieldnames
 Returns a cell array of string containing the names of public properties. See the MATLAB fieldnames function. More...
 
 isvalid
 Returns a logical array in which elements are true if the corresponding elements in the input array are valid handles. This method is Sealed so you cannot override it in a handle subclass. More...
 
 eq
 Relational functions example. See details for more information. More...
 
 transpose
 Transposes the elements of the handle object array. More...
 
 permute
 Rearranges the dimensions of the handle object array. See the MATLAB permute function. More...
 
 reshape
 hanges the dimensions of the handle object array to the specified dimensions. See the MATLAB reshape function. More...
 
 sort
 ort the handle objects in any array in ascending or descending order. More...
 

Constructor & Destructor Documentation

ModelAnalyzer.ModelAnalyzer ( models.ReducedModel  rmodel)

Definition at line 53 of file ModelAnalyzer.m.

Member Function Documentation

function pm = ModelAnalyzer.analyzeError ( colvec< double mu,
integer  inputidx,
  pm 
)

Definition at line 368 of file ModelAnalyzer.m.

References Norm.L2(), Utils.preparePlainPlot(), t, and UseOutput.

Here is the call graph for this function:

function [ t , pm ] = ModelAnalyzer.compareRedFull (   mu,
  inputidx 
)

Compares the solutions of the reduced model and the associated full model by calling the BaseModel.plot method for both solutions and again for the difference. Also some information of \(l^2\) and \(l^\infty\) errors are printed.

Parameters
muThe concrete mu parameter sample to simulate for.
inputidxThe index of the input function to use.
Return values
tThe PrintTable instance
Generated fields of t:
Generated fields of pm:

Definition at line 185 of file ModelAnalyzer.m.

References Utils.implode(), Norm.L2(), Norm.Linf(), and t.

Here is the call graph for this function:

function [ el2 , elinf , pm ] = ModelAnalyzer.getATDError (   pm)

Computes the approximation training error on the full system's trajectory for given mu and inputidx.

Required fields of pm:
Generated fields of pm:

Definition at line 308 of file ModelAnalyzer.m.

References LogPlot.cleverPlot(), Norm.L2(), Norm.Linf(), and t.

Here is the call graph for this function:

function [ errs , details ] = ModelAnalyzer.getRedErrForParamSamples ( integer  params,
integer  in 
)

Computes the simulation errors (output) for the given model parameters.

Parameters
paramsThe parameters to sample and compute the error for. If not given, the param samples for reduced model computation are used. Default: FullModel.Data.ParamSamples
inThe input index to use for the simulations. Default: []
Return values
errsA \(5\times n\) matrix containing the Linf-L2 absolute and relative error in rows 1,2 and Linf-Linf absolute and relative errors in rows 3-4. Row 5 contains the error estimator efficiency if enabled.
Generated fields of details:

Definition at line 93 of file ModelAnalyzer.m.

References Norm.L2(), and Norm.Linf().

Referenced by getRedErrForRandomParamSamples().

Here is the call graph for this function:

Here is the caller graph for this function:

function [ matrix< double > params , errs , details ] = ModelAnalyzer.getRedErrForRandomParamSamples ( integer  num,
integer  seed,
  in 
)

Computes the simulation errors (output) for num random model parameters.

See Also
ModelAnalyzer.getRedErrForParamSamples
Parameters
numThe number of random parameters to get the error for.
Default:
50
Parameters
seedThe seed for the random number generator.
Default:
round(cputime*100)
Parameters
inThe number of the input to use. Leave unset for no model inputs.
Return values
paramsThe parameters generated.
errsA \(4\times num\) matrix containing the Linf-L2 absolute and relative error in rows 1,2 and Linf-Linf absolute and relative errors in rows 3-4.

Definition at line 61 of file ModelAnalyzer.m.

References getRedErrForParamSamples().

Here is the call graph for this function:

function [ el2 , elinf , double t , colvec< double > x , fx , afx ] = ModelAnalyzer.getTrajApproxError ( colvec< double mu,
integer  inputidx 
)

Computes the approximation training error on the full system's trajectory for given mu and inputidx.

Parameters
muThe currently used parameter \(\vmu\). Set to \([]\) if not used.
inputidxThe index \(i\) of the currently used input function \(u_i(t)\). Set to \([]\) if not used.

Definition at line 276 of file ModelAnalyzer.m.

References Norm.L2(), Norm.Linf(), and t.

Here is the call graph for this function:

function ModelAnalyzer.plotRedErrForParamSamples (   errs,
  pm 
)

\todo implement, so far only plotting in DEIM testing with multiple DEIM m Orders.

Definition at line 176 of file ModelAnalyzer.m.

function pm = ModelAnalyzer.plotReductionOverview (   pm)
Todo:
create interface with plot method -> current config gives automatic reduction overview in each component
Required fields of pm:
Generated fields of pm:

Definition at line 476 of file ModelAnalyzer.m.

References FindInstance(), k, and l.

Here is the call graph for this function:

Member Data Documentation

ModelAnalyzer.SingleFigures = false

Definition at line 39 of file ModelAnalyzer.m.

ModelAnalyzer.UseOutput = true

Definition at line 42 of file ModelAnalyzer.m.

Referenced by analyzeError().


The documentation for this class was generated from the following file: