Index: trunk/doc/release.2015/systematics.20140411/systematics.tex
===================================================================
--- trunk/doc/release.2015/systematics.20140411/systematics.tex	(revision 40099)
+++ trunk/doc/release.2015/systematics.20140411/systematics.tex	(revision 40102)
@@ -1,3 +1,4 @@
-\documentclass[iop,floatfix]{emulateapj}
+% \documentclass[iop,floatfix]{emulateapj}
+\documentclass[10pt,preprint]{aastex}
 % \pdfoutput=1
 
@@ -22,12 +23,12 @@
 \def\plotext{ps}
 
-\def\picdir{/home/eugene/chipresid.20140404}
-%\def\picdir{/data/kukui.2/eugene/chipresid.20140404}
+%\def\picdir{/home/eugene/chipresid.20140404}
+\def\picdir{/data/kukui.2/eugene/chipresid.20140404}
 
 % Pick a terse version of the title here;
-\shorttitle{Systematics in PS1}
+\shorttitle{Charge Diffusion Variations in PS1}
 \shortauthors{E.A. Magnier et al}
 \begin{document}
-\title{Systematic Effects in Pan-STARRS1 Photometry and Astrometry}
+\title{Charge Diffusion Variations in Pan-STARRS\,1 CCDs}
 
 % this is a crude trick to get the order of affiliations right.  These
@@ -50,5 +51,5 @@
 %PS Builder List
 % W.~S. Burgett,\altaffilmark{\IfA}
-% K.~C. Chambers,\altaffilmark{\IfA} 
+K.~C. Chambers,\altaffilmark{\IfA} 
 % L. Denneau,\altaffilmark{\IfA}
 % P. Draper,\altaffilmark{\DUR}
@@ -85,14 +86,20 @@
 \begin{abstract}
 
-Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vestibulum
-bibendum nisi id tristique posuere. Duis eu mollis nulla. Maecenas est
-turpis, mattis tempor urna vitae, placerat rhoncus sem. Lorem ipsum
-dolor sit amet, consectetur adipiscing elit. Sed quis velit
-nisl. Aliquam erat volutpat. Cras lacinia, nisl tristique auctor
-molestie, dolor nulla rhoncus purus, ac accumsan nunc nunc ac
-nibh. Maecenas vitae mollis mauris. Ut sollicitudin pulvinar purus,
-eget luctus lorem tincidunt vitae. Vestibulum eu mattis neque. Nulla
-in tortor id urna dapibus gravida a vel leo.
-
+Thick back-illuminated deep-depletion CCDs have superior quantum
+efficiency over previous generations of thinned and traditional thick
+CCDs.  As a result, they are being used for major wide-field imaging
+cameras in several projects.  We use observations from the Pan-STARRS
+$3\pi$ survey to characterize the behavior of the deep-depletion
+devices used in the Pan-STARRS\,1 Gigapixel Camera.  We have
+identified systematic variations in the photometric behavior and
+stellar profiles which are similar to the so-called tree rings
+identified in devices used by other wide-field cameras (DECam and
+Hypersuprime Camera).  The tree-ring features identified in these
+other cameras result from lateral electric fields which displace the
+electrons as they are transported in the silicon to the pixel
+location.  In contrast, we show that the photometric and morphological
+modifications observed in the GPC1 detectors are caused by variations
+in the vertical charge transportation range and resulting charge
+diffusion variations.
 \end{abstract}
 
@@ -102,17 +109,106 @@
 \section{INTRODUCTION}\label{sec:intro}
 
