Index: trunk/doc/release.2015/ps1.analysis/analysis.tex
===================================================================
--- trunk/doc/release.2015/ps1.analysis/analysis.tex	(revision 37893)
+++ trunk/doc/release.2015/ps1.analysis/analysis.tex	(revision 37897)
@@ -282,5 +282,5 @@
 \begin{itemize}
 \item {\bf Image preparation} Load data, characterize the image
-  background, load or construct noise and mask images.
+  background, load or construct variance and mask images.
 
 \item {\bf Initial object detection} Smooth, find peaks, measure basic
@@ -301,5 +301,5 @@
 
 \item {\bf Output} Write out objects in selected format, write out
-  difference image, noise image, etc, as selected.
+  difference image, variance image, etc, as selected.
 \end{itemize}
 
@@ -317,15 +317,12 @@
 defining which pixels are valid and which should be ignored.  The
 signal and variance images are represented internally as 32-bit
-floating point values.  The noise and mask images may either
+floating point values.  The variance and mask images may either
 be provided by the user, or they may be automatically generated from
 the input image, based on configuration-defined values for the image
 gain, read-noise, saturation, and so forth.  For the function-call
 form of the program, the flux image is provided in the API, and
-references to the mask and noise are provided in the configuration
-information.  As in the stand-alone C-program, the noise and mask may
+references to the mask and variance are provided in the configuration
+information.  As in the stand-alone C-program, the variance and mask may
 be constructed automatically by PSPhot.
-
-\note{describe the use of the covariance image}
-\note{describe the difference between 'bad' and 'suspect' pixels}
 
 The mask is represented as 16-bit integer image in which a value of 0
@@ -347,5 +344,15 @@
 \code{XMIN}, \code{XMAX}, \code{YMIN}, \code{YMAX}.
 
-The noise image, if not supplied is constructed by default from the
+PSPhot (and other IPP) functions understand two types of masked
+pixels: ``bad'' and ``suspect''.  Bad pixels are those which should
+not be used in any operations, while suspect pixels are those for
+which the reported signal may be contaminated or biased, but may be
+useable in some contexts.  For example, a pixel with poor charge
+transfer efficiency is likely to be too untrustworthy to use in any
+circumstance, while a pixel in which persistence ghosts have been
+subtracted might be useful for detection or even analysis of brighter
+sources.  \note{can I identify which functions respect which sets of masks}
+
+The variance image, if not supplied is constructed by default from the
 flux image using the configuration supplied values of \code{GAIN} and
 \code{READ\_NOISE} to calculate the appropriate Poisson statistics for
@@ -355,7 +362,23 @@
 if the input flux image is the result of an image stack with a
 variable number of input measurements per pixel (due to masking and
-dithering), it will be necessary to supply a noise image which
-accurately represents the noise as a function of position in the
+dithering), the variance cannot be calculated from the signal image
+alone.  It is necessary in such a case to supply a variance image which
+accurately represents the variance as a function of position in the
 image.
+
+Some image processing steps introduce cross-correlation between pixel
+fluxes.  An obvious case is smoothing, but geometric transformations
+which redistibute fractional flux between neighboring pixels also
+introduces cross-correlations.  In the noise model, it is necessary to
+track the impact of the cross correlations on the per-pixel variance.
+In the general case, this would require a complete covariance image,
+consisting of the set of cross-correlated pixels for each image pixel.
+Since a typical smoothing or warping operation may introduce
+correlation between 25 - 100 neighboring pixels, the size of such a
+covariance image is prohibitive.  In practice, however, there are two
+extreme cases which generally are relevant.  \note{talk about the
+  covar matrix for a PSF}
+
+\subsection{Background (Sky) Model}
 
 \subsection{Initial Object Detection}
@@ -635,10 +658,10 @@
 make a good guess for the centroid and shape parameters for the PSF
 models.  \note{still true? In order to minimize the impact of close
-  neighbors, the noise values used in the fit are enhanced by a
+  neighbors, the variance values used in the fit are enhanced by a
   fraction of the deviation of the particular pixel value from the
   model guess.}  Any objects which fail to converge in the fit are
 flagged as invalid.
 
-\note{does the noise enhancement introduce too much bias?}
+\note{does the variance enhancement introduce too much bias?}
 
 \note{discuss the convergence criteria, model parameter guesses}
@@ -813,5 +836,5 @@
 process modifies the image pixels (removing the fitted flux, though
 not the locally fitted background) but does not modify the mask or the
-noise images.  The signal-to-noise ratio in the image after
+variance images.  The signal-to-noise ratio in the image after
 subtraction represents the significance of the remaining flux.  If the
 subtractions are sufficiently accurate models of the PSF flux
@@ -819,5 +842,5 @@
 significance.  In practice the cores of bright stars are poorly
 represented and may have larger residual significance. \note{in future
-work, we may choose to enhance the noise to minimize detection of
+work, we may choose to enhance the variance to minimize detection of
 objects in the residuals of brighter objects}.
 
@@ -880,5 +903,5 @@
 the image as is done for the successful PSF model fits.  Of course,
 the background flux is retained, with the result that only the object
-is subtracted from the image.  Again, the noise image is (currently)
+is subtracted from the image.  Again, the variance image is (currently)
 not modified.  
 
@@ -897,5 +920,5 @@
 this stage, the new peaks are detected on the image with the bright
 objects subtracted.  In this pass, the peak detection process uses the
-noise image to test the validity of the individual peaks.  All peaks
+variance image to test the validity of the individual peaks.  All peaks
 with a significance greater than a user-defined minimum threshold are
 accepted as objects of potential interest.  
@@ -943,5 +966,5 @@
 \note{In the ideal case, if we were only interested in detecting PSFs,
 and we had a good model for the PSF, we could optimally find the
-sources by smoothing the image and the noise image with the PSF model.
+sources by smoothing the image and the variance image with the PSF model.
 \em write out the description of Nick's optimal PSF finding}.
 
@@ -1075,7 +1098,7 @@
 \subsection{Difference Images}
 
-The noise map for a difference image must be generated from the two
+The variance map for a difference image must be generated from the two
 images use to construct the difference.  Otherwise, the low sky level
-will automatically result in inconsistent interpretation of the noise.
+will automatically result in inconsistent interpretation of the variance.
 
 For a difference image, both positive and negative objects will be
