rbmatlab  1.16.09
 All Classes Namespaces Files Functions Variables Modules Pages
List of all members | Public Member Functions | Static Public Member Functions | Static Public Attributes
LinEvol.DetailedModel Class Reference

Detailed Description

Detailed model for a linear evolution problem with a Finite volume discretization.

This is a detailed model for a problem of the type

\begin{align} \partial_t u(x;t,\mu) - {\cal L}(t,\mu)[u(x,t;\mu)] &= 0 \qquad &\text{in }& \Omega \times [0, T], \\\ u(x;0,\mu) &= u_0(x;\mu) \qquad &\text{in }& \Omega \times \{0\} \end{align}

with suitable boundary conditions and linear operators \({\cal L}(t,\mu) : {\cal W} \to {\cal W}\) parametrized over the time-parameter domain \([0,T] \times {\cal M}\).

The numerical scheme for the numerical solution of this problem is assumed to be of the following type:

\begin{align*} u_h(\cdot;t^0,\mu) &= {\cal M}_h[u_0] \\\ \left(\text{Id} - \Delta t^k {\cal L}_{h, I}(t^{k+1},\mu)\right)[u_h(\cdot;t^{k+1},\mu)] &= \left(\text{Id} + \Delta t^k {\cal L}_{h, E}(t^{k},\mu)\right)[u_h(\cdot;t^{k},\mu)] \end{align*}

with the following ingredients:

Definition at line 18 of file DetailedModel.m.

Inheritance diagram for LinEvol.DetailedModel:
Inheritance graph
[legend]
Collaboration diagram for LinEvol.DetailedModel:
Collaboration graph
[legend]

Public Member Functions

 DetailedModel (descr)
 constructor based on problem description More...
 
function
sim_data = 
detailed_simulation (ModelData model_data)
 executes a detailed simulation for a given parameter More...
 
function ModelData
model_data = 
gen_model_data ()
 method which produces all \(H\)-dependent data, that is required for a detailed simulations and is independent of the parameter \(\mu\). More...
 
function p = plot_sim_data (ModelData model_data, sim_data, plot_params)
 plots the simulation data as returned by detailed_simulation() More...
 
- Public Member Functions inherited from Greedy.User.FVDetailedModelDefault
 FVDetailedModelDefault (ModelDescr descr)
 Constructor for this class. More...
 
function UON = orthonormalize (ModelData model_data, U)
 orthonormalizes a set of discrete functions \(\{ v_h^l \}_{l=1}^L\) More...
 
function U0 = init_values_algorithm (ModelData model_data)
 computes the Dof vectors for the initial value function \(u_h^0(\cdot;t\mu) = {\cal P}_h[u_0(\mu)]\) More...
 
function UV = inner_product (ModelData model_data, U, V)
 computes the inner project between the Dof vectors of two discrete functions More...
 
- Public Member Functions inherited from Greedy.User.IDetailedModel
 IDetailedModel (descr)
 constructor More...
 
- Public Member Functions inherited from IDetailedModel
 IDetailedModel (descr)
 constructor More...
 
function
isequal = 
eq (IDetailedModel other)
 overloaded equality (==) operator, by default comparing the descr variables More...
 
function IDetailedModel this = set_mu (mu)
 sets the active parameter vector \(\mu \in {\cal M}\) More...
 
function mu = get_mu ()
 returns the active parameter vector \(\boldsymbol\mu \in {\cal M}\) More...
 
virtual function
sim_data = 
detailed_simulation (model_data)
 executes a detailed simulation for a given parameter More...
 
virtual function p = plot_sim_data (model_data, sim_data, plot_params)
 plots the simulation data as returned by detailed_simulation() More...
 

Static Public Member Functions

static function U = get_dofs_from_sim_data (sim_data)
 extracts the \(H\) dimensional Dof vector from the sim_data structure More...
 
static function
snapshot = 
get_dofs_at_time (U, time_index)
 
- Static Public Member Functions inherited from Greedy.User.FVDetailedModelDefault
static function errs = l2_error_sequence_algorithm (U, Uapprox,ModelData model_data)
 computes the \(L^2(\Omega)\) error for each "snapshot" of a trajectories and returns the sequence of these errors. More...
 
static function errs = linfty_error_sequence_algorithm (U, Uapprox,ModelData model_data)
 computes the \(L^{\infty}(\Omega)\) error for each "snapshot" of a trajectories and returns the sequence of these errors. More...
 
static function W = get_inner_product_matrix (ModelData model_data)
 returns the inner product matrix for efficient computation of inner products on \({\cal W}_h\) More...
 
- Static Public Member Functions inherited from IModel
static function ok = struct_check (descr, checks)
 executes checks on the fields of a structure object More...
 

Static Public Attributes

static const  ddescr_checks
 This constant is used for a consistency check of the model descr with help of Greedy.Remove.IDetailedModelBase.struct_check() More...
 
