Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Maximilian Vitz
Lecture Statistics and Data Analysis
Commits
cd362d13
Commit
cd362d13
authored
Nov 29, 2021
by
Maximilian Vitz
Browse files
Update
parent
a4f26df8
Changes
6
Expand all
Hide whitespace changes
Inline
Side-by-side
Week3/.ipynb_checkpoints/Solution3-checkpoint.ipynb
0 → 100644
View file @
cd362d13
%% Cell type:markdown id: tags:
### Error Propagation
%% Cell type:markdown id: tags:
1)
%% Cell type:markdown id: tags:
$a = 6.1
\p
m 0.1$ cm
%% Cell type:markdown id: tags:
$b = 2.8
\p
m 0.1$ cm
%% Cell type:markdown id: tags:
With 100% correlation one ends up with $
\r
ho = 1$.
%% Cell type:markdown id: tags:
$
\R
ightarrow
\t
ext{cov}(a,b) =
\r
ho
\s
igma_{a}
\s
igma_{b} =
\s
igma_{a}
\s
igma_{b}$
%% Cell type:markdown id: tags:
$
\s
igma_{f}^{2} =
\l
eft(
\f
rac{
\d
elta f}{
\d
elta a}
\r
ight)^{2}
\s
igma_{a}^{2} +
\l
eft(
\f
rac{
\d
elta f}{
\d
elta b}
\r
ight)^{2}
\s
igma_{b}^{2} + 2
\l
eft(
\f
rac{
\d
elta A}{
\d
elta a}
\r
ight)
\l
eft(
\f
rac{
\d
elta f}{
\d
elta b}
\r
ight)
\t
ext{cov}(a,b) =
\l
eft(
\f
rac{
\d
elta f}{
\d
elta a}
\r
ight)^{2}
\s
igma_{a}^{2} +
\l
eft(
\f
rac{
\d
elta f}{
\d
elta b}
\r
ight)^{2}
\s
igma_{b}^{2} + 2
\l
eft(
\f
rac{
\d
elta f}{
\d
elta a}
\r
ight)
\l
eft(
\f
rac{
\d
elta f}{
\d
elta b}
\r
ight)
\s
igma_{a}
\s
igma_{b} =
\l
eft(
\f
rac{
\d
elta f}{
\d
elta a}
\s
igma_{a} +
\f
rac{
\d
elta f}{
\d
elta b}
\s
igma_{b}
\r
ight)^{2}$
%% Cell type:markdown id: tags:
$f = A(a,b) = a
\c
dot b$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{A} =
\f
rac{
\d
elta A}{
\d
elta a}
\s
igma_{a} +
\f
rac{
\d
elta A}{
\d
elta b}
\s
igma_{b} = b
\s
igma_{a} + a
\s
igma_{b} = 0.89
\t
ext{cm}^{2}$
%% Cell type:markdown id: tags:
$f = C(a,b) = 2a + 2b$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{C} =
\f
rac{
\d
elta C}{
\d
elta a}
\s
igma_{a} +
\f
rac{
\d
elta C}{
\d
elta b}
\s
igma_{b} = 2
\s
igma_{a} + 2
\s
igma_{b} = 0.4
\t
ext{cm}$
%% Cell type:markdown id: tags:
2)
%% Cell type:markdown id: tags:
With 0% correlation one ends up with $
\r
ho = 0$.
%% Cell type:markdown id: tags:
$
\R
ightarrow
\t
ext{cov}(a,b) =
\r
ho
\s
igma_{a}
\s
igma_{b} = 0$
%% Cell type:markdown id: tags:
$
\s
igma_{f}^{2} =
\l
eft(
\f
rac{
\d
elta f}{
\d
elta a}
\r
ight)^{2}
\s
igma_{a}^{2} +
\l
eft(
\f
rac{
\d
elta f}{
\d
elta b}
\r
ight)^{2}
\s
igma_{b}^{2} + 2
\l
eft(
\f
rac{
\d
elta A}{
\d
elta a}
\r
ight)
\l
eft(
\f
rac{
\d
elta f}{
\d
elta b}
\r
ight)
\t
ext{cov}(a,b) =
\l
eft(
\f
rac{
\d
elta f}{
\d
elta a}
\r
ight)^{2}
\s
igma_{a}^{2} +
\l
eft(
\f
rac{
\d
elta f}{
\d
elta b}
\r
ight)^{2}
\s
igma_{b}^{2} $
%% Cell type:markdown id: tags:
$f = A(a,b) = a
\c
dot b$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{A} =
\s
qrt{
\l
eft(
\f
rac{
\d
elta A}{
\d
elta a}
\r
ight)^{2}
\s
igma_{a}^{2} +
\l
eft(
\f
rac{
\d
elta A}{
\d
elta b}
\r
ight)^{2}
\s
igma_{b}^{2}} =
\s
qrt{b^{2}
\s
igma_{a}^{2} + a^{2}
\s
igma_{b}^{2}} = 0.67
\t
ext{cm}^{2}$
%% Cell type:markdown id: tags:
$f = C(a,b) = 2a + 2b$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{C} =
\s
qrt{
\l
eft(
\f
rac{
\d
elta C}{
\d
elta a}
\r
ight)^{2}
\s
igma_{a}^{2} +
\l
eft(
\f
rac{
\d
elta C}{
\d
elta b}
\r
ight)^{2}
\s
igma_{b}^{2}} =
\s
qrt{4
\s
igma_{a}^{2} + 4
\s
igma_{b}^{2}} = 0.28
\t
ext{cm}$
%% Cell type:markdown id: tags:
3)
%% Cell type:markdown id: tags:
$
\l
eft(
\b
egin{array}{cc}
\s
igma_{A}^{2} &
\t
ext{cov}(A,C)
\\
\t
ext{cov}(A,C) &
\s
igma_{C}^{2}
\e
nd{array}
\r
ight) =
\l
eft(
\b
egin{array}{cc}
\f
rac{
\d
elta A}{
\d
elta a} &
\f
rac{
\d
elta A}{
\d
elta b}
\\
\f
rac{
\d
elta C}{
\d
elta a} &
\f
rac{
\d
elta C}{
\d
elta b}
\e
nd{array}
\r
ight)
\c
dot
\l
eft(
\b
egin{array}{cc}
\s
igma_{a}^{2} &
\t
ext{cov}(a,b)
\\
\t
ext{cov}(a,b) &
\s
igma_{b}^{2}
\e
nd{array}
\r
ight)
\c
dot
\l
eft(
\b
egin{array}{cc}
\f
rac{
\d
elta A}{
\d
elta a} &
\f
rac{
\d
elta C}{
\d
elta a}
\\
\f
rac{
\d
elta A}{
\d
elta b} &
\f
rac{
\d
elta C}{
\d
elta b}
\e
nd{array}
\r
ight) =
\l
eft(
\b
egin{array}{cc}
b & a
\\
2 & 2
\e
nd{array}
\r
ight)
\c
dot
\l
eft(
\b
egin{array}{cc}
\s
igma_{a}^{2} &
\t
ext{cov}(a,b)
\\
\t
ext{cov}(a,b) &
\s
igma_{b}^{2}
\e
nd{array}
\r
ight)
\c
dot
\l
eft(
\b
egin{array}{cc}
b & 2
\\
a & 2
\e
nd{array}
\r
ight)$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\l
eft(
\b
egin{array}{cc}
\s
igma_{A}^{2} &
\t
ext{cov}(A,C)
\\
\t
ext{cov}(A,C) &
\s
igma_{C}^{2}
\e
nd{array}
\r
ight) =
\l
eft(
\b
egin{array}{cc}
\s
igma_{a}^{2} b^{2} +
\s
igma_{b}^{2} a^{2} + 2 a b
\t
ext{cov} (a,b) & 2 (b
\s
igma_{2}^2 + a
\s
igma_{b}^2 +
\t
ext{cov}(a,b)(a+b))
\\
2 (b
\s
igma_{2}^2 + a
\s
igma_{b}^2 +
\t
ext{cov}(a,b)(a+b)) & 4
\s
igma_{a}^2 + 4
\s
igma_{b}^2 + 8
\t
ext{cov}(a,b)
\e
nd{array}
\r
ight)$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\t
ext{cov}(A,C) = 2 (b
\s
igma_{2}^2 + a
\s
igma_{b}^2 +
\t
ext{cov}(a,b)(a+b))$
%% Cell type:markdown id: tags:
$
\r
ho_{A,C} =
\f
rac{
\t
ext{cov}(A,C)}{
\s
igma_{A}
\s
igma_{C}}$
%% Cell type:markdown id: tags:
With 100% correlation one ends up with $
\r
ho_{a,b} = 1$, $
\s
igma_{a}=
\s
igma_{b}$.
%% Cell type:markdown id: tags:
$
\r
ho_{A,C} =
\f
rac{
\t
ext{cov}(A,C)}{
\s
igma_{A}
\s
igma_{C}} =
\f
rac{4(a+b)}{4(a+b)} = 1$
%% Cell type:markdown id: tags:
With 0% correlation one ends up with $
\r
ho_{a,b} = 0$, $
\s
igma_{a}=
\s
igma_{b}$.
%% Cell type:markdown id: tags:
$
\r
ho_{A,C} =
\f
rac{
\t
ext{cov}(A,C)}{
\s
igma_{A}
\s
igma_{C}} =
\f
rac{2(a+b)}{
\s
qrt{8(a^{2}+b^{2})}} = 0.938$
%% Cell type:markdown id: tags:
### Triangulation
%% Cell type:markdown id: tags:
1)
%% Cell type:markdown id: tags:
$l = 101.2$ m, $
\s
igma_{l} = 0.1$ m
%% Cell type:markdown id: tags:
$
\a
lpha = 87.4^{
\c
irc}$, $
\s
igma_{
\a
lpha} = 0.1^{
\c
irc}$
%% Cell type:markdown id: tags:
$
\b
eta = 87.8^{
\c
irc}$, $
\s
igma_{
\b
eta} = 0.1^{
\c
irc}$
%% Cell type:markdown id: tags:
$d =
\f
rac{l
\s
in{(
\a
lpha)}
\s
in{(
\b
eta)}}{
\s
in{(
\a
lpha +
\b
eta)}}$
%% Cell type:markdown id: tags:
$
\s
igma_{d}^{2} =
\s
igma_{
\a
lpha}^{2}
\l
eft( -
\f
rac{l
\s
in{(
\a
lpha)}
\s
in{(
\b
eta)}
\c
os{(
\a
lpha +
\b
eta)}}{
\s
in^{2}{(
\a
lpha +
\b
eta)}} +
\f
rac{l
\c
os{(
\a
lpha)}
\s
in{(
\b
eta)}}{
\s
in{(
\a
lpha +
\b
eta)}}
\r
ight)^{2} +
\s
igma_{
\b
eta}^{2}
\l
eft( -
\f
rac{l
\s
in{(
\a
lpha)}
\s
in{(
\b
eta)}
\c
os{(
\a
lpha +
\b
eta)}}{
\s
in^{2}{(
\a
lpha +
\b
eta)}} +
\f
rac{l
\s
in{(
\a
lpha)}
\c
os{(
\b
eta)}}{
\s
in{(
\a
lpha +
\b
eta)}}
\r
ight)^{2} +
\s
igma_{l}^{2}
\l
eft(
\f
rac{
\s
in{(
\a
lpha)}
\s
in{(
\b
eta)}}{
\s
in{(
\a
lpha +
\b
eta)}}
\r
ight)^{2}$
%% Cell type:markdown id: tags:
$
\R
ightarrow d =1207.36$ m, $
\s
igma_{d} = 35.63$ m
%% Cell type:markdown id: tags:
2)
%% Cell type:markdown id: tags:
Assuming $
\s
igma_{l} = 0$.
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{d}^{2} =
\s
igma_{
\a
lpha}^{2}
\l
eft( -
\f
rac{l
\s
in{(
\a
lpha)}
\s
in{(
\b
eta)}
\c
os{(
\a
lpha +
\b
eta)}}{
\s
in^{2}{(
\a
lpha +
\b
eta)}} +
\f
rac{l
\c
os{(
\a
lpha)}
\s
in{(
\b
eta)}}{
\s
in{(
\a
lpha +
\b
eta)}}
\r
ight)^{2} +
\s
igma_{
\b
eta}^{2}
\l
eft( -
\f
rac{l
\s
in{(
\a
lpha)}
\s
in{(
\b
eta)}
\c
os{(
\a
lpha +
\b
eta)}}{
\s
in^{2}{(
\a
lpha +
\b
eta)}} +
\f
rac{l
\s
in{(
\a
lpha)}
\c
os{(
\b
eta)}}{
\s
in{(
\a
lpha +
\b
eta)}}
\r
ight)^{2}$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{d} = 35.61$ m
%% Cell type:markdown id: tags:
The error on the distance is dominated by the error on the angles.
%% Cell type:markdown id: tags:
3)
%% Cell type:markdown id: tags:
$
\a
lpha =
\b
eta$, $
\s
igma_{
\a
lpha} =
\s
igma_{
\b
eta} =
\s
igma$
%% Cell type:markdown id: tags:
$
\s
igma_{d}^{2} =
\s
igma_{
\a
lpha}^{2}
\l
eft( -
\f
rac{l
\s
in{(
\a
lpha)}
\s
in{(
\b
eta)}
\c
os{(
\a
lpha +
\b
eta)}}{
\s
in^{2}{(
\a
lpha +
\b
eta)}} +
\f
rac{l
\c
os{(
\a
lpha)}
\s
in{(
\b
eta)}}{
\s
in{(
\a
lpha +
\b
eta)}}
\r
ight)^{2} +
\s
igma_{
\b
eta}^{2}
\l
eft( -
\f
rac{l
\s
in{(
\a
lpha)}
\s
in{(
\b
eta)}
\c
os{(
\a
lpha +
\b
eta)}}{
\s
in^{2}{(
\a
lpha +
\b
eta)}} +
\f
rac{l
\s
in{(
\a
lpha)}
\c
os{(
\b
eta)}}{
\s
in{(
\a
lpha +
\b
eta)}}
\r
ight)^{2}$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{d}^{2} = 2
\s
igma^{2} l^{2}
\l
eft(
\f
rac{-
\s
in{(
\a
lpha)}
\s
in{(
\a
lpha)}
\c
os{(2
\a
lpha)}}{
\s
in^{2}{(2
\a
lpha)}} +
\f
rac{
\c
os{(
\a
lpha)}
\s
in{(
\a
lpha)}}{
\s
in{(2
\a
lpha)}}
\r
ight)^{2} = 2
\s
igma^{2} l^{2}
\l
eft(
\f
rac{-
\s
in^{2}{(
\a
lpha)}
\c
os{(2
\a
lpha)} +
\c
os{(
\a
lpha)}
\s
in{(
\a
lpha)}
\s
in{(2
\a
lpha)}}{
\s
in^{2}{(2
\a
lpha)}}
\r
ight)^{2}$
%% Cell type:markdown id: tags:
Use: $
\h
space{0.5cm}$ $
\c
os(2
\a
lpha) =
\c
os^{2}{(
\a
lpha)} -
\s
in^{2}{(
\a
lpha)}$ $
\h
space{0.5cm}$ and $
\h
space{0.5cm}$ $
\s
in(2
\a
lpha) = 2
\s
in{(
\a
lpha)}
\c
os{(
\a
lpha)}$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{d}^{2} = 2
\s
igma^{2} l^{2}
\l
eft(
\f
rac{-
\s
in^{2}{(
\a
lpha)}
\c
os^{2}{(
\a
lpha)} +
\s
in^{2}{(
\a
lpha)}
\s
in^{2}{(
\a
lpha)} + 2
\c
os^{2}{(
\a
lpha)}
\s
in^{2}{(
\a
lpha)}}{
\s
in^{2}{(2
\a
lpha)}}
\r
ight)^{2} = 2
\s
igma^{2} l^{2}
\l
eft(
\f
rac{
\s
in^{2}{(
\a
lpha)}
\c
dot [ -
\c
os^{2}{(
\a
lpha)} +
\s
in^{2}{(
\a
lpha)} + 2
\c
os^{2}{(
\a
lpha)} ]}{
\s
in^{2}{(2
\a
lpha)}}
\r
ight)^{2}= 2
\s
igma^{2} l^{2}
\l
eft(
\f
rac{
\s
in^{2}{(
\a
lpha)}
\c
dot [
\c
os^{2}{(
\a
lpha)} +
\s
in^{2}{(
\a
lpha)]} }{
\s
in^{2}{(2
\a
lpha)}}
\r
ight)^{2}$
%% Cell type:markdown id: tags:
Use: $
\h
space{0.5cm}$ $
\s
in(2
\a
lpha) = 2
\s
in{(
\a
lpha)}
\c
os{(
\a
lpha)}$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{d}^{2} = 2
\s
igma^{2} l^{2}
\l
eft(
\f
rac{
\s
in^{2}{(
\a
lpha)}}{
\s
in^{2}{(2
\a
lpha)}}
\r
ight)^{2} = 2
\s
igma^{2} l^{2}
\l
eft(
\f
rac{
\s
in^{2}{(
\a
lpha)}}{4
\s
in^{2}{(
\a
lpha)}
\c
os^{2}{(
\a
lpha)}}
\r
ight)^{2} =
\f
rac{
\s
igma^{2} l^{2}}{8
\c
os^{4}{(
\a
lpha)}}$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{d}
\a
pprox
\f
rac{
\s
igma l}{
\s
qrt{8} }
\f
rac{(l/2)^{2} + d}{(l/2)^{2}}
\a
pprox
\f
rac{
\s
igma l}{
\s
qrt{8} }
\f
rac{4 d^{2}}{l^{2}} =
\s
qrt{2}
\s
igma
\f
rac{d^{2}}{l}$
%% Cell type:code id: tags:
```
python
```
Week3/Solution3.ipynb
View file @
cd362d13
%% Cell type:markdown id: tags:
### Error Propagation
%% Cell type:markdown id: tags:
1)
%% Cell type:markdown id: tags:
$a = 6.1
\p
m 0.1$ cm
%% Cell type:markdown id: tags:
$b = 2.8
\p
m 0.1$ cm
%% Cell type:markdown id: tags:
With 100% correlation one ends up with $
\r
ho = 1$.
%% Cell type:markdown id: tags:
$
\R
ightarrow
\t
ext{cov}(a,b) =
\r
ho
\s
igma_{a}
\s
igma_{b} =
\s
igma_{a}
\s
igma_{b}$
%% Cell type:markdown id: tags:
$
\s
igma_{f}^{2} =
\l
eft(
\f
rac{
\d
elta f}{
\d
elta a}
\r
ight)^{2}
\s
igma_{a}^{2} +
\l
eft(
\f
rac{
\d
elta f}{
\d
elta b}
\r
ight)^{2}
\s
igma_{b}^{2} + 2
\l
eft(
\f
rac{
\d
elta A}{
\d
elta a}
\r
ight)
\l
eft(
\f
rac{
\d
elta f}{
\d
elta b}
\r
ight)
\t
ext{cov}(a,b) =
\l
eft(
\f
rac{
\d
elta f}{
\d
elta a}
\r
ight)^{2}
\s
igma_{a}^{2} +
\l
eft(
\f
rac{
\d
elta f}{
\d
elta b}
\r
ight)^{2}
\s
igma_{b}^{2} + 2
\l
eft(
\f
rac{
\d
elta f}{
\d
elta a}
\r
ight)
\l
eft(
\f
rac{
\d
elta f}{
\d
elta b}
\r
ight)
\s
igma_{a}
\s
igma_{b} =
\l
eft(
\f
rac{
\d
elta f}{
\d
elta a}
\s
igma_{a} +
\f
rac{
\d
elta f}{
\d
elta b}
\s
igma_{b}
\r
ight)^{2}$
%% Cell type:markdown id: tags:
$f = A(a,b) = a
\c
dot b$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{A} =
\f
rac{
\d
elta A}{
\d
elta a}
\s
igma_{a} +
\f
rac{
\d
elta A}{
\d
elta b}
\s
igma_{b} = b
\s
igma_{a} + a
\s
igma_{b} = 0.89
\t
ext{cm}^{2}$
%% Cell type:markdown id: tags:
$f = C(a,b) = 2a + 2b$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{C} =
\f
rac{
\d
elta C}{
\d
elta a}
\s
igma_{a} +
\f
rac{
\d
elta C}{
\d
elta b}
\s
igma_{b} = 2
\s
igma_{a} + 2
\s
igma_{b} = 0.4
\t
ext{cm}$
%% Cell type:markdown id: tags:
2)
%% Cell type:markdown id: tags:
With 0% correlation one ends up with $
\r
ho = 0$.
%% Cell type:markdown id: tags:
$
\R
ightarrow
\t
ext{cov}(a,b) =
\r
ho
\s
igma_{a}
\s
igma_{b} = 0$
%% Cell type:markdown id: tags:
$
\s
igma_{f}^{2} =
\l
eft(
\f
rac{
\d
elta f}{
\d
elta a}
\r
ight)^{2}
\s
igma_{a}^{2} +
\l
eft(
\f
rac{
\d
elta f}{
\d
elta b}
\r
ight)^{2}
\s
igma_{b}^{2} + 2
\l
eft(
\f
rac{
\d
elta A}{
\d
elta a}
\r
ight)
\l
eft(
\f
rac{
\d
elta f}{
\d
elta b}
\r
ight)
\t
ext{cov}(a,b) =
\l
eft(
\f
rac{
\d
elta f}{
\d
elta a}
\r
ight)^{2}
\s
igma_{a}^{2} +
\l
eft(
\f
rac{
\d
elta f}{
\d
elta b}
\r
ight)^{2}
\s
igma_{b}^{2} $
%% Cell type:markdown id: tags:
$f = A(a,b) = a
\c
dot b$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{A} =
\s
qrt{
\l
eft(
\f
rac{
\d
elta A}{
\d
elta a}
\r
ight)^{2}
\s
igma_{a}^{2} +
\l
eft(
\f
rac{
\d
elta A}{
\d
elta b}
\r
ight)^{2}
\s
igma_{b}^{2}} =
\s
qrt{b^{2}
\s
igma_{a}^{2} + a^{2}
\s
igma_{b}^{2}} = 0.67
\t
ext{cm}^{2}$
%% Cell type:markdown id: tags:
$f = C(a,b) = 2a + 2b$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{C} =
\s
qrt{
\l
eft(
\f
rac{
\d
elta C}{
\d
elta a}
\r
ight)^{2}
\s
igma_{a}^{2} +
\l
eft(
\f
rac{
\d
elta C}{
\d
elta b}
\r
ight)^{2}
\s
igma_{b}^{2}} =
\s
qrt{4
\s
igma_{a}^{2} + 4
\s
igma_{b}^{2}} = 0.28
\t
ext{cm}$
%% Cell type:markdown id: tags:
3)
%% Cell type:markdown id: tags:
$
\l
eft(
\b
egin{array}{cc}
\s
igma_{A}^{2} &
\t
ext{cov}(A,C)
\\
\t
ext{cov}(A,C) &
\s
igma_{C}^{2}
\e
nd{array}
\r
ight) =
\l
eft(
\b
egin{array}{cc}
\f
rac{
\d
elta A}{
\d
elta a} &
\f
rac{
\d
elta A}{
\d
elta b}
\\
\f
rac{
\d
elta C}{
\d
elta a} &
\f
rac{
\d
elta C}{
\d
elta b}
\e
nd{array}
\r
ight)
\c
dot
\l
eft(
\b
egin{array}{cc}
\s
igma_{a}^{2} &
\t
ext{cov}(a,b)
\\
\t
ext{cov}(a,b) &
\s
igma_{b}^{2}
\e
nd{array}
\r
ight)
\c
dot
\l
eft(
\b
egin{array}{cc}
\f
rac{
\d
elta A}{
\d
elta a} &
\f
rac{
\d
elta C}{
\d
elta a}
\\
\f
rac{
\d
elta A}{
\d
elta b} &
\f
rac{
\d
elta C}{
\d
elta b}
\e
nd{array}
\r
ight) =
\l
eft(
\b
egin{array}{cc}
b & a
\\
2 & 2
\e
nd{array}
\r
ight)
\c
dot
\l
eft(
\b
egin{array}{cc}
\s
igma_{a}^{2} &
\t
ext{cov}(a,b)
\\
\t
ext{cov}(a,b) &
\s
igma_{b}^{2}
\e
nd{array}
\r
ight)
\c
dot
\l
eft(
\b
egin{array}{cc}
b & 2
\\
a & 2
\e
nd{array}
\r
ight)$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\l
eft(
\b
egin{array}{cc}
\s
igma_{A}^{2} &
\t
ext{cov}(A,C)
\\
\t
ext{cov}(A,C) &
\s
igma_{C}^{2}
\e
nd{array}
\r
ight) =
\l
eft(
\b
egin{array}{cc}
\s
igma_{a}^{2} b^{2} +
\s
igma_{b}^{2} a^{2} + 2 a b
\t
ext{cov} (a,b) & 2 (b
\s
igma_{2}^2 + a
\s
igma_{b}^2 +
\t
ext{cov}(a,b)(a+b))
\\
2 (b
\s
igma_{2}^2 + a
\s
igma_{b}^2 +
\t
ext{cov}(a,b)(a+b)) & 4
\s
igma_{a}^2 + 4
\s
igma_{b}^2 + 8
\t
ext{cov}(a,b)
\e
nd{array}
\r
ight)$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\t
ext{cov}(A,C) = 2 (b
\s
igma_{2}^2 + a
\s
igma_{b}^2 +
\t
ext{cov}(a,b)(a+b))$
%% Cell type:markdown id: tags:
$
\r
ho_{A,C} =
\f
rac{
\t
ext{cov}(A,C)}{
\s
igma_{A}
\s
igma_{C}}$
%% Cell type:markdown id: tags:
With 100% correlation one ends up with $
\r
ho_{a,b} = 1$, $
\s
igma_{a}=
\s
igma_{b}$.
%% Cell type:markdown id: tags:
$
\r
ho_{A,C} =
\f
rac{
\t
ext{cov}(A,C)}{
\s
igma_{A}
\s
igma_{C}} =
\f
rac{4(a+b)}{4(a+b)} = 1$
%% Cell type:markdown id: tags:
With 0% correlation one ends up with $
\r
ho_{a,b} = 0$, $
\s
igma_{a}=
\s
igma_{b}$.
%% Cell type:markdown id: tags:
$
\r
ho_{A,C} =
\f
rac{
\t
ext{cov}(A,C)}{
\s
igma_{A}
\s
igma_{C}} =
\f
rac{2(a+b)}{
\s
qrt{8(a^{2}+b^{2})}} = 0.938$
%% Cell type:markdown id: tags:
### Triangulation
%% Cell type:markdown id: tags:
1)
%% Cell type:markdown id: tags:
$l = 101.2$ m, $
\s
igma_{l} = 0.1$ m
%% Cell type:markdown id: tags:
$
\a
lpha = 87.4^{
\c
irc}$, $
\s
igma_{
\a
lpha} = 0.1^{
\c
irc}$
%% Cell type:markdown id: tags:
$
\b
eta = 87.8^{
\c
irc}$, $
\s
igma_{
\b
eta} = 0.1^{
\c
irc}$
%% Cell type:markdown id: tags:
$d =
\f
rac{l
\s
in{(
\a
lpha)}
\s
in{(
\b
eta)}}{
\s
in{(
\a
lpha +
\b
eta)}}$
%% Cell type:markdown id: tags:
$
\s
igma_{d}^{2} =
\s
igma_{
\a
lpha}^{2}
\l
eft( -
\f
rac{l
\s
in{(
\a
lpha)}
\s
in{(
\b
eta)}
\c
os{(
\a
lpha +
\b
eta)}}{
\s
in^{2}{(
\a
lpha +
\b
eta)}} +
\f
rac{l
\c
os{(
\a
lpha)}
\s
in{(
\b
eta)}}{
\s
in{(
\a
lpha +
\b
eta)}}
\r
ight)^{2} +
\s
igma_{
\b
eta}^{2}
\l
eft( -
\f
rac{l
\s
in{(
\a
lpha)}
\s
in{(
\b
eta)}
\c
os{(
\a
lpha +
\b
eta)}}{
\s
in^{2}{(
\a
lpha +
\b
eta)}} +
\f
rac{l
\s
in{(
\a
lpha)}
\c
os{(
\b
eta)}}{
\s
in{(
\a
lpha +
\b
eta)}}
\r
ight)^{2} +
\s
igma_{l}^{2}
\l
eft(
\f
rac{
\s
in{(
\a
lpha)}
\s
in{(
\b
eta)}}{
\s
in{(
\a
lpha +
\b
eta)}}
\r
ight)^{2}$
%% Cell type:markdown id: tags:
$
\R
ightarrow d =1207.36$ m, $
\s
igma_{d} = 35.63$ m
%% Cell type:markdown id: tags:
2)
%% Cell type:markdown id: tags:
Assuming $
\s
igma_{l} = 0$.
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{d}^{2} =
\s
igma_{
\a
lpha}^{2}
\l
eft( -
\f
rac{l
\s
in{(
\a
lpha)}
\s
in{(
\b
eta)}
\c
os{(
\a
lpha +
\b
eta)}}{
\s
in^{2}{(
\a
lpha +
\b
eta)}} +
\f
rac{l
\c
os{(
\a
lpha)}
\s
in{(
\b
eta)}}{
\s
in{(
\a
lpha +
\b
eta)}}
\r
ight)^{2} +
\s
igma_{
\b
eta}^{2}
\l
eft( -
\f
rac{l
\s
in{(
\a
lpha)}
\s
in{(
\b
eta)}
\c
os{(
\a
lpha +
\b
eta)}}{
\s
in^{2}{(
\a
lpha +
\b
eta)}} +
\f
rac{l
\s
in{(
\a
lpha)}
\c
os{(
\b
eta)}}{
\s
in{(
\a
lpha +
\b
eta)}}
\r
ight)^{2}$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{d} = 3
6
.61$ m
$
\R
ightarrow
\s
igma_{d} = 3
5
.61$ m
%% Cell type:markdown id: tags:
The error on the distance is dominated by the error on the angles.
%% Cell type:markdown id: tags:
3)
%% Cell type:markdown id: tags:
$
\a
lpha =
\b
eta$, $
\s
igma_{
\a
lpha} =
\s
igma_{
\b
eta} =
\s
igma$
%% Cell type:markdown id: tags:
$
\s
igma_{d}^{2} =
\s
igma_{
\a
lpha}^{2}
\l
eft( -
\f
rac{l
\s
in{(
\a
lpha)}
\s
in{(
\b
eta)}
\c
os{(
\a
lpha +
\b
eta)}}{
\s
in^{2}{(
\a
lpha +
\b
eta)}} +
\f
rac{l
\c
os{(
\a
lpha)}
\s
in{(
\b
eta)}}{
\s
in{(
\a
lpha +
\b
eta)}}
\r
ight)^{2} +
\s
igma_{
\b
eta}^{2}
\l
eft( -
\f
rac{l
\s
in{(
\a
lpha)}
\s
in{(
\b
eta)}
\c
os{(
\a
lpha +
\b
eta)}}{
\s
in^{2}{(
\a
lpha +
\b
eta)}} +
\f
rac{l
\s
in{(
\a
lpha)}
\c
os{(
\b
eta)}}{
\s
in{(
\a
lpha +
\b
eta)}}
\r
ight)^{2}$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{d}^{2} = 2
\s
igma^{2} l^{2}
\l
eft(
\f
rac{-
\s
in{(
\a
lpha)}
\s
in{(
\a
lpha)}
\c
os{(2
\a
lpha)}}{
\s
in^{2}{(2
\a
lpha)}} +
\f
rac{
\c
os{(
\a
lpha)}
\s
in{(
\a
lpha)}}{
\s
in{(2
\a
lpha)}}
\r
ight)^{2} = 2
\s
igma^{2} l^{2}
\l
eft(
\f
rac{-
\s
in^{2}{(
\a
lpha)}
\c
os{(2
\a
lpha)} +
\c
os{(
\a
lpha)}
\s
in{(
\a
lpha)}
\s
in{(2
\a
lpha)}}{
\s
in^{2}{(2
\a
lpha)}}
\r
ight)^{2}$
%% Cell type:markdown id: tags:
Use: $
\h
space{0.5cm}$ $
\c
os(2
\a
lpha) =
\c
os^{2}{(
\a
lpha)} -
\s
in^{2}{(
\a
lpha)}$ $
\h
space{0.5cm}$ and $
\h
space{0.5cm}$ $
\s
in(2
\a
lpha) = 2
\s
in{(
\a
lpha)}
\c
os{(
\a
lpha)}$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{d}^{2} = 2
\s
igma^{2} l^{2}
\l
eft(
\f
rac{-
\s
in^{2}{(
\a
lpha)}
\c
os^{2}{(
\a
lpha)} +
\s
in^{2}{(
\a
lpha)}
\s
in^{2}{(
\a
lpha)} + 2
\c
os^{2}{(
\a
lpha)}
\s
in^{2}{(
\a
lpha)}}{
\s
in^{2}{(2
\a
lpha)}}
\r
ight)^{2} = 2
\s
igma^{2} l^{2}
\l
eft(
\f
rac{
\s
in^{2}{(
\a
lpha)}
\c
dot [ -
\c
os^{2}{(
\a
lpha)} +
\s
in^{2}{(
\a
lpha)} + 2
\c
os^{2}{(
\a
lpha)} ]}{
\s
in^{2}{(2
\a
lpha)}}
\r
ight)^{2}= 2
\s
igma^{2} l^{2}
\l
eft(
\f
rac{
\s
in^{2}{(
\a
lpha)}
\c
dot [
\c
os^{2}{(
\a
lpha)} +
\s
in^{2}{(
\a
lpha)]} }{
\s
in^{2}{(2
\a
lpha)}}
\r
ight)^{2}$
%% Cell type:markdown id: tags:
Use: $
\h
space{0.5cm}$ $
\s
in(2
\a
lpha) = 2
\s
in{(
\a
lpha)}
\c
os{(
\a
lpha)}$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{d}^{2} = 2
\s
igma^{2} l^{2}
\l
eft(
\f
rac{
\s
in^{2}{(
\a
lpha)}}{
\s
in^{2}{(2
\a
lpha)}}
\r
ight)^{2} = 2
\s
igma^{2} l^{2}
\l
eft(
\f
rac{
\s
in^{2}{(
\a
lpha)}}{4
\s
in^{2}{(
\a
lpha)}
\c
os^{2}{(
\a
lpha)}}
\r
ight)^{2} =
\f
rac{
\s
igma^{2} l^{2}}{8
\c
os^{4}{(
\a
lpha)}}$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\s
igma_{d}
\a
pprox
\f
rac{
\s
igma l}{
\s
qrt{8} }
\f
rac{(l/2)^{2} + d}{(l/2)^{2}}
\a
pprox
\f
rac{
\s
igma l}{
\s
qrt{8} }
\f
rac{4 d^{2}}{l^{2}} =
\s
qrt{2}
\s
igma
\f
rac{d^{2}}{l}$
%% Cell type:code id: tags:
```
python
```
...
...
Week5/.ipynb_checkpoints/Solution_5-checkpoint.ipynb
0 → 100644
View file @
cd362d13
%% Cell type:markdown id: tags:
### Likelihood Estimation
%% Cell type:markdown id: tags:
1)
%% Cell type:markdown id: tags:
$
\m
athcal{L}=
\e
xp{
\l
eft(-
\f
rac{[
\s
in{(
\t
heta)}-s]^{2}}{2
\s
igma^{2}}
\r
ight)}
\e
xp{
\l
eft(-
\f
rac{[
\c
os{(
\t
heta)}-c]^{2}}{2
\s
igma^{2}}
\r
ight)}$
%% Cell type:markdown id: tags:
$
\m
athcal{l} =
\l
og{(
\m
athcal{L})} = -
\l
eft(
\f
rac{[
\s
in{(
\t
heta)}-s]^{2}}{2
\s
igma^{2}} +
\f
rac{[
\c
os{(
\t
heta)}-c]^{2}}{2
\s
igma^{2}}
\r
ight)$
%% Cell type:markdown id: tags:
$
\f
rac{
\d
elta
\m
athcal{l}}{
\d
elta
\t
heta} = -
\f
rac{1}{
\s
igma^{2}} [
\c
os{(
\t
heta)}(
\s
in{(
\t
heta)}-s) -
\s
in{(
\t
heta)}(
\c
os{(
\t
heta)}-c) ] =
\f
rac{
\c
os{(
\t
heta)}s -
\s
in{(
\t
heta)}c}{
\s
igma^{2}}
\o
verset{
\m
athrm{!}}{=} 0$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\h
at{
\t
heta} =
\t
ext{atan}
\l
eft(
\f
rac{s}{c}
\r
ight)$
%% Cell type:markdown id: tags:
2)
%% Cell type:markdown id: tags:
$
\f
rac{
\d
elta^{2}
\m
athcal{l}}{
\d
elta
\t
heta^{2}} = -
\f
rac{
\s
in{(
\t
heta)}s +
\c
os{(
\t
heta)}c}{
\s
igma^{2}}$
%% Cell type:markdown id: tags:
$
\l
eft
\l
angle
\f
rac{
\d
elta^{2}
\m
athcal{l}}{
\d
elta
\t
heta^{2}}
\r
ight
\r
angle = -
\f
rac{1}{
\s
igma^{2}}$
%% Cell type:markdown id: tags:
### Maximum Likelihood Method
%% Cell type:markdown id: tags:
1)
%% Cell type:markdown id: tags:
$
\m
athcal{L} =
\l
eft(
\b
egin{array}{c}
N
\\
k
\e
nd{array}
\r
ight)
\c
dot p^{k}
\c
dot (1-p)^{N-k}$
%% Cell type:markdown id: tags:
$
\m
athcal{l} =
\l
og{(
\m
athcal{L})} =
\s
um_{i}
\l
eft[
\t
ext{log}
\l
eft(
\b
egin{array}{c}
N
\\
k
\e
nd{array}
\r
ight) + k_{i}
\t
ext{log}(p) + (N-k_{i})
\t
ext{log}(1-p)
\r
ight]$
%% Cell type:markdown id: tags:
$
\f
rac{
\d
elta
\m
athcal{l}}{
\d
elta p} =
\s
um_{i}
\l
eft(
\f
rac{k_{i}}{p} - (N-k_{i})
\f
rac{1}{1-p}
\r
ight)
\o
verset{
\m
athrm{!}}{=} 0$
%% Cell type:markdown id: tags:
$(1-p)
\s
um_{i} k_{i} - nNp +
\s
um_{i} k_{i} p = 0$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\h
at{p} =
\f
rac{
\s
um_{i} k_{i}}{nN}$
%% Cell type:markdown id: tags:
2)
%% Cell type:markdown id: tags:
$
\f
rac{
\d
elta^{2}
\m
athcal{l}}{
\d
elta p^{2}} =
\s
um_{i=1}^{n}
\l
eft(
\f
rac{k_{i}}{p^{2}} - (N-k_{i})
\f
rac{1}{(1-p)^{2}}
\r
ight)$
%% Cell type:markdown id: tags:
$
\l
eft
\l
angle
\f
rac{
\d
elta^{2}
\m
athcal{l}}{
\d
elta p^{2}}
\r
ight
\r
angle = n
\l
eft( -
\f
rac{pN}{p^{2}} -
\f
rac{N-pN}{(1-p)^{2}}
\r
ight) = nN
\l
eft( -
\f
rac{1}{p} -
\f
rac{1}{1-p}
\r
ight) = -nN
\f
rac{1}{p(1-p)} $
%% Cell type:markdown id: tags:
### Likelihood and Exponential
%% Cell type:markdown id: tags:
1)
%% Cell type:markdown id: tags:
$
\m
athcal{L}=
\f
rac{1}{
\t
au}
\e
xp{
\l
eft(-
\f
rac{t}{
\t
au}
\r
ight)}$
%% Cell type:markdown id: tags:
$
\m
athcal{l} =
\l
n{(
\m
athcal{L})} =
\s
um_{i}
\l
n
\l
eft[
\f
rac{1}{
\t
au}
\e
xp{
\l
eft(-
\f
rac{t_{i}}{
\t
au}
\r
ight)}
\r
ight] =
\s
um_{i}
\l
eft[ -
\f
rac{t_{i}}{
\t
au} -
\l
n(
\t
au)
\r
ight]$
%% Cell type:markdown id: tags:
$
\f
rac{
\d
elta
\m
athcal{l}}{
\d
elta
\t
au} =
\s
um_{i}
\l
eft[
\f
rac{t_{i}}{
\t
au^{2}} -
\f
rac{1}{
\t
au}
\r
ight]
\o
verset{
\m
athrm{!}}{=} 0$
%% Cell type:markdown id: tags:
$
\R
ightarrow
\h
at{
\t
au} =
\s
um_{i}
\f
rac{t_{i}}{N}$
%% Cell type:markdown id: tags:
$
\f
rac{
\d
elta^{2}
\m
athcal{l}}{
\d
elta
\t
au^{2}} =
\s
um_{i}
\l
eft[ -
\f
rac{2t_{i}}{
\t
au^{3}} +
\f
rac{1}{
\t
au^{2}}
\r
ight]$
%% Cell type:markdown id: tags:
$
\l
eft
\l
angle
\f
rac{
\d
elta^{2}
\m
athcal{l}}{
\d
elta
\t
au^{2}}
\r
ight
\r
angle = -
\f
rac{2N}{
\t
au^{2}} +
\f
rac{N}{
\t
au^{2}} = -
\f
rac{N}{
\t
au^{2}}$
%% Cell type:markdown id: tags:
2)
%% Cell type:markdown id: tags:
Show that $
\i
nt_{0}^{T} f(t;
\t
au) dt = 1$:
%% Cell type:markdown id: tags:
$
\i
nt_{0}^{T} f(t;
\t
au) dt =
\f
rac{1}{
\t
au}
\f
rac{1}{1-
\e
xp{
\l
eft(-
\f
rac{T}{
\t
au}
\r
ight)}}
\l
eft[ -
\t
au
\e
xp{
\l
eft(-
\f
rac{t}{
\t
au}
\r
ight)}
\r
ight]_{0}^{T} = 1$
%% Cell type:markdown id: tags:
%% Cell type:code id: tags:
```
python
``
`
%%
Cell
type
:
code
id
:
tags
:
```
python
```
Week5/Solution_5.ipynb
0 → 100644
View file @
cd362d13
%% Cell type:markdown id: tags:
### Likelihood Estimation
%% Cell type:markdown id: tags:
1)
%% Cell type:markdown id: tags:
$
\m
athcal{L}=
\e
xp{
\l
eft(-
\f
rac{[
\s
in{(
\t
heta)}-s]^{2}}{2
\s
igma^{2}}
\r
ight)}
\e
xp{
\l
eft(-
\f
rac{[
\c
os{(
\t
heta)}-c]^{2}}{2
\s
igma^{2}}
\r
ight)}$