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
RCLadderSys.m
Go to the documentation of this file.
1 namespace models{
2 namespace circ{
3 
4 
5 /* (Autoinserted by mtoc++)
6  * This source code has been filtered by the mtoc++ executable,
7  * which generates code that can be processed by the doxygen documentation tool.
8  *
9  * On the other hand, it can neither be interpreted by MATLAB, nor can it be compiled with a C++ compiler.
10  * Except for the comments, the function bodies of your M-file functions are untouched.
11  * Consequently, the FILTER_SOURCE_FILES doxygen switch (default in our Doxyfile.template) will produce
12  * attached source files that are highly readable by humans.
13  *
14  * Additionally, links in the doxygen generated documentation to the source code of functions and class members refer to
15  * the correct locations in the source code browser.
16  * However, the line numbers most likely do not correspond to the line numbers in the original MATLAB source files.
17  */
18 
39  public:
40 
42  this = this@models.BaseFirstOrderSystem(model);
43 
44  dim = this.Model.Dims;
45  this.NumStateDofs= dim;
46 
47  this.x0= dscomponents.ConstInitialValue(zeros(this.Model.Dims,1));
48 
49  B = zeros(dim,1);
50  B(1) = 1;
51  this.B= dscomponents.LinearInputConv(B);
52 
53  e = ones(dim,1);
54  A = spdiags([e -2*e e],-1:1,dim,dim);
55  A(1,:) = -A(1,:);
56  A(end,end) = -1;
57  this.A= dscomponents.LinearCoreFun(A);
58 
59  this.C= dscomponents.LinearOutputConv(B^t);
60 
61  this.f= models.circ.RCLadderFun(this, dim);
62 
63  this.Inputs= [@(t)exp(-t),@(t)(cos(2*pi*t/10) + 1)/2,...
64  @(t)double((t-.3)>0),@(t)(cos(pi*t)+1)/(t+1),...
65  @(t)(cos(pi*t*.5)+1)/(t+1),@(t)2*(t>1.3),@(t)(cos(3*pi*t)+1)/(2*t+1)];
66 
67  this.MaxTimestep= [];
68  this.StateScaling= 1;
69 
70  this.updateDimensions;
71  }
72 
73 
74  protected:
75 
77  if ~isa(model, " models.circ.RCLadder ")
78  error(" The Model property has to be a child of models.circ.RCLadder ");
79  end
80  }
94 };
95 }
96 }
97 
The base class for any KerMor detailed model.
Definition: BaseFullModel.m:18
dscomponents.AInputConv B
The input conversion.
Model
The Model this System is attached to.
A double value.
LinearCoreFun(A)
No system reference needed for constant linear core fun.
Definition: LinearCoreFun.m:43
dscomponents.AInitialValue x0
Function handle to initial state evaluation.
RCLadderSys(models.BaseFullModel model)
Definition: RCLadderSys.m:41
Inputs
The system's possible input functions. A cell array of function handles, each taking a time argument ...
colvec StateScaling
The scaling for the state vectors.
dscomponents.LinearOutputConv C
The output conversion Defaults to an LinearOutputConv instance using a 1-matrix, which just forwards ...
dscomponents.ACoreFun f
The core f function from the dynamical system.
function validateModel(models.BaseFullModel model)
Validates if the model to be set is a valid BaseModel at least. Extracting this function out of the s...
Definition: RCLadderSys.m:76
double MaxTimestep
The maximum timestep allowed for any ODE solvers.
Base class for all KerMor first-order dynamical systems.
dscomponents.LinearCoreFun A
Represents a linear or affine-linear component of the dynamical system.