- Static Public Attributes inherited from IDetailedModel
static const  base_checks
 this structure holds variable names that need to be defined by the descr structure. More...
 
- Static Public Attributes inherited from IModel
static const  time_checks
 This constant can be used for a consistency check of time evolution members in the ModelDescr with help of IModel.struct_check() More...
 

Additional Inherited Members

- Public Attributes inherited from IDetailedModel
 descr
 The description structure holding information about the analytical parametrized problem and its discretization. More...
 
 decomp_mode
 
 mu_names
 cell array of strings describing the parameters of the model More...
 
 mu_ranges
 cell array of vectors of size two defining the allowed interval range for the parameter components More...
 
 verbose
 an integer defining the verbosity level of information output during basis generation More...
 
 debug
 an integer defining the debugging level controlling error output and extra tests during basis generation More...
 
- Public Attributes inherited from IModel
 num_cpus = 4
 The number of CPUs used for parallel sessions. More...
 
 decomp_mode
 Decomposition operation mode. More...
 
 mu_names
 cell array of strings describing the parameters of the model More...
 
 mu_ranges
 cell array of vectors of size two defining the allowed interval range for the parameter components More...
 
 verbose
 an integer defining the verbosity level of information output during basis generation More...
 
 debug
 an integer defining the debugging level controlling error output and extra tests during basis generation More...
 

Constructor & Destructor Documentation

LinEvol.DetailedModel.DetailedModel (   descr)

constructor based on problem description

Parameters
descrstructure describing the problem and the descretization

Definition at line 78 of file DetailedModel.m.

Here is the call graph for this function:

Member Function Documentation

function sim_data = LinEvol.DetailedModel.detailed_simulation ( ModelData  model_data)

executes a detailed simulation for a given parameter

This function computes a numerical scheme defined by the descr for the parameter set via the set_mu() method.

Parameters
model_dataMatlab structure storing (possibly) high dimensional data needed by IDetailedModel.detailed_simulation().
Return values
sim_datastructure holding the \(H\)-dimensional simulation data.
Generated fields of sim_data:
  • U —  Dof vectors for the solution snapshots \(u_h(\cdot, t^{k_i})\) where \((k_i)_{i=1}^{\hat{K}}\) are the time_indices.
  • time_indices —  This is a vector of stored time indices \((k_i)_{i=1}^{\hat{K}}\)
  • time —  This is a vector of stored time instances \((t^{k_i})_{i=1}^{\hat{K}}\)
  • y —  Vector of output functional values (if activated)
  • mu —  mu

Definition at line 19 of file detailed_simulation.m.

function ModelData model_data = LinEvol.DetailedModel.gen_model_data ( )
virtual

method which produces all \(H\)-dependent data, that is required for a detailed simulations and is independent of the parameter \(\mu\).

Return values
model_datamodel data
Generated fields of model_data:
  • W —  inner product weighting matrix
  • grid —  a structure containing geometry information of a mesh used for discretizations
Documentation Update:

Implements IDetailedModel.

Definition at line 19 of file gen_model_data.m.

static function U = LinEvol.DetailedModel.get_dofs_from_sim_data (   sim_data)
staticvirtual

extracts the \(H\) dimensional Dof vector from the sim_data structure

Parameters
sim_datamatlab struct with simulation data generated e.g. by detailed_simulation() or rb_reconstruction() methods.
Return values
U\(H\) dimensional Dof vector

Implements Greedy.User.IDetailedModel.

Definition at line 102 of file DetailedModel.m.

function p = LinEvol.DetailedModel.plot_sim_data ( ModelData  model_data,
  sim_data,
  plot_params 
)

plots the simulation data as returned by detailed_simulation()

Parameters
model_dataMatlab structure storing (possibly) high dimensional data needed by IDetailedModel.detailed_simulation().
sim_datasimulation data structure as returned by detailed_simulation()
plot_paramsstructure which controls the plot output
Return values
pMatlab GUI handle to figure window
Required fields of sim_data:
  • U —  DOF vector of solution snapshots
  • y —  DOF vector of output function
  • s —  s
Required fields of model_data:
  • grid —  a structure containing geometry information of a mesh used for discretizations
Optional fields of plot_params:
  • plot_title —  title of the plot (default = trajectory)
  • plot_output_title —  title of the output functional plot (default = output)
  • axis_equal —  flag equalizing the axes ratio

Definition at line 19 of file plot_sim_data.m.

Here is the call graph for this function:

Member Data Documentation

LinEvol.DetailedModel.ddescr_checks
static
Initial value:
= struct(" \
'mass_matrix', {{\@(x) isequal(class(x), 'function_handle')}} \
")

This constant is used for a consistency check of the model descr with help of Greedy.Remove.IDetailedModelBase.struct_check()


Default: struct(" \ 'mass_matrix', {{@(x) isequal(class(x), 'function_handle')}} \ ")

Definition at line 63 of file DetailedModel.m.


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