uncertainty in hard, soft and hard-soft modeling

38
Uncertainty in Hard, Soft and Hard-Soft Modeling

Upload: havily

Post on 10-Feb-2016

75 views

Category:

Documents


0 download

DESCRIPTION

Uncertainty in Hard, Soft and Hard-Soft Modeling. Uncertainty in Calculated Model Parameters using Hard- Modeling Method. Model Based Analyses. - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Uncertainty in Hard, Soft and Hard-Soft Modeling

Uncertainty in Hard, Soft and Hard-Soft

Modeling

Page 2: Uncertainty in Hard, Soft and Hard-Soft Modeling

Uncertainty in Calculated Model

Parameters using Hard- Modeling Method

Page 3: Uncertainty in Hard, Soft and Hard-Soft Modeling

The very rigid constraints of a chemical model form a framework within which the fit is confined and which results in a robust analysis, in model-free analysis, this framework is dramatically wider and looser and these methods suffer gradually from a sever lack of robustness. It must be remembered, however, that the choice of the wrong model necessarily results in the rung analysis and wrong resulting parameters.

Model Based Analyses

Page 4: Uncertainty in Hard, Soft and Hard-Soft Modeling

Complex Formation Equilibrium

M + L ML [M] [L][ML ]

Kf =[ ]

CL = [L] + [ML]CM = [M] + [ML ]

CM = [M] + KF [M] [L]

CL = [L] + KF [M] [L]

Page 5: Uncertainty in Hard, Soft and Hard-Soft Modeling

Data.m

Spectrophotometric monitoring of complex

formation titration

Page 6: Uncertainty in Hard, Soft and Hard-Soft Modeling

200 250 300 3500

500

1000

1500

2000

2500

Wavelength

Molar A

bsorptivity

0 0.5 1 1.5 2 2.5 3 3.5 40

0.1

0.2

0.3

0.4

0.5

0.6

0.7

0.8

0.9

1x 10-3

Mole Ratio, CM/CL

[spe

cies

]

LML

Page 7: Uncertainty in Hard, Soft and Hard-Soft Modeling

200 250 300 350-0.5

0

0.5

1

1.5

2

Wavelength

Abs

orba

nce

Page 8: Uncertainty in Hard, Soft and Hard-Soft Modeling

Calculation of Model ParameterThe task of model-based data fitting for a given matrix A, is to determine the best parameters defining matrix C, as well as the best pure responses collected in matrix E.

A = C E + R

A C E R= +

The quality of the fit is represented by the matrix of residuals. Assuming white noise, the sum of the squares, ssq, of all elements ri,j is statistically the best measure to be minimized ssq = ΣΣ r2 I,j

R = A – C E = A – C C+ A = f( A, model, K)

Page 9: Uncertainty in Hard, Soft and Hard-Soft Modeling

1 1.5 2 2.5 3 3.5 4 4.5 5 5.5 60

5

10

15

20

25

30

log beta

ssq

Calculation of Model Parameter

Page 10: Uncertainty in Hard, Soft and Hard-Soft Modeling

How we can calculate the precision of model parameter?

3.4 3.42 3.44 3.46 3.48 3.5 3.52 3.54 3.56 3.58 3.6

0.18

0.2

0.22

0.24

0.26

0.28

0.3

0.32

0.34

0.36

log beta

ssq

Repeatation

Page 11: Uncertainty in Hard, Soft and Hard-Soft Modeling

3.496 3.497 3.498 3.499 3.5 3.501 3.502 3.503 3.504 3.5050

2

4

6

8

10

12

14

Calculated K

Freq

uenc

y

Distribution of 50 calculated KDistribution of Fitted Model Parameters

log (Kf) (mean) = 3.5004 Standard Deviation of log (Kf)= 0.0021

Page 12: Uncertainty in Hard, Soft and Hard-Soft Modeling

Main_ML_S.m

Search for K in a certain range

Page 13: Uncertainty in Hard, Soft and Hard-Soft Modeling
Page 14: Uncertainty in Hard, Soft and Hard-Soft Modeling
Page 15: Uncertainty in Hard, Soft and Hard-Soft Modeling

?Based on repeatation procedure, calculate the standard deviation of fitted parameter in different level of noise

Page 16: Uncertainty in Hard, Soft and Hard-Soft Modeling

Error Propagation

y = f (x)

var (y) = (df/ dx)2 var (x)