-\begin{verbatim}
-* early CCDs were thick, but low resistivity Si had low cross-section to red photons
-* thinning was used to improve the blue sensitivity, at the cost of further reducing the red sensitivity
-* by the early 2000s, high-resistivity Si was used to make thick "deep-depletion" devices with good red and blue response.
-* voltages?
-* sky-scraper pixels
-* Plazas et al and other effects
-* 
-\end{verbatim}
+CCD detectors have evolved greatly since they were first introduced
+for astronomical imaging in the mid 1970s.  In addition to the
+well-known increases in the size of CCDs over the past 4 decades, CCD
+architecture has gone through three major evolutionary stages.  
+
+The first generation of CCDs used a silicon substrate a few hundred
+microns thick on top of which gate structures were deposited to define
+the pixels.  A positive voltage applied to the gate layers would
+create a shallow region (\approx 10 microns thick) in which the holes
+were depleted.  This ``depletion region'' acted as a potential well to
+trap electrons, specifically those generated by absorbed photons.  The
+thick silicon substrate required illumination from the ``front'' side
+with the thin gate structures to allow the photons to reach the
+depletion region and be detected.  These early CCDs had modest quantum
+efficiency as photons were easily absorbed by the several micron thick
+gate structures.  For an excellent review of the history of CCD
+development, see \cite{1992ASPC...23....1J}.
+
+Thinned, backside-illuminated CCDs such as the TI 3PCCD
+\citep{1981SPIE..290....6B} were developed to address the quantum
+efficiency limitations of the first generation thick CCDs.  The
+silicon substrate was removed using a chemical process, leaving a
+delicate device only \approx 10 - 20\micron\ thick, exposing the
+depletion region on the backside.  Photons entering the backside of
+the device are not blocked by the gate structures and thus more easily
+absorbed and detected.  Thinned backside-illuminated CCDs have high
+quantum efficiency to blue photons.  However, as the wavelength
+increases beyond \approx 800 nm, the silicon becomes more transparent
+to the photons, with a corresponding drop in quantum efficiency for
+red photons.  In addition, thin film interference between the entering
+photons and those reflecting off the front side of the CCD result in
+``fringe'' patterns for redder photons.
+
+Early generations of CCDs were made of low-resistivity (\approx 10 -
+50 $\Omega$-cm) silicon.  Following experiments beginning in the early
+1990s \citep{Holland.1996}, CCDs made from thick, high-resistivity ($
+> 10 k\Omega$-cm) silicon were developed for astronomical instruments
+in the early 2000s\citep{Holland.2003}.  The high-resistivity of the
+silicon allows for depletion regions of hundreds of microns in depth,
+compared to \approx 10\micron\ for the low-resistivity silicon.  This
+modification allows for a back-illuminated CCD with a relatively thick
+silicon subtrate of 75 - 300\micron.  Blue photons impinging on the
+back of the device are absorbed near the back surface of the device
+and are caried through the depletion region to the gates on the front
+side.  The thick silicon allows red photons to have a greater chance
+to be absorbed, increasing quantum efficiency in the red.  Because
+these thick, deep-depletion devices have near-unity quantum efficiency
+across the whole a very wide spectral range, they have become the
+design of choice for many modern, large-scale CCD cameras (e.g.,
+Pan-STARRS GPC1, \citealt{2009amos.confE..40T}; Subaru Hypersuprime
+Camera, \citealt{2010SPIE.7735E..3FK}; Dark Energy Survey Camera,
+\citealt{2015AJ....150..150F}).
+
+While these deep-depletion CCDs seem to be ideal, they do have
+features which can cause challenges for precise measurements.  As a
+result of the ``Brighter-Fatter Effect''
+\citep{2014JInst...9C3048A,2015JInst..10C5032G}, the profile of bright
+stars are measured to be wider than the profiles of faint stars.  The
+accepted interpretation is that the electric fields produced by the
+electrons accumulated from a star repel successive incoming electrons,
+with the repulsion increasing the more electrons have accumulated.
+
+The effects of lateral electric fields are likewise identified as the
+cause of the so-called ``Tree-Rings'' observed in the flat-field,
+astrometry, and photometry response of thick deep depletion detectors
+\citep{2014PASP..126..750P}.  These tree-ring patterns have been noted
+in the flat-field response of deep depletion devices since their early
+testing \citep[see, e.g., Figure 2 in][]{2010SPIE.7735E..1RE} and were
+initially considered to be a sensitivity response which could be
+removed with a flat-field.  As discussed in detail by
+\cite{2014PASP..126..750P}, these Tree Rings are more correctly
+interpretted as variations in the effective pixel area due to
+migration of the electrons pushed by lateral electric fields induced
+by small changes in the doping used to set the resistivity of the
+silicon.  The changes in the effective area result in changes to the
+apparent flat-field response as well as the astrometric response of
+the detector.  More subtly, the flat-field response changes, since
+they do not reflect actual variations in sensitivity, can lead to
+systematic photometry errors for astronomical sources if the
+flat-field images are used in the standard fashion.
+
+In this paper, we examine the behavior of an apparently-similar kind
+of Tree Ring observed in the Pan-STARRS GPC1 CCDs.  Although we also
+observe the pixel effective area changes caused by lateral electric
+fields as described by \cite{2014PASP..126..750P}, we show below a
+second effect which is more important in driving systematic photometry
+errors.  We find that variations in charge diffusion, also resulting
+from changes in the silicon doping structures, affect both the
+observed stellar profiles as well as the photometry measured with
+profile fitting techniques.  In Section~\ref{sec:PS1}, we discuss the
+Pan-STARRS telescope, camera, and survey data used in this analysis.
+In Section~\ref{sec:tree.rings}, we present the Tree-Ring-like
+patterns as observed in several different types of measurements:
+flat-field response, systematic photometry residuals, systematic
+astrometric residuals, and stellar profile shape variations.  In
+Section~\ref{sec:discussion}, we discuss the interpretation of
+patterns we observe and present a simple model to explain the observed
+behavior.  We conclude with a discussion of the implications of this
+effect on astronomical measurements from deep depletion instruments
 
 \section{Pan-STARRS1}
