11.3.1: Media y varianza
- Page ID
- 131418
\( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)
\( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)
\( \newcommand{\dsum}{\displaystyle\sum\limits} \)
\( \newcommand{\dint}{\displaystyle\int\limits} \)
\( \newcommand{\dlim}{\displaystyle\lim\limits} \)
\( \newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\)
( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\)
\( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)
\( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\)
\( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)
\( \newcommand{\Span}{\mathrm{span}}\)
\( \newcommand{\id}{\mathrm{id}}\)
\( \newcommand{\Span}{\mathrm{span}}\)
\( \newcommand{\kernel}{\mathrm{null}\,}\)
\( \newcommand{\range}{\mathrm{range}\,}\)
\( \newcommand{\RealPart}{\mathrm{Re}}\)
\( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)
\( \newcommand{\Argument}{\mathrm{Arg}}\)
\( \newcommand{\norm}[1]{\| #1 \|}\)
\( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)
\( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\AA}{\unicode[.8,0]{x212B}}\)
\( \newcommand{\vectorA}[1]{\vec{#1}} % arrow\)
\( \newcommand{\vectorAt}[1]{\vec{\text{#1}}} % arrow\)
\( \newcommand{\vectorB}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)
\( \newcommand{\vectorC}[1]{\textbf{#1}} \)
\( \newcommand{\vectorD}[1]{\overrightarrow{#1}} \)
\( \newcommand{\vectorDt}[1]{\overrightarrow{\text{#1}}} \)
\( \newcommand{\vectE}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash{\mathbf {#1}}}} \)
\( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)
\(\newcommand{\longvect}{\overrightarrow}\)
\( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)
\(\newcommand{\avec}{\mathbf a}\) \(\newcommand{\bvec}{\mathbf b}\) \(\newcommand{\cvec}{\mathbf c}\) \(\newcommand{\dvec}{\mathbf d}\) \(\newcommand{\dtil}{\widetilde{\mathbf d}}\) \(\newcommand{\evec}{\mathbf e}\) \(\newcommand{\fvec}{\mathbf f}\) \(\newcommand{\nvec}{\mathbf n}\) \(\newcommand{\pvec}{\mathbf p}\) \(\newcommand{\qvec}{\mathbf q}\) \(\newcommand{\svec}{\mathbf s}\) \(\newcommand{\tvec}{\mathbf t}\) \(\newcommand{\uvec}{\mathbf u}\) \(\newcommand{\vvec}{\mathbf v}\) \(\newcommand{\wvec}{\mathbf w}\) \(\newcommand{\xvec}{\mathbf x}\) \(\newcommand{\yvec}{\mathbf y}\) \(\newcommand{\zvec}{\mathbf z}\) \(\newcommand{\rvec}{\mathbf r}\) \(\newcommand{\mvec}{\mathbf m}\) \(\newcommand{\zerovec}{\mathbf 0}\) \(\newcommand{\onevec}{\mathbf 1}\) \(\newcommand{\real}{\mathbb R}\) \(\newcommand{\twovec}[2]{\left[\begin{array}{r}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\ctwovec}[2]{\left[\begin{array}{c}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\threevec}[3]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\cthreevec}[3]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\fourvec}[4]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\cfourvec}[4]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\fivevec}[5]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\cfivevec}[5]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\mattwo}[4]{\left[\begin{array}{rr}#1 \amp #2 \\ #3 \amp #4 \\ \end{array}\right]}\) \(\newcommand{\laspan}[1]{\text{Span}\{#1\}}\) \(\newcommand{\bcal}{\cal B}\) \(\newcommand{\ccal}{\cal C}\) \(\newcommand{\scal}{\cal S}\) \(\newcommand{\wcal}{\cal W}\) \(\newcommand{\ecal}{\cal E}\) \(\newcommand{\coords}[2]{\left\{#1\right\}_{#2}}\) \(\newcommand{\gray}[1]{\color{gray}{#1}}\) \(\newcommand{\lgray}[1]{\color{lightgray}{#1}}\) \(\newcommand{\rank}{\operatorname{rank}}\) \(\newcommand{\row}{\text{Row}}\) \(\newcommand{\col}{\text{Col}}\) \(\renewcommand{\row}{\text{Row}}\) \(\newcommand{\nul}{\text{Nul}}\) \(\newcommand{\var}{\text{Var}}\) \(\newcommand{\corr}{\text{corr}}\) \(\newcommand{\len}[1]{\left|#1\right|}\) \(\newcommand{\bbar}{\overline{\bvec}}\) \(\newcommand{\bhat}{\widehat{\bvec}}\) \(\newcommand{\bperp}{\bvec^\perp}\) \(\newcommand{\xhat}{\widehat{\xvec}}\) \(\newcommand{\vhat}{\widehat{\vvec}}\) \(\newcommand{\uhat}{\widehat{\uvec}}\) \(\newcommand{\what}{\widehat{\wvec}}\) \(\newcommand{\Sighat}{\widehat{\Sigma}}\) \(\newcommand{\lt}{<}\) \(\newcommand{\gt}{>}\) \(\newcommand{\amp}{&}\) \(\definecolor{fillinmathshade}{gray}{0.9}\)Supongamos que tiene un conjunto de valores\(a_{j}\). Al decir que esto es un conjunto, queremos decir que tenemos varios valores\(a_{1}\),\(a_{2}\),\(a_{3}\), y así sucesivamente. La notación\(a_{j}\), en este contexto, significa que\(j\) puede ser reemplazado por cualquier entero entre 1 y el número total de valores que tenga para hacer referencia a ese valor específico. Supongamos que tenemos valores\(N\) totales. El promedio de todos nuestros valores se puede escribir como:
\[\langle a\rangle=\frac{1}{N} \sum_{j} a_{j}\tag{11.10}\]
La letra\(\Sigma\) es la letra griega mayúscula “sigma”. Esta notación significa que sumas todos los valores de los\(a_{j}\) que tienes. Por ejemplo, supongamos que solo tenía cuatro valores\(a_{1}, a_{2}, a_{3}\), y\(a_{4}\), luego:
\[\sum_{j} a_{j}=a_{1}+a_{2}+a_{3}+a_{4}\tag{11.11}\]
Por lo tanto, el valor medio (o promedio) de\(a\) en este contexto es:
\[\langle a\rangle=\frac{1}{N} \sum_{j} a_{j}=\frac{1}{N}\left(a_{1}+a_{2}+a_{3}+a_{4}\right)\tag{11.12}\]
Para cuantificar la incertidumbre sobre un conjunto de valores, queremos decir algo sobre qué tan lejos, en promedio, está un valor dado de la media de todos los valores. Así, es tentador tratar de definir la incertidumbre de la siguiente manera:
\[\frac{1}{N} \sum_{j}\left(a_{j}-\langle a\rangle\right)\tag{11.13}\]
Recuerda que la adición es conmutativa. Al darse cuenta de que el\(\sum\) símbolo solo indica una suma, es decir, mucha suma, podemos reescribir esto como:
\[\frac{1}{N}\left(\sum_{j} a_{j}-\sum_{j}\langle a\rangle\right)\tag{11.14}\]
El segundo término en la resta es una suma por encima\(j\) del valor promedio. El valor promedio no depende de cuál\(a_{j}\) estemos hablando; es una constante, es lo mismo para todos ellos. Por lo tanto, la suma de ese número de\(N\) veces sólo va a ser igual a\(N\langle a\rangle\). Haciendo esta sustitución y distribuyendo el 1/\(N\) entre paréntesis:
\[\frac{1}{N} \sum_{j} a_{j}-\frac{1}{N} N\langle a\rangle\tag{11.15}\]
Pero reconocemos el primer término en esta resta como justo\(\langle a\rangle\). Entonces, el resultado total de esto es cero. Claramente, esta no es una buena expresión para la incertidumbre en\(a\). Si lo piensas, la desviación promedio de\(a_{j}\) desde\(\langle a\rangle\) debería ser cero. Si\(\langle a\rangle\) es el valor promedio de\(a\), entonces\(a_{j}\) debería estar por debajo\(\langle a\rangle\) aproximadamente con la frecuencia que esté por encima, por lo que su suma tendrá una mezcla de términos positivos y negativos. La definición misma del promedio asegura que esta suma será cero.
En su lugar, definiremos la varianza como:
\[\Delta a^{2}=\frac{1}{N} \sum_{j}\left(a_{j}-\langle a\rangle\right)^{2}\tag{11.16}\]
Aquí, estamos usando\(\Delta a\) para indicar la incertidumbre en\(a\). La varianza se define como la incertidumbre al cuadrado. 1 La ventaja de esta expresión es que debido a que estamos cuadrando la diferencia entre cada valor\(a_{j}\) y el valor promedio, siempre vamos a estar sumando términos positivos; no habrá términos negativos para cancelar los términos positivos. Por lo tanto, esta debería ser una estimación razonable de qué tan lejos, típicamente,\(a_{j}\) están las mediciones de su promedio.
Podemos desempaquetar esta suma un poco, primero multiplicando el polinomio cuadrado:
\[\Delta^{2}=\frac{1}{N} \sum_{j}\left(a_{j}^{2}-2\langle a\rangle a_{j}+\langle a\rangle^{2}\right)\tag{11.17}\]
Para limpiar esta expresión, dentro de los paréntesis suman y restan\(\langle a\rangle^{2}\):
\ [\ begin {alineado}
\ Delta a^ {2} &=\ frac {1} {N}\ sum_ {j}\ izquierda (a_ {j} ^ {2} -2\ langle a\ rangle a_ {j} +2\ langle a\ rangle^ {2} -\ langle a\ rangle^ {2}\ derecha)\\
&=\ frac {1} N}\ suma_ {j}\ izquierda (a_ {j} ^ {2} -\ langle a\ rangle^ {2} +2\ langle a\ rangle\ izquierda (\ langle a\ rangle-a_ {j}\ derecha)\ derecha)\\
&=\ frac {1} {N}\ suma_ {j} a_ {j} ^ {2} -\ frac {1} {N}\ suma_ {j}\ langle a\ rangle^ {2} +\ frac {1} {N} 2\ langle a\ rangle\ sum_ {j}\ izquierda (\ langle a\ rangle-a_ {j} derecha)
\ end {alineado}\ tag {11.18}\]
Observe que el último término va a ser cero, ya que incluye la diferencia promedio entre la media y cada observación. El segundo término sólo va a ser\(\langle a\rangle^{2}\), porque una vez más\(\langle a\rangle\) es el mismo para todos los términos de la suma; la suma cederá\(N\langle a\rangle^{2}\), cancelando el\(N\) en el denominador. Entonces, tenemos:
\[\Delta a^{2}=\left\langle a^{2}\right\rangle-\langle a\rangle^{2}\tag{11.19}\]
1 Si conoces estadísticas, es posible que reconozcas esto como muy similar a cómo se define la varianza ahí, solo en las estadísticas, dividimos por en\(N −1\) lugar de por\(N\). La diferencia se vuelve poco importante a medida que\(N\) se hace grande.


