summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--notes/Makefile118
-rw-r--r--notes/error_propagation_note.tex90
2 files changed, 208 insertions, 0 deletions
diff --git a/notes/Makefile b/notes/Makefile
new file mode 100644
index 0000000..5625df5
--- /dev/null
+++ b/notes/Makefile
@@ -0,0 +1,118 @@
+# -*- make -*-
+# FILE: "/home/evmik/jobs/wm/2013_fall_Experimental_Atomic_Physics_251/manual/Makefile"
+# LAST MODIFICATION: "Tue, 27 Aug 2013 10:36:02 -0400 (evmik)"
+# (C) 2001 by Eugeniy Mikhailov, <evmik@tamu.edu>
+# $Id: Makefile,v 1.3 2003/04/23 20:40:19 evmik Exp $
+
+MANUSCRIPT_DIR = $(shell basename `pwd`)
+SUBDIR=`find ./ -maxdepth 1 -type d |sed 1d| sed /CVS/d`
+
+LATEX_OPTIONS="-interaction=nonstopmode -src-specials"
+
+DATE := $(shell date +%Y%m%d)
+
+ROOT_OF_MAIN_TEX_FILE= EIT_filter
+MAIN_TEX_FILE=$(ROOT_OF_MAIN_TEX_FILE).tex
+
+source_files = $(wildcard *.tex)
+source_basename = $(source_files:%.tex=%)
+
+tex_targets = $(wildcard *.tex)
+pdf_targets = $(tex_targets:%.tex=%.pdf)
+ps_targets = $(tex_targets:%.tex=%.ps)
+dvi_targets = $(tex_targets:%.tex=%.dvi)
+
+default: pdf
+
+INCLUDED_TEX_FILES=$(wildcard chapters/*.tex)
+GENERATED_AUX_FILES=$(INCLUDED_TEX_FILES:%.tex=%.aux)
+
+
+$(INCLUDED_TEX_FILES):
+
+
+dvi: $(dvi_targets)
+
+$(dvi_targets): %.dvi : %.tex
+ rubber $<
+
+
+ps: $(ps_targets)
+
+$(ps_targets).ps: %.ps : %.dvi
+ dvips -o $@ $<
+
+
+dvipdf: $(pdf_targets)
+
+#home of dvipdfm utilit is at
+#http://gaspra.kettering.edu/dvipdfm/
+# if one want to use hyperred in pdf and dvipdfm converter
+# then \usepackage[dvipdfm]{hyperref} should be use
+# but then no links in dvi would be present
+# so we use \usepackage{hyperref} but make pdf with dvipdf
+# which do it through dvi -> ps -> pdf conversion
+#$(pdf_targets): %.pdf : %.dvi
+ #dvipdfmx $<
+ # dvipdf $<
+
+pdf: $(pdf_targets)
+
+$(pdf_targets): %.pdf : %.tex $(INCLUDED_TEX_FILES)
+ rubber -d $<
+
+
+
+zip:
+ zip -r arch.$(ROOT_OF_MAIN_TEX_FILE).`date +%F`.zip $(ROOT_OF_MAIN_TEX_FILE).tex Makefile bibliography.bib figures ol.bst osajnl.bst osajnl2.rtx osajnl2.sty `tex2figlist.sh $(ROOT_OF_MAIN_TEX_FILE).tex`
+
+clean_results:
+ rm -f $(pdf_targets)
+
+clean: clean_tex clean_bib clean_backups
+ rm -f $(ROOT_OF_MAIN_TEX_FILE).tar.gz
+
+real_clean: clean_all
+
+clean_backups:
+ rm -f *~
+
+clean_tex:
+ rm -f $(tex_targets:%.tex=%.dvi)
+ rm -f $(tex_targets:%.tex=%.log)
+ rm -f $(tex_targets:%.tex=%.aux)
+ rm -f $(tex_targets:%.tex=%.nav)
+ rm -f $(tex_targets:%.tex=%.out)
+ rm -f $(tex_targets:%.tex=%.snm)
+ rm -f $(tex_targets:%.tex=%.toc)
+ rm -f $(tex_targets:%.tex=%.vrb)
+ rm -f $(tex_targets:%.tex=%.blg)
+ rm -f $(GENERATED_AUX_FILES)
+ rm -f missfont.log
+ rm -f *Notes.bib
+
+clean_bib:
+ rm -f $(tex_targets:%.tex=%.bbl)
+
+clean_for_arxive: clean_results clean_backups clean_tex
+
+clean_all: clean clean_results clean_backups
+
+arxive_submission: $(ROOT_OF_MAIN_TEX_FILE).for_arxive.$(DATE).tar.gz
+
+$(ROOT_OF_MAIN_TEX_FILE).for_arxive.$(DATE).tar.gz: clean_for_arxive
+ cd ..; tar c --dereference --exclude=.git --exclude=*gz \
+ $(MANUSCRIPT_DIR)/$(tex_targets) \
+ $(MANUSCRIPT_DIR)/$(ROOT_OF_MAIN_TEX_FILE).bbl \
+ $(MANUSCRIPT_DIR)/ready_plots/* \
+ | gzip > $@
+ mv ../$@ .
+
+
+arch:
+ cd ..; tar c --dereference --exclude=.git --exclude=*gz $(MANUSCRIPT_DIR) |gzip > $(ROOT_OF_MAIN_TEX_FILE).$(DATE).tar.gz
+ mv ../$(ROOT_OF_MAIN_TEX_FILE).$(DATE).tar.gz .
+
+
+upload_draft_to_web:
+
diff --git a/notes/error_propagation_note.tex b/notes/error_propagation_note.tex
new file mode 100644
index 0000000..19413ed
--- /dev/null
+++ b/notes/error_propagation_note.tex
@@ -0,0 +1,90 @@
+\documentclass[letterpaper,11pt]{article}
+\usepackage{units}
+\begin{document}
+
+\section*{A note on error propagation}
+
+We are trying to find the change (uncertainty) in some function $f(x,y,z)$ when $x,y$ and $z$ are subject to change (i.e., have some uncertainty). Assuming first that only $x$ has an uncertainty $\delta x$ and that our measured values (distinct from the variables $x,y$ and $z$) are $x_0, y_0, z_0$, we have:
+
+\begin{eqnarray}\label{eq:delta_f}
+|\delta f(x_0,y_0,z_0)| & = & \left| f(x_0+\delta x, y_0, z_0) - f(x_0,y_0,z_0) \right | \\
+ & \approx & \left|[f(x_0,y_0,z_0) + \frac{\partial f}{\partial x}\Big|_{x=x_0} (x_0+\delta x - x_0)] \right. \nonumber \\
+& & \left. -f(x_0,y_0,z_0) \right| \\
+& = & \left| \frac{\partial f}{\partial x}\Big|_{x=x_0} (\delta x) \right|
+\end{eqnarray}
+
+For uncorrelated uncertainties on $x,y$ and $z$, this leads to the general formula:
+
+\begin{equation}
+(\delta f)^{2} = \left(\frac{\partial f}{\partial x}\right)^{2} (\delta x)^{2}
+ + \left(\frac{\partial f}{\partial y}\right)^{2} (\delta y)^{2}
+ + \left(\frac{\partial f}{\partial z}\right)^{2} (\delta z)^{2}
+\end{equation}
+
+Where we evaluate $f()$ and it's derivatives at $(x_0,y_0,z_0)$.
+
+\subsection*{Example from the e/m lab}
+
+We'd like to propagate errors on $e/m$. First we write down a function for $e/m$ in terms of the measured variables:
+
+\begin{equation}
+\frac{e}{m}=\left[\frac{125}{32}\frac{a^2}{\mu_{0}^2 N^{2}}\right]\frac{V}{I^2 r^2} = C \frac{V}{I^2 r^2}
+\end{equation}
+where $C$ is a constant and $V,I,r$ are the measured variables. We can now propagate errors and find the uncertainty $(e/m)_{j}$, the measured value of $e/m$ for trial $j$. We set $e/m = f(V,I,r)$ and then $(e/m)_j= f(V_j, I_j, r_j)\equiv f_j$. The uncertainty in $f_j$ is:
+\begin{eqnarray}
+(\delta f_j)^2 & = & \left(\frac{\partial f}{\partial V}\Big|_j \right)^{2} (\delta V)^{2}
+ + \left(\frac{\partial f}{\partial I}\Big|_j \right)^{2} (\delta I)^{2}
+ + \left(\frac{\partial f}{\partial r}\Big|_j \right)^{2} (\delta r)^{2} \\
+& = & \left(\frac{C}{I_j^2 r_j^2}\right)^2 (\delta V_j)^2
+ + \left(\frac{-2C V_j}{I_j^3 r_j^2}\right)^2 (\delta I_j)^2
+ + \left(\frac{-2C V_j}{I_j^2 r_j^3}\right)^2 (\delta r_j)^2 \\
+ & & \mbox{now we can rearrange a little bit} \nonumber \\
+& = & \left(\frac{CV_j}{I_j^2 r_j^2}\right)^2 \left(\frac{\delta V_j}{V_j}\right)^2
+ + \left(\frac{CV_j}{I_j^2 r_j^2}\right)^2 \left(2\frac{\delta I_j}{I_j}\right)^2
+ + \left(\frac{CV_j}{I_j^2 r_j^2}\right)^2 \left(2\frac{\delta r_j}{r_j}\right)^2
+\end{eqnarray}
+
+But $\left(\frac{CV_j}{I_j^2 r_j^2}\right)^2 = (f_j)^2$, so we have
+
+\begin{equation}\label{eq:final_em}
+(\delta f_j)^2 = (f_j)^2 \left(\frac{\delta V_j}{V_j}\right)^2
+ + (f_j)^2 \left(2\frac{\delta I_j}{I_j}\right)^2
+ + (f_j)^2 \left(2\frac{\delta r_j}{r_j}\right)^2
+\end{equation}
+The terms $\frac{\delta V_j}{V_j}$, $\frac{\delta I_j}{I_j}$, $\frac{\delta r_j}{r_j}$ are just fractional uncertainties in the measured voltage, current and radius. In this case, you had something like $\frac{\delta V_j}{V_j}\approx\frac{\unit[0.05]{V}}{\unit[250]{V}}=0.02\%$, something similar for $I$, but $\frac{\delta r_j}{r_j}\approx \frac{\unit[0.3]{cm}}{\unit[4.0]{cm}}=7.5\%$, so the last term in Eq.~\ref{eq:final_em} completely dominates the other two. Therefore:
+
+\begin{equation}\label{eq:approx_err}
+|\delta f_j| \approx |f_j| \left|2\frac{\delta r_j}{r_j}\right| = 15\%|f_j|
+\end{equation}
+
+This is the sort of analysis I'd like to see in a report and Eq.~\ref{eq:approx_err} is what you'd code into an Igor or Excel spreadsheet. Of course Eq.~\ref{eq:final_em} would also work, you'd just miss out on some intuition about what was driving the uncertainties in your experiment and could be more vulnerable to typos in the formula.
+
+\subsection*{A slightly different approach}
+
+What if derivatives of $f$ are messy to evaluate? For example as in the electron diffraction lab when you are trying to propagate uncertainties on $\sin\theta$ which involves a double angle formula, sines and inverse sines of the quantities you measured. There is a simple thing you can do, going back to Eq.~\ref{eq:delta_f}:
+
+\begin{equation}
+|\delta f(x_0,y_0,z_0)| = \left| f(x_0+\delta x, y_0, z_0) - f(x_0,y_0,z_0) \right |
+\end{equation}
+
+which can be generalized to multiple dimensions as:
+
+\begin{eqnarray}
+(\delta f(x_0,y_0,z_0))^2 & = & \left[f(x_0+\delta x, y_0, z_0) - f(x_0,y_0,z_0) \right ]^2 \nonumber \\
+& + & \left[f(x_0, y_0+\delta y, z_0) - f(x_0,y_0,z_0) \right ]^2 \nonumber \\
+& + & \left[f(x_0, y_0, z_0+\delta z) - f(x_0,y_0,z_0) \right ]^2 \nonumber
+\end{eqnarray}
+
+That is, we just reevaluate $f$ when we shift $x_0,y_0,z_0$. The shifts are independent so long as the uncertainties themselves are independent, and we add all shifts in quadrature. This avoids taking derivatives and may, or may not, be less messy. Also, note, I claim it's a little better to do this:
+
+\begin{eqnarray}
+(\delta f(x_0,y_0,z_0))^2 & = & \left[\frac{1}{2}|f(x_0+\delta x, y_0, z_0) - f(x_0,y_0,z_0)| \right. \\
+& + & \left. \frac{1}{2}\left|f(x_0-\delta x, y_0, z_0) - f(x_0,y_0,z_0)\right| \right]^2 \nonumber \\
+& + & \quad \mbox{similar terms for $y$ and $z$}
+\end{eqnarray}
+That is, average the effect of shifting by $\pm \delta x$.
+
+\subsection*{Final Note}
+Whatever you do, be clear about what you are assuming for input uncertainties and the specific formula for $\delta f$! We don't need to see all steps in deriving $\delta f$ but we must be able to plug your $x_i, y_i, z_i$ and $\delta x_i, \delta y_i, \delta z_i$ into your formula to get your $\delta f_i$.
+
+\end{document}