-
-\note{tidy up this section}
+\label{sec:PS1}
 
 The 1.8m Pan-STARRS\,1 telescope (PS1), located on the summit of
@@ -121,12 +217,12 @@
 March 2014, PS1 was run under the aegis of the Pan-STARRS Science
 Consortium to perform a set of wide-field science surveys; since March
-2014, the telescope is operated by the Pan-STARRS New Science
+2014, the telescope has been operated by the Pan-STARRS New Science
 Consortium (PSNSC).  Under the PS1SC, the largest survey, both in
-terms of area of the sky covered and fraction of observing time
-(56\%), was the \TPS\ in which the entire sky north of Declination
-$-30$\degrees\ was imaged up \approx 80 times over the 4 years.  These
-observations were distributed over five filters, \grizy, and have been
-astrometrically and photometrically calibrated to good precision
-\citep{magnier2017.calibration}.
+terms of area of the sky covered ($3\pi$ steradians) and fraction of
+observing time (56\%), was the \TPS\ in which the entire sky north of
+Declination $-30$\degrees\ was imaged up \approx 80 times over 4
+years.  These observations were distributed over five filters, \grizy,
+and have been astrometrically and photometrically calibrated to good
+precision \citep{magnier2017.calibration}.
 
 % 2004SPIE.5489..667H == PS1.optics
@@ -138,18 +234,17 @@
 \citep[GPC1][]{2009amos.confE..40T}, with low distortion and generally
 good image quality.  The median seeing for the \TPS\ data vary
-somewhat by filter, with (\grizy) = (XXXX).  Routine observations are
-conducted remotely from the Advanced Technology Research Center in
-Kula, the main facility of the University of Hawaii's Institute for
-Astronomy operations on Maui.
-
-GPC1 \citep{2009amos.confE..40T}, currently the largest astronomical camera in
-terms of number of pixels, consists of a mosaic of 60 edge-abutted
-$4800\times4800$ pixel detectors, with 10~$\mu$m pixels subtending
-0.258~arcsec. These \note{OTA51} detectors, manufactured by Lincoln
-Laboratory, are \note{75$\mu$m}-thick back-illuminated CCDs with a
-readout time of 7 seconds for a full unbinned image. \note{details
-  about the voltages?}  Initial performance assessments are presented
-in \cite{2008SPIE.7014E..0DO}. The active, usable pixels cover $\sim 80$\% of the
-FOV.
+somewhat by filter: (\grizy) = (1.31, 1.19, 1.11, 1.07, 1.02)
+arcseconds.  Routine observations are conducted remotely from the
+Advanced Technology Research Center in Kula, the main facility of the
+University of Hawaii's Institute for Astronomy operations on Maui.
+
+GPC1 \citep{2009amos.confE..40T}, currently the largest astronomical
+camera in terms of number of pixels, consists of a mosaic of 60
+edge-abutted $4800\times4800$ pixel detectors, with 10~$\mu$m pixels
+subtending 0.258~arcsec. These CCID58 detectors, manufactured by
+Lincoln Laboratory, are 75\micron-thick back-illuminated CCDs
+\citep{Tonry.2006,Tonry.2008}.  Initial performance assessments are
+presented in \cite{2008SPIE.7014E..0DO}. The active, usable pixels
+cover \approx 80\% of the FOV.
 
 \subsection{Data Processing and Calibration}
@@ -161,16 +256,17 @@
 
 Images obtained by PS1 are processed by the Pan-STARRS Image
