2 %
function [bound,valid] = riccati_estim_validity_bound(model, reduced_data,
5 % This
function performs a check, whether the validity bound
for the
6 % application of the error estimator is valid.
8 % This is done by checking the inequality
10 % 8 gamma^2 \|E\|^2 \|B\|^2 \| R \| <= 1
12 % This
function also takes care of performance improvements, when the
13 % matrices E,B are not parameter dependent.
15 % Andreas Schmidt, 2015
18 if ~isfield(rbsim.estim,
'gamma')
19 error('The field rbsim.gamma must be present!')
21 if ~isfield(rbsim, 'P_residual')
22 error('The field rbsim.P_residual must be present')
25 model.decomp_mode = 2;
26 Ecoeff = model.E(model, reduced_data);
28 error('Q_E > 1 currently not implemented.');
30 normE2 = (reduced_data.estim.normE*Ecoeff(1))^2;
32 Bcoeff = model.B(model, reduced_data);
33 if reduced_data.estim.normBBT_use2norm
34 normBBT = (reduced_data.estim.normBBT*abs(Bcoeff(1)))^2;
37 for i = 1:length(Bcoeff)
38 for j = 1:length(Bcoeff)
39 for k = 1:length(Bcoeff)
40 for l = 1:length(Bcoeff)
41 normBBT = normBBT + Bcoeff(i)*Bcoeff(j)*Bcoeff(k)* ...
42 Bcoeff(l)*reduced_data.estim.normBBT{i,j,k,l};
49 bound = 8*rbsim.estim.gamma^2*rbsim.P_residual*normE2*normBBT;
function [ bound , valid ] = riccati_validity_bound(model, reduced_data, rbsim)
rbsim)