KerMor
0.9
Model order reduction for nonlinear dynamical systems and nonlinear approximation
|
BaseCompLemmaEstimator: Base class for error estimators using the comparison lemma formulation. More...
BaseCompLemmaEstimator: Base class for error estimators using the comparison lemma formulation.
This class is part of the framework
Homepage
http://www.morepas.org/software/index.htmlDocumentation
http://www.morepas.org/software/kermor/index.htmlLicense
KerMor license conditionsDefinition at line 18 of file BaseCompLemmaEstimator.m.
Public Member Functions | |
BaseCompLemmaEstimator () | |
function | offlineComputations (models.BaseFullModel model) |
Overrides the method from BaseEstimator and performs additional computations. More... | |
function
prepared = | prepareForReducedModel (models.ReducedModel rm) |
Prepares this estimator for use with a given reduced model. Basically uses the projection matrices and some other reduced quantities for local storage. More... | |
function e = | evalODEPart (colvec x,double t,double ut) |
Evaluates the auxiliary ode part for the comparison-lemma based error estimators. More... | |
function ct = | prepareConstants (colvec< double > mu,integer inputidx) |
function copy = | clone (copy) |
The interface method with returns a copy of the current class instance. More... | |
function | clear () |
function a = | getAlpha (colvec< double > x,double t,colvec< double > ut) |
Convenience access method for semi-implicit euler method. More... | |
function ct = | postProcess (colvec< double > x,double t,integer inputidx) |
Return values: ct: The time needed for postprocessing. More... | |
virtual function b = | getBeta (colvec x,double t) |
Computes the \(\beta(t)\) term from the error estimation ODE for given time and place. More... | |
Public Member Functions inherited from error.BaseEstimator | |
function | offlineComputations (models.BaseFullModel model) |
Performs a validity check for the given model and sets up the estimator for use with the specified model. More... | |
function double ct = | postProcess (unused1,rowvec t, unused2) |
Post-processes the error estimator ODE part after reduced simulation computation. More... | |
function | clear () |
Clears the last error set by the estimator. More... | |
function copy = | clone (copy) |
Creates a copy of this error estimator. Call only allowed from subclasses. More... | |
function e0 = | getE0 (colvec< double > mu) |
Calls the inner initial error computation strategy. More... | |
function ct = | prepareConstants (colvec< double > mu, unused1) |
function
prepared = | prepareForReducedModel (models.ReducedModel rmodel) |
Default implementation which simply clones this (subclass!)instance and returns the copy to use in reduced models. More... | |
Public Member Functions inherited from KerMorObject | |
KerMorObject () | |
Constructs a new KerMor object. More... | |
function | display () |
disp(object2str(this)); More... | |
function bool = | eq (B) |
Checks equality of two KerMor objects. More... | |
function bool = | ne (B) |
Checks if two KerMorObjects are different. More... | |
function cn = | getClassName () |
Returns the simple class name of this object without packages. More... | |
Public Member Functions inherited from DPCMObject | |
DPCMObject () | |
Creates a new DPCM object. More... | |
DPCMObject () | |
Static Public Member Functions | |
static function errmsg = | validModelForEstimator (models.BaseFullModel model) |
Validations. More... | |
Static Public Member Functions inherited from error.BaseEstimator | |
static function est = | getEstimator (models.BaseFullModel model) |
Factory method that creates a suitable error estimator for the given model. More... | |
static function errmsg = | validModelForEstimator (models.ReducedModel rmodel) |
Abstract static method that forces subclasses to specify whether an estimator can be used for a given model or not. More... | |
Public Attributes | |
EstimationData = "[]" | |
\(3\times n\) matrix containing the \(t,\alpha(t),\beta(t)\) values at each time step. More... | |
aComp | |
Public Attributes inherited from error.BaseEstimator | |
Enabled | |
Flag that indicates whether error estimation is used or not. More... | |
StateError = "[]" | |
The reduction state-space error from the last simulation. More... | |
ExtraODEDims = 0 | |
The dimensions added to the ODE function by the estimator. More... | |
OutputError = "[]" | |
The output error from the last simulation. More... | |
models.ReducedModel | ReducedModel = "[]" |
The reduced model associated with the error estimator. More... | |
mu | |
Public Attributes inherited from DPCMObject | |
WorkspaceVariableName = "" | |
The workspace variable name of this class. Optional. More... | |
ID = "[]" | |
An ID that allows to uniquely identify this DPCMObject (at least within the current MatLab session/context). More... | |
PropertiesChanged = "[]" | |
The Dictionary containing all the property settings as key/value pairs. More... | |
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... | |
Protected Attributes | |
StepNr | |
The current step. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from KerMorObject | |
function | checkType (obj, type) |
Object typechecker. More... | |
Protected Member Functions inherited from DPCMObject | |
function | registerProps (varargin) |
Call this method at any class that defines DPCM observed properties. More... | |
function | registerProps (varargin) |
Static Protected Member Functions inherited from DPCMObject | |
static function obj = | loadobj (obj, from) |
Re-register any registered change listeners! More... | |
static function obj = | loadobj (obj, from) |
error.BaseCompLemmaEstimator.BaseCompLemmaEstimator | ( | ) |
Definition at line 93 of file BaseCompLemmaEstimator.m.
References error.BaseEstimator.ExtraODEDims.
function error.BaseCompLemmaEstimator.clear | ( | ) |
Definition at line 192 of file BaseCompLemmaEstimator.m.
References EstimationData.
|
virtual |
The interface method with returns a copy of the current class instance.
target | If clone was called for a subclass of this class, target must contain the new instance of the subclass that is to be the cloned result. |
Implements ICloneable.
Definition at line 180 of file BaseCompLemmaEstimator.m.
References aComp, handle.addlistener, EstimationData, and StepNr.
Evaluates the auxiliary ode part for the comparison-lemma based error estimators.
x | The full extended state variable vector. Extended means that the last ExtraODEDims rows contain the error estimators own data. If not used, implementers must take care to ditch those values if any function evaluations are performed within the integral part. |
t | The current time \(t\) |
ut | The value of the input function \(u(t)\) if given, [] else. |
mu | The current parameter \(\mu\) |
e | The auxiliary ode part value. |
Implements error.BaseEstimator.
Definition at line 140 of file BaseCompLemmaEstimator.m.
References aComp, EstimationData, models.BaseFirstOrderSystem.f, getBeta(), error.BaseEstimator.mu, error.BaseEstimator.ReducedModel, StepNr, models.BaseModel.System, and t.
function a = error.BaseCompLemmaEstimator.getAlpha | ( | colvec< double > | x, |
double | t, | ||
colvec< double > | ut | ||
) |
Convenience access method for semi-implicit euler method.
x | The state variable vector \(\vx(t)\) |
t | The current time(s) \(t \in [0, T]\) |
ut | The value \(\vu(t)\) of the current input function \(\vu\) at time \(t\), [] else. |
Definition at line 198 of file BaseCompLemmaEstimator.m.
References aComp, models.BaseFirstOrderSystem.f, error.BaseEstimator.mu, error.BaseEstimator.ReducedModel, and models.BaseModel.System.
Computes the \(\beta(t)\) term from the error estimation ODE for given time and place.
x | The current reduced state variable, composed by \(Vz(t)\) and any extra dimensions set up by the error estimator. |
t | The current time \(t\in[0,T]\) |
Referenced by evalODEPart().
function error.BaseCompLemmaEstimator.offlineComputations | ( | models.BaseFullModel | model | ) |
Overrides the method from BaseEstimator and performs additional computations.
model | A KerMor full model |
Definition at line 99 of file BaseCompLemmaEstimator.m.
function ct = error.BaseCompLemmaEstimator.postProcess | ( | colvec< double > | x, |
double | t, | ||
integer | inputidx | ||
) |
Return values: ct: The time needed for postprocessing.
x | The state variable vector \(\vx(t)\) |
t | The current time(s) \(t \in [0, T]\) |
inputidx | The index \(i\) of the currently used input function \(u_i(t)\). Set to \([]\) if not used. |
Definition at line 213 of file BaseCompLemmaEstimator.m.
function ct = error.BaseCompLemmaEstimator.prepareConstants | ( | colvec< double > | mu, |
integer | inputidx | ||
) |
Definition at line 169 of file BaseCompLemmaEstimator.m.
References handle.addlistener, models.BaseModel.ODESolver, error.BaseEstimator.ReducedModel, and StepNr.
function prepared = error.BaseCompLemmaEstimator.prepareForReducedModel | ( | models.ReducedModel | rm | ) |
Prepares this estimator for use with a given reduced model. Basically uses the projection matrices and some other reduced quantities for local storage.
rm | The reduced model |
prepared | A clone of this estimator, with accordingly projected components |
Definition at line 113 of file BaseCompLemmaEstimator.m.
References handle.addlistener, models.BaseFirstOrderSystem.B, models.ReducedModel.FullModel, models.BaseModel.ODESolver, and models.BaseModel.System.
|
static |
Validations.
model | A KerMor full model |
Definition at line 264 of file BaseCompLemmaEstimator.m.
error.BaseCompLemmaEstimator.aComp |
Definition at line 75 of file BaseCompLemmaEstimator.m.
Referenced by clone(), evalODEPart(), and getAlpha().
error.BaseCompLemmaEstimator.EstimationData = "[]" |
\(3\times n\) matrix containing the \(t,\alpha(t),\beta(t)\) values at each time step.
SetAccess = Protected, GetAccess = Public
Definition at line 61 of file BaseCompLemmaEstimator.m.
Referenced by clear(), clone(), and evalODEPart().
|
protected |
The current step.
Transient
set to true. SetAccess = Private, GetAccess = Protected
Definition at line 47 of file BaseCompLemmaEstimator.m.
Referenced by clone(), evalODEPart(), error.IterationCompLemmaEstimator.getBeta(), and prepareConstants().