-Processing Pipeline (IPP; \citealp{PS1_IPP,magnier2017.datasystem}).  All observations are processed
-nightly, with results sent to groups within the science consortium
-(i.e., PS1SC during the \TPS) performing short-term science projects
-(e.g., searching for transient and moving objects).  In addition, the
-\TPS\ dataset has been re-processed several times with improved
-calibration and analysis techniques.  To date (2017 July), 3
-re-processings starting from raw pixel data have been performed.  The
-labels PV0, PV1, PV2, PV3 are used identify the nightly processing and
-successive re-processing versions.  PV3 has been used for the public
-release of the Pan-STARRS \TPS\ data via the {\it Barbara A. Mikulski
-  Archive for Space Telescopes} (MAST) at the Space Telescope Science
-Institute.\footnote{http//panstarrs.stci.edu}
+Processing Pipeline (IPP;
+\citealp{2006amos.confE..50M,magnier2017.datasystem}).  All
+observations are processed nightly, with results sent to groups within
+the science consortium (i.e., PS1SC during the \TPS) performing
+short-term science projects (e.g., searching for transient and moving
+objects).  In addition, the \TPS\ dataset has been re-processed
+several times with improved calibration and analysis techniques.  To
+date (2017 July), 3 re-processings starting from raw pixel data have
+been performed.  The labels PV0, PV1, PV2, PV3 are used identify the
+nightly processing and successive re-processing versions.  PV3 has
+been used for the public release of the Pan-STARRS \TPS\ data via the
+{\it Barbara A. Mikulski Archive for Space Telescopes} (MAST) at the
+Space Telescope Science Institute.\footnote{http//panstarrs.stci.edu}
 
 The data processing and calibration operations are discussed in detail
@@ -207,20 +303,19 @@
 factors which may make the flat-field image inconsistent with stellar
 photometry, e.g., SED, filter band-pass variations, etc
-\citep[see][]{waters2017,2004PASP..116..449M,magnier.belgium}.  This
-correction was made on a relatively coarse grid across the focal plane
-in order to accumulate sufficient statistics from the stars in the
-relatively small number of images available at the time.  We have
+\citep[see][]{waters2017,2004PASP..116..449M,2007ASPC..364..153M}.
+This correction was made on a relatively coarse grid across the focal
+plane in order to accumulate sufficient statistics from the stars in
+the relatively small number of images available at the time.  We have
 found that a single flat-field set can be used for all PS1
 observations to yield photometric consistency at the level of \approx
-2\% \note{use the ubercal flat stdev as a statistic}.  PS1 benefits in
-this regard from the stability of having a single instrument which is
-rarely removed.  
+2\%.  PS1 benefits in this regard from the stability of having a
+single instrument which is rarely removed.
 
 Photometry of the PS1 images is performed using a
 point-spread-function (PSF) model as well as multiple kinds of
-apertures \citep{magnier2017.analysis}.  In this analysis, we
-refer to aperture photometry performed using an aperture defined based
-on the image quality observed for a given chip.  The aperture diameter
-is set to be \note{XXX} times the FWHM for the image.
+apertures \citep{magnier2017.analysis}.  In this analysis, we refer to
+aperture photometry performed using an aperture defined based on the
+image quality observed for a given chip.  The aperture diameter is set
+to be \approx 3.75 times the FWHM for the image.
 
 To improve the photometric systematic errors beyond the level achieved
@@ -228,17 +323,18 @@
 photometry is re-calibrated within the databasing system based on the
 properties of the measured photometry.  The calibration process is
-discussed by \cite{2012ApJ...756..158S,2013ApJS..205...20M,magnier2017.calibration}.
+discussed by
+\cite{2012ApJ...756..158S,2013ApJS..205...20M,magnier2017.calibration}.
 As part of this process, several flat-field corrections have been
 determined.  For the PV2 analysis discussed here, a flat-field
 correction determined during the ubercal analysis
-\citep[see][]{2012ApJ...756..158S} consisted of an $8\times 8$ grid of corrections
-for each GPC1 chip and filter for each of 4 seasons.  The boundaries
-of those seasons are \note{tentatively} identified with modifications
-to the baffle structures or the system optics.  The critical point
-here is that the final effective flat-field image for the PV2 dataset
-is based on a dome-flat at the highest resolution, with very low
-resolution corrections based on photometry, resulting in photometric
-calibration with roughly 1 millimag consistency for each measurement
-\note{better number from ubercal?}.
+\citep[see][]{2012ApJ...756..158S} consisted of an $8\times 8$ grid of
+corrections for each GPC1 chip and filter for each of 4 seasons.  The
+boundaries of those seasons are tentatively identified with
+modifications to the baffle structures or the system optics.  The
+critical point here is that the final effective flat-field image for
+the PV2 dataset is based on a dome-flat at the highest resolution,
+with very low resolution corrections based on photometry, resulting in
+photometric systmatic uncertainties in the range 7 - 12
+millimagnitudes, depending on the filter \citep{2013ApJS..205...20M}.
 
 For all objects, positions are measured from the PSF model for the
@@ -252,4 +348,5 @@
 
 \section{Tree-Ring-Like Patterns}
+\label{sec:tree.rings}
 
 \begin{table}
@@ -274,7 +371,7 @@
 For many of the GPC1 OTA CCDs, we observe a pattern in the photometric
 residuals which is similar in appearence to the Tree Rings described
-in the Dark Energy Camera (DECam) by \cite{plazas.2014}.  This pattern
-consists of systematic deviations which are consistent in a set of
-circular arcs centered on the corner of the CCD, as shown in
+in the Dark Energy Camera (DECam) by \cite{2014PASP..126..750P}.  This
+pattern consists of systematic deviations which are consistent in a
+set of circular arcs centered on the corner of the CCD, as shown in
 Figure~\ref{fig:psfmags.by.filter}.  The details of the analysis used
 to generate Figure~\ref{fig:psfmags.by.filter} are given below.  For
@@ -282,13 +379,14 @@
 circular silicon wafer into 4 inscribed squares.  Thus the corners of
 the CCDs lie in the center of the silicon boule, just as the center of
-the circular Tree Rings described by \cite{plazas.2014} match the
-center of the boule from which they came.  This gives the impression
-that a similar mechanism is responsible for the pattern observed in
-the PS1 photometry and the DECam photometry, namely the diffusive
-effects of lateral electric field variations in the detectors.  In the
-next section, we will make the case that the patterns observed in the
-PS1 residuals are {\em not} caused by this mechanism, but are instead
-caused by variations in the {\em vertical} electric field (the field
-direction perpendicular to the CCD surface).  
+the circular Tree Rings described by \cite{2014PASP..126..750P} match
+the center of the boule from which they came.  This gives the
+impression that a similar mechanism is responsible for the pattern
+observed in the PS1 photometry and the DECam photometry, namely the
+diffusive effects of lateral electric field variations in the
+detectors.  In the next section, we will make the case that the
+patterns observed in the PS1 photometry residuals are {\em not} caused
+by this mechanism, but are instead caused by variations in the {\em
+  vertical} electric field (the field direction perpendicular to the
+CCD surface).
 
 First, in this section, we will describe how we have measured the
@@ -296,10 +394,9 @@
 For all of these examples, we use a single GPC1 CCD (XY40) to
 illustrate the effects in detail, but a similar set of effects are
-seen in \note{many? most?} GPC1 detectors.  First, we show the
-residual PSF photometry.  Second, we show the residual Aperture
-photometry.  Third, we show the astrometric residual patterns.
-Fourth, we show the patterns observed in the flat-field images.
-Finally, we show measurements derived from the second-moments of the
-stars.
+seen in many of the GPC1 detectors.  First, we show the residual PSF
+photometry.  Second, we show the residual Aperture photometry.  Third,
+we show the astrometric residual patterns.  Fourth, we show the
+patterns observed in the flat-field images.  Finally, we show
+measurements derived from the second-moments of the stars.
 
 For all effects discussed below, we are measuring the mean value of
@@ -308,5 +405,5 @@
 represents the same range of true GPC1 XY40 pixels regardless of the
 type of measurement.  To generate the photometry, astrometry, or
-second-moment measurements were extracted from the \note{PV0} DVO
+second-moment plots, measurements were extracted from the PV0 DVO
 database for observations covering the region ($\alpha$,$\delta$) =
 (90\degree\ -- 150\degree, -25\degree\ -- 10\degree).  This region of
@@ -358,5 +455,5 @@
 
 Figure~\ref{fig:psfmags.by.filter} shows the 2D patterns of PSF
-photometric residuals.  In this case, we select PSF magnitude
+photometry residuals.  In this case, we select PSF magnitude
 measurements for detections of stars which fall in the given
 superpixel.  We subtract each measurement from the average magnitude
@@ -378,5 +475,5 @@
 is comparable to the amplitude of the correlated structures, so we
 need to integrate along the radial structures to make stronger
-statements about these patterns. \note{hanging statement?}
+statements about these patterns.
 
 Figure~\ref{fig:apmags.by.filter} shows the equivalent measurement for
@@ -462,7 +559,7 @@
 then observed by the PS1 telescope.  These flat-field images were
 obtained 2011 Feb 09 as part of a campaign to study the PS1 system
-response \citep{2012ApJ...750...99T}.  Flats were obtain in a set of 4nm steps,
-with \note{XXnm} band-pass.  To enhance the signal-to-noise, we have
-median-combined a set of 6 flats at the center of the corresponding filter.
+response \citep{2012ApJ...750...99T}.  Flats were obtain in a set of
+4nm steps.  To enhance the signal-to-noise, we have median-combined a
+set of 6 flats at the center of the corresponding filter.
 
 In order to mask pixels which do not flatten well, we generate a
@@ -535,5 +632,5 @@
 multiple detections).  The second moments are measured with a Gaussian
 weighting function, with the $\sigma_{w}$ scaled by the PSF size so
-that the $\sigma$ measured for PSF stars is \approx 60\% of
+that the $\sigma$ measured for PSF stars is \approx 65\% of
 $\sigma_{w}$.  (Note that, since the measured $\sigma$ of stellar
 objects is biased down by the weighting function, this is not quite
@@ -541,11 +638,10 @@
 discussion in \citealt{magnier2017.analysis}).  For each stellar
 detection, we extract the values $M_{xx,xy,yy} = \sum F_i w_i (x^2, x
-y, y^2) / \sum F_i w_i$.  For each exposure, we find the mean second
-moments ($\bar{M_{xx,xy,yy}}$) for PSF objects on this chip (XY40) and
-subtract that mean value from the instantaneous measurements of
-$M_{xx,xy,yy}$.  We then determine the median of the residual second
-moments for each superpixel, resulting in 3 images for each filter.
-
-\note{write out this math, check out psLibADD}
+y, y^2) / \sum F_i w_i$.  For each exposure, we find the median second
+moments for PSF objects on this chip (XY40) and subtract that median
+value from the instantaneous measurements of $M_{xx,xy,yy}$.  We then
+determine the median of the residual second moments for each
+superpixel, resulting in 3 images ($\delta M_{xx,xy,yy}$) for each
+filter.
 
 Using the second moment images, we can construct certain interesting
