# opal AT lists.psi.ch

**Subject:**
The OPAL Discussion Forum

## List archive

**From**: christof kraus <christof.j.kraus AT gmail.com>**To**: Nicole Neveu <nneveu AT hawk.iit.edu>**Cc**: opal <opal AT lists.psi.ch>**Subject**: Re: [Opal] Correlation term**Date**: Tue, 1 Nov 2016 10:46:12 +0100

Hi Nicole,

the correlation is divided by xrms * prms.On Mon, Oct 31, 2016 at 8:50 PM, Nicole Neveu <nneveu AT hawk.iit.edu> wrote:

Hi OPAL'ers,What is the equation for xpx (column 21) in the stat file?When I calculate xrms and pxrms, (using the h5 file and math definitions), the numbers match exactly.I thought the calculation would be similar for the correlation term. Something like:correlation = ( (np.sum(x*px)/npt) - (np.sum(x)/npt)*(np.sum(px)/npt) )However, when I do this calculation, it does not match the xpx value listed in the stat file.Do I need to divide by xrms? What part of the equation am I missing?Thanks!Nicole

**Re: [Opal] Correlation term**,*christof kraus, 11/01/2016***Re: [Opal] Correlation term**,*Nicole Neveu, 11/01/2016*

- <Possible follow-up(s)>
**Re: [Opal] Correlation term**,*Adelmann Andreas (PSI), 11/01/2016***Re: [Opal] Correlation term**,*Nicole Neveu, 11/01/2016*

Archive powered by MHonArc 2.6.19.