A weighted least-squares fit gives a fitted intercept and slope with means

PHYSICS · Subjective · Fermi University Physics · Scientific Practice & Experimental Methods · Data analysis and model fitting in the laboratory · Data analysis and model fitting in the laboratory

Error, Chance and the Machine, Ch Monte Carlo integration and variance reduction

Problem

A weighted least-squares fit gives a fitted intercept aa and slope bb with means ⟨a⟩=5.0\langle a\rangle = 5.0, ⟨b⟩=2.0\langle b\rangle = 2.0 and covariance matrix V=(4.03.03.09.0)\mathsf{V} = \begin{pmatrix} 4.0 & 3.0 \\ 3.0 & 9.0 \end{pmatrix} in the fit's units (so var(a)=4.0\mathrm{var}(a) = 4.0, var(b)=9.0\mathrm{var}(b) = 9.0, cov(a,b)=3.0\mathrm{cov}(a,b) = 3.0). Using the Cholesky factor L\mathsf{L} of V\mathsf{V} (with V=LLT\mathsf V = \mathsf L\mathsf L^{\rm T} and L\mathsf L lower triangular, so that L=RT\mathsf L=\mathsf R^{\rm T} for the upper-triangular factor R\mathsf R with V=RTR\mathsf V=\mathsf R^{\rm T}\mathsf R) and a pair of independent standard normal draws z1=1.0z_1 = 1.0, z2=−0.5z_2 = -0.5, generate one correlated sample (a,b)(a, b) with the fit's covariance structure.

Browse the problem library