@@ -559,9 +655,9 @@
 related to the shape of the elliptical contour as follows:
 \begin{eqnarray}
-e_0 & = & \sigma^2_a  + \sigma^2_b \\
-e_1 & = & (\sigma^2_a  - \sigma^2_b) \cos (2 \theta) \\
-e_2 & = & \sigma^2_a  - \sigma^2_b 
+e_0 & = & \sigma^2_{\mbox{major}}  + \sigma^2_{\mbox{minor}} \\
+e_1 & = & (\sigma^2_{\mbox{major}}  - \sigma^2_{\mbox{minor}}) \cos (2 \theta) \\
+e_2 & = & \sigma^2_{\mbox{major}}  - \sigma^2_{\mbox{minor}}
 \end{eqnarray}
-Where $\sigma_a$ and $\sigma_b$ are the major and minor axis
+Where $\sigma_{\mbox{major}}$ and $\sigma_{\mbox{minor}}$ are the major and minor axis
 dimensions of the ellipse and $\theta$ is the position angle.  
 Thus, $e_0$ is a measurement of the change in the size of the stellar
@@ -570,7 +666,6 @@
 can determine the angle of the PSF ellipticity from the $e_1$ term.
 
-Figure~\ref{fig:smear.by.filter} shows the spatial trend of the {\em
-  smear}, $\sigma^2_{major} + \sigma^2_{minor} = \delta M_{xx} +
-\delta M_{yy}$.  This value corresponds to the increase or decrease in
+Figure~\ref{fig:smear.by.filter} shows the spatial trend of $e_0$, the {\em
+  smear}.  This value corresponds to the increase or decrease in
 the circularly-symmetric component of the image size.  The dynamic
 range of these images is -0.3 to +0.3 pixel$^2$. A tree-ring-like
@@ -579,16 +674,15 @@
 can also be seen.
 
-We can also construct a measurement of the change in ellipticity
-$\sigma^2_{major} - \sigma^2_{minor} = (M_{xx} - M_{yy})^2 + 4
-M_{xy}$.  This value is plotted in Figure~\ref{fig:shear.by.filter}.
-This value is positive definite and is plotted with a color scale
-ranging from -0.02 to 0.22 pixel$^2$.  We can also determine the
-orientation of the corresponding ellipse.  Overlayed on
+Figure~\ref{fig:shear.by.filter} shows the spatial trend of $e_2$, the
+{\em shear}.  This value is positive definite and is plotted with a
+color scale ranging from -0.02 to 0.22 pixel$^2$.  We can also
+determine the orientation of the corresponding ellipse.  Overlayed on
 Figure~\ref{fig:shear.by.filter} is a set of vectors representing the
 ellipse orientation as a function of postion.  The length of the
 vectors corresponds to the value of $\sigma^2_{major} -
-\sigma^2_{minor}$.  The tree-ring-like structure is {\em not} apparent in this
-figure for any filter.  The spatial variations are low-frequency and
-unrelated to the radial trend from the upper-left corner.
+\sigma^2_{minor}$.  The tree-ring-like structure is {\em not} apparent
+in this figure for any filter.  The spatial variations are
+low-frequency and unrelated to the radial trend from the upper-left
+corner.
 
 \subsection{Correlations Between Tree-Ring-Like Patterns}
