| KADD 2022 Laboratorium 5 ENFrom Łukasz Graczykowski(Difference between revisions) Lgraczyk  (Talk | contribs) (Created page with "{| align="right" | __TOC__ |} == Exercise == Measurements of three physical observables <code>X1, X2</code> oraz <code>X3</code> have been made. Results of the measurements ar...") Newer edit → Revision as of 10:48, 28 March 2022
 
 ExerciseMeasurements of three physical observables   Dane1.dat, Dane2.dat oraz Dane3.dat. 
 Variables  
 Y2 = 3 + 0.5 X1 + 4 X2 Please calculate: 
 Attention
 ifstream ifile;
ifile.open("dane.dat");
double val;
while(ifile>>val)
{
  cout<<val<<endl;
}
ifile.close();
  double x1min = 1.5, x1max = 5.0;
 double x2min = 0.0, x2max = 3.0;
 double x3min = 4.0, x3max = 16.0;
 TH2D *h12 = new TH2D("h12","Hist12",100,x1min,x1max,100,x2min,x2max);
 TH2D *h13 = new TH2D("h13","Hist13",100,x1min,x1max,100,x3min,x3max);
 TH2D *h23 = new TH2D("h13","Hist23",100,x2min,x2max,100,x3min,x3max);
ResultsOutput: X1=3.00691, u(X1)=0.495242
X2=2.00581, u(X1)=0.40909
X3=9.97287, u(X3)=1.98102
rho(X1,X2)=0.156132
rho(X1,X3)=-0.00698853
rho(X2,X3)=0.00875851
after rounding to 2 significant digits:
X1=3.01, u(X1)=0.50
X2=2.01, u(X1)=0.41
X3=9.97, u(X3)=1.98
 
This is the matrix of covariance for X
3x3 matrix is as follows
     |      0    |      1    |      2    |
--------------------------------------------
   0 |     0.2453      0.0316   -0.006855 
   1 |     0.0316      0.1674      0.0071 
   2 |  -0.006855      0.0071       3.924 
 
This is the matrix of covariance for Y
2x2 matrix is as follows
     |      0    |      1    |
-------------------------------
   0 |      9.765       3.949 
   1 |      3.949       2.865 
Y1=26.0157, u(Y1)=3.1249
Y2=12.5267, u(Y2)=1.6927404
rho(Y1,Y2)=0.746574
rho(Y2,Y1)=0.746574
after rounding to 2 significant digits:
Y1=26.02, u(Y1)=3.13
Y2=12.53, u(Y2)=1.70
 | 