y = f (x1, x2)var (y) = (df/dx1)2 var (x1) + (df/dx2)2 var(x2) + (df/d(x1) d(f)/d(x2) 2cov(x1, x2)

Page 17: Uncertainty in Hard, Soft and Hard-Soft Modeling

Var(x) =

var(x1), cov(x1, x2), … , cov(x1,xn) cov(x2, x1), var(x1), … , cov(x2, xn)

… … …

cov(xn, x1), cov(xn, x2), … , var(xn)

JT= [ df/dx1, df/dx2, …, df/dxn]

y = f (x1, x2, x3, …)var (y) = JT [Var (x)] J

General Error Propagation

Page 18: Uncertainty in Hard, Soft and Hard-Soft Modeling

R = A – C E = A – C C+ A = f( A, model, p)A = C E + R

Var(p) =

var(p1), cov(p1, p2), … , cov(p1,pn) cov(p2, p1), var(p2), … , cov(p2, pn)

… … …

cov(pn, p1), cov(pn, p2), … , var(pn)

var (R) =JT [Var(p)] JVar(p) =(JT J)-1 var (R)

var (R) = (Ri,j)2/(nm-np) = ssq/df

Uncertainty of fitted model parameters

Page 19: Uncertainty in Hard, Soft and Hard-Soft Modeling

R(p1+p1) – R(p1-p1)J1= dR/dp1= 2p1

J1 …J2 JnJ =

JnJ2J1

J =

Jacobian Matrix

Page 20: Uncertainty in Hard, Soft and Hard-Soft Modeling

JT J =

J1TJ1 J1

TJ2 … J1TJn

J2TJ1 J2

TJ2 … J2TJn ………

JnTJ1 Jn

TJ2 … JnTJn

Hessian Matrix

The inverted Hessian matrix H-1, is the variance-covariance matrix of the fitted parameters. The diagonal elements contain information on the parameter variances and the off-diagonal elements the covariances.

Page 21: Uncertainty in Hard, Soft and Hard-Soft Modeling

Newton-Gauss-Levenberg-Marquardt Algorithmguess parameters, p=pstart initial value for mp

Calculate residuals, r(p) and sum of squares, ssq

ssqold< = > ssq

Calculate Jacobian, J

Calculate shift vector p, and p = p + p

End, display results

=

>

mp=0

mp=0

<

mp ×10 mp / 3

yes

no

Page 22: Uncertainty in Hard, Soft and Hard-Soft Modeling

Main_ML.m

NGLM algorithm for Fitting

Page 23: Uncertainty in Hard, Soft and Hard-Soft Modeling
Page 24: Uncertainty in Hard, Soft and Hard-Soft Modeling
Page 25: Uncertainty in Hard, Soft and Hard-Soft Modeling
Page 26: Uncertainty in Hard, Soft and Hard-Soft Modeling
Page 27: Uncertainty in Hard, Soft and Hard-Soft Modeling

?Use Main_ML m-file for fitting the three parameters (K, CM and CL) with different initial estimates

Page 28: Uncertainty in Hard, Soft and Hard-Soft Modeling

?Check the uncertainty calculated for K when the initial concentrations are fixed or fitted

Page 29: Uncertainty in Hard, Soft and Hard-Soft Modeling

Correlation between Fitted Parameters

When two parameters are fitted, is there any relation between calculated parameters?

Is there any relation between the estimated uncertainties on K and C0?

?????????????????????????????????????????

KC0

Page 30: Uncertainty in Hard, Soft and Hard-Soft Modeling

Main_ML_corr.m

Correlation between fitted parameters

Page 31: Uncertainty in Hard, Soft and Hard-Soft Modeling
Page 32: Uncertainty in Hard, Soft and Hard-Soft Modeling
Page 33: Uncertainty in Hard, Soft and Hard-Soft Modeling

?What are the relations between the shapes and values of Jacobian with variance and covariance of parameters?

Page 34: Uncertainty in Hard, Soft and Hard-Soft Modeling

?Using the J matrix and calculate the corelation between parameters

Page 35: Uncertainty in Hard, Soft and Hard-Soft Modeling

Propagation of Uncertainty from Initial Concentration to Equilibrium Constant

K = f(residual, C0)

var(K) = (df/d(residual))2var(residual) +

(dK/dC0)2 var (C0)

(dK/dC0)2 Sensitivity of K to C0

Kopt(C0+C0) – Kopt(C0-C0)dK/dC0 =

2C0

Page 36: Uncertainty in Hard, Soft and Hard-Soft Modeling

Main_ML_C0

Propagation of uncertainty from C) to K

Page 37: Uncertainty in Hard, Soft and Hard-Soft Modeling

?What is the effect of noise on measured signal in uncertainty of K due to C0?

Page 38: Uncertainty in Hard, Soft and Hard-Soft Modeling

?Modify the Main_ML_cO m-file for considering the uncertainty in C0

M and C0L