@@ -715,5 +809,5 @@
 radial component of the astrometric residuals: $\frac{\partial
   (\sigma^2_{major} + \sigma^2_{minor})}{\partial radius} \sim \delta
-R$ (see Figure~\ref{fig:dsmear.vs.astrom}.  
+R$ (see Figure~\ref{fig:dsmear.vs.astrom}).
 
 Finally, the radial derivative of the radial component of the
@@ -730,5 +824,5 @@
 residual values without a derivative.  We are convinced that we have
 the sense of the derivative correct by examination of specific
-features in each imaage (e.g., \note{give example}).
+features in each imaage.
 
 \begin{table}
@@ -781,9 +875,8 @@
 
 \section{Discussion}
+\label{sec:discussion}
 
 These trends help to illuminate the underlying causes of these
 different effects.  
-
-\note{summarize what pure lateral electric fields would do}
 
 First, if we consider the smear pattern
@@ -829,10 +922,5 @@
 The slope of our relationship is \approx 0.5 in normalized units.
 Thus the observed trends appear to be too weak by a factor of \approx
-2.  \note{looks like a slope of 1.0 would not be excluded by these
-  plots}
-
-\note{I need to use the relationship between the astrometry and the
-  flat-field to calculate the amplitude of the lateral electric
-  fields.}
+2, but otherwise exhibits the expected behavior.
 
 The fact that the PSF ellipticity changes are {\em not} correlated
@@ -846,26 +934,78 @@
 magnitudes.
 
+Finally, the correlation between the smear structures and the
+astrometry residuals shows that these two effects are connected.  The
+underlying connection is the pattern of the resistivity variations.
+Regions with high (or low) resistivity show relatively high (or low)
+amounts of smear; astrometric deviations follow the gradient between
+these regions.  
+
+We interpret the changes in the {\em smear} term as changes in the
+amount of charge diffusion.  The blue filters exhibit the strongest
+changes in the amount of smear.  These are also the filters for which
+the detected electrons have travelled the longest distance in the
+silicon, and are thus most affected by diffusion effects.  
+
+\note{add more quantitative discussion of the variations in $E_y$ vs $E_x$?}
+
 \section{Conclusion}
 
-The tree rings are showing (at least?) two effects, though they must
-be related.  First, the images are experiencing circularly-symmetric
-changes in the PSF size correlated with the tree-ring pattern.  These
-PSF size changes drive errors in the PSF photometry which the are also
-correlated with the tree ring pattern on the scale of a few
-millimagnitudes.  These PSF size changes are consistent with changes
-in the charge diffusion, which also introduces a circularly symmetric
-smearing.
-
-In addition, there are radial plate-scale changes
-correlated with the tree rings.  These plate-scale changes introduce a
-flat-field errors on the scale of \approx 1 millimagnitude and
-astrometric errors in the scale of 2-3 milliarcseconds.  The observed
-relationship between the flat-field deviations and the radial
-derivative of the astrometric deviations confirms that these two
-measurements are caused by the same effect.  
-
-There must be some common cause for both the smearing (charge
-diffusion) and the radial plate-scale changes since the astrometric
-deviations are correlated with the radial derivative of the smearing.
+The tree rings observed in the Pan-STARRS GPC1 data show (at least)
+two effects, though they are related.  First, the images are
+experiencing circularly-symmetric changes in the PSF size correlated
+with the tree-ring pattern.  These PSF size changes drive errors in
+the PSF photometry which the are also correlated with the tree ring
+pattern on the scale of a few millimagnitudes.  These PSF size changes
+are consistent with changes in the charge diffusion, which also
+introduces a circularly symmetric smearing.
+
+In addition, there are radial plate-scale changes correlated with the
+tree rings.  These plate-scale changes introduce a flat-field errors
+on the scale of \approx 1 millimagnitude and astrometric errors in the
+scale of 2-3 milliarcseconds.  The observed relationship between the
+flat-field deviations and the radial derivative of the astrometric
+deviations confirms this interpretation \citep[see discussion
+  in][]{2014PASP..126..750P}.
+
+The vertical diffusion variations and the lateral charge migration are
+both driven by the same variations in the doping structures.  This
+point is clear from the spatial correlation of the gradient in the
+smear variations and the astrometric variations.
+
+% The small-scale variations in the charge diffusion observed in these
+% devices has not been reported for DECam, Hypersuprime Cam, or
+% prototype LSST sensors.  
+
+The small-scale variations in the charge diffusion observed in the
+Pan-STARRS detectors represents a new type of systematic effect in
+deep depletion devices.  This feature, if present in other detectors,
+could manifest in systematic errors in several ways.  Like in the
+Pan-STARRS analysis example, the charge diffusion variations result in
+fine-structure in the observed stellar point-spread functions.  For
+very precise photometry or morphological analysis, it will be
+necessary for the PSF models to account for the extra charge
+diffusion.  Unlike the non-uniform pixel-size effects, correction of
+the PSF photometry cannot simply be performed as an average flat-field
+correction on the measurements after they have been processed.  
+The additional smearing acts as a convolution with a Gaussian kernel
+of fixed size for a given filter.  The photometry bias is a function
+of the fractional change of the PSF size.  Thus, the introduced error
+depends on the average PSF for the image in question: an image with
+good image quality will suffer larger PSF model errors than an image
+with poor image quality.  To account for this effect in a rigorous
+way, the analysis should use the measured diffusion variations to
+modify the model PSFs as a function of position before they are used
+for the image analysis.
+
+The charge diffusion variations may also have an impact on
+spectroscopic measurements.  Modern, precise spectroscopic
+measurements rely on precise measurements of the stellar line
+profiles.  If such an analysis ignores variations in the charge
+diffusion, the measured line widths may be systematically biased.
+
+This analysis points to the importance of careful instrumental
+characterization, especially for those instruments which are used for
+large-scale surveys with largely automatic data analysis systems and
+stringent precision goals.
 
 \acknowledgments
@@ -893,44 +1033,5 @@
 \end{document}
 
-Notes for paper re-work:
-
-* Paper focus is now only on the diffusion variations
-  * strip out the discussion of other systematic effects
-  * strip down the PS1 introduction discussion
-
-* tentative title:
-  Evidence for Small-Scale Charge-Diffusion Variations in Pan-STARRS CCDs
-
-* outline
-
- 1. introduction
-    * thick CCDs
-    * tree rings == transverse field effects (see Plazas et al)
-    * we see something else
-
- 4 model : diffusion variations due to E|| field variations
-
- 5 discussion (how to treat in calibration / analysis)
-
- 6 conclusions
-
-some possible refs to tree rings / charge diff:
-
-* http://adsabs.harvard.edu/abs/2016SPIE.9904E..2CW (Woods et al 2016; TESS)
-* https://arxiv.org/pdf/1605.01001.pdf : plazas et al 
-* http://ieeexplore.ieee.org/document/1225293/?part=1 Altmannshofer et al 2003 (about thick Si)
-
-* plazas et al 2014 outline
-
-  1. intro: thick CCDs, transverse electric fields
-  2. DES / DECam
-
-  2.1 flat-field tree rings (discussion of flat-field tree rings
-  starting from the premise that they know the answer).
-  
-  3 impact on astrometry and photometry
-
-  4 improving calibrations given tree rings
-
-  5 summary and conclusions
-
+%% Some refs to be added as appropriate:
+% Bernstein DEC astrometry : arxiv 1703.01679
+% Baumer et al arxiv 1706.07400 (Flat-fielding)
