How does one actually compute a correlation function?

Click For Summary

Discussion Overview

The discussion revolves around the computation of the correlation function and power spectrum in the context of weak gravitational lensing, specifically focusing on the aperture mass for a singular isothermal sphere. Participants seek guidance on how to carry out these calculations, expressing frustration over circular definitions and lack of clarity in existing resources.

Discussion Character

  • Exploratory
  • Technical explanation
  • Debate/contested
  • Mathematical reasoning

Main Points Raised

  • One participant describes the two-point correlation function for a homogeneous and isotropic random field and its relationship to the power spectrum through Fourier transforms.
  • Another participant emphasizes the need to clarify the type of data available (e.g., point-like objects or photon densities) to determine the best approach for computing the correlation function or power spectrum.
  • There is a discussion about the definition and interpretation of the power spectrum and correlation function, noting that they can be defined in various ways.
  • A participant mentions that the power spectrum is the average variance of the correlation as a function of distance and describes the need for averaging over a range of wavelengths in a discrete two-dimensional field.
  • One participant expresses a desire to compute the power spectrum as it is necessary for calculating the variance of the aperture mass, while also considering the feasibility of computing either the correlation function or power spectrum first.
  • Clarification questions arise regarding whether the analysis is based on measurements or theoretical considerations, indicating potential misunderstandings in the initial approach.

Areas of Agreement / Disagreement

Participants do not reach a consensus on the best approach to compute the correlation function or power spectrum, with multiple competing views on definitions and methodologies remaining unresolved.

Contextual Notes

Participants express uncertainty about the definitions of the correlation function and power spectrum, and how to apply them to their specific data. There are unresolved questions regarding the nature of the data and the intended analysis (theoretical vs. measurement-based).

BOAS
Messages
546
Reaction score
19
I have been reading about weak gravitational lensing and I am trying to calculate the dispersion ##\langle M_{ap}^2\rangle## of the aperture mass for a singular isothermal sphere acting as a lens for distant objects.

I need some guidance on how to actually carry out the calculation of the power spectrum. It is defined as the Fourier transform of the two point correlation function, but how does one actually compute that function? All the information I have found just defines each quantity in terms of the other, which is not very helpful to me. I feel like I'm going around in circles.

To provide some context:

In The book "Gravitational Lensing: Strong, Weak and Micro", Peter Schneider includes a discussion on the 2-point correlation function for a homogeneous and isotropic random field ##g(\vec x)##. The main points being that (in 2d):

##\langle g(\vec x) g^*(\vec y) \rangle = C_{gg}(|\vec x - \vec y|)## is the two point correlation function.

By going to Fourier space we can show that ##\langle g(\vec k) g^*(\vec k') \rangle = (2\pi)^2 \delta(\vec k - \vec k') \int \mathrm{d^2}y \quad e^{i \vec y . \vec k} C_{gg}(|\vec y|)##

The power spectrum is then defined by the Fourier transform of the two point correlation function.

##P_g(|\vec k|) = \int \mathrm{d^2}y e^{i \vec y . \vec k} C_{gg}(|\vec y|)##

The aperture mass is defined as being ##M_{ap} (\vec \theta) = \int d^2 \theta' \kappa(\vec \theta')U(|\vec \theta - \vec \theta'|)##, where ##\kappa## is the convergence and ##U## a suitable filter function.

By following a similar approach as for the random field, expressing the two point correlation function of the convergence in Fourier space, I have been able to arrive at the desired expression for ##\langle M_{ap}^2\rangle##.

##\langle M_{ap}^2\rangle = \frac{1}{(2\pi)^2}\int d^2 \vec l \mathrm{P_{\kappa}}(\vec l) |U(\vec l)|^2 ##

But I am no closer to actually being able to compute what the power spectrum is.

Thank you if you're still reading!
 
Space news on Phys.org
BOAS said:
I have been reading about weak gravitational lensing and I am trying to calculate the dispersion ##\langle M_{ap}^2\rangle## of the aperture mass for a singular isothermal sphere acting as a lens for distant objects.

I need some guidance on how to actually carry out the calculation of the power spectrum. It is defined as the Fourier transform of the two point correlation function, but how does one actually compute that function? All the information I have found just defines each quantity in terms of the other, which is not very helpful to me. I feel like I'm going around in circles.

To provide some context:

In The book "Gravitational Lensing: Strong, Weak and Micro", Peter Schneider includes a discussion on the 2-point correlation function for a homogeneous and isotropic random field ##g(\vec x)##. The main points being that (in 2d):

##\langle g(\vec x) g^*(\vec y) \rangle = C_{gg}(|\vec x - \vec y|)## is the two point correlation function.

By going to Fourier space we can show that ##\langle g(\vec k) g^*(\vec k') \rangle = (2\pi)^2 \delta(\vec k - \vec k') \int \mathrm{d^2}y \quad e^{i \vec y . \vec k} C_{gg}(|\vec y|)##

The power spectrum is then defined by the Fourier transform of the two point correlation function.

##P_g(|\vec k|) = \int \mathrm{d^2}y e^{i \vec y . \vec k} C_{gg}(|\vec y|)##

The aperture mass is defined as being ##M_{ap} (\vec \theta) = \int d^2 \theta' \kappa(\vec \theta')U(|\vec \theta - \vec \theta'|)##, where ##\kappa## is the convergence and ##U## a suitable filter function.

By following a similar approach as for the random field, expressing the two point correlation function of the convergence in Fourier space, I have been able to arrive at the desired expression for ##\langle M_{ap}^2\rangle##.

##\langle M_{ap}^2\rangle = \frac{1}{(2\pi)^2}\int d^2 \vec l \mathrm{P_{\kappa}}(\vec l) |U(\vec l)|^2 ##

But I am no closer to actually being able to compute what the power spectrum is.

Thank you if you're still reading!
The two-point correlation function of a field is the difference in the value of the field between any two locations on the field.

The power spectrum is the average variance of this correlation as a function of distance: P(x) is the variance of the difference in field values averaged over all pairs of points separated by that distance.

The discussion about the Fourier transform describes an optimized method of calculating this variance as a function of distance: in Fourier space, the power spectrum is simply an average over the squares of the magnitudes of the Fourier components of a given wavelength.

The final piece is the window function: because the above operations are performed on a discrete two-dimensional field, you need to average the components in a range of wavelengths. In a graphical representation, the Fourier components would exist on a plane, and the averages would be rings through the plane. For the power spectrum to be representative, there shouldn't be any gaps in the rings. That requires averaging over the square magnitudes of the Fourier components in a narrow range of wavelengths for each component.
 
Last edited:
BOAS said:
I need some guidance on how to actually carry out the calculation of the power spectrum. It is defined as the Fourier transform of the two point correlation function, but how does one actually compute that function? All the information I have found just defines each quantity in terms of the other, which is not very helpful to me. I feel like I'm going around in circles.
You are apparently starting with a misunderstanding, which may be why you are going in circles. The power spectrum (PS) can be defined in various ways, and so can the correlation function (CF). But regardless of the definition, they are Fourier transforms of each other.

The questions for you are (a) what are your data and (b) what do you want to compute? Your title asks about the CF, yet your last question in the OP asks about the PS. Focus on your data: What kinds of measurements do you have? Locations of discrete point-like objects? photon densities as a function of position on the sky? something else? That will suggest the best way to compute either the CF or the PS; the other can then be computed from Fourier, if you want to.
 
JMz said:
You are apparently starting with a misunderstanding, which may be why you are going in circles. The power spectrum (PS) can be defined in various ways, and so can the correlation function (CF). But regardless of the definition, they are Fourier transforms of each other.

The questions for you are (a) what are your data and (b) what do you want to compute? Your title asks about the CF, yet your last question in the OP asks about the PS. Focus on your data: What kinds of measurements do you have? Locations of discrete point-like objects? photon densities as a function of position on the sky? something else? That will suggest the best way to compute either the CF or the PS; the other can then be computed from Fourier, if you want to.

Thank you for your reply.

I have some data that is essentially a point sampled shear field. Ideally I would like to compute the power spectrum since that is the quantity I need to calculate the variance of the aperture mass. But since they are FT pairs, I suppose I would like to calculate whichever is easiest and then Fourier transform as necessary.
 
BOAS said:
Thank you for your reply.

I have some data that is essentially a point sampled shear field. Ideally I would like to compute the power spectrum since that is the quantity I need to calculate the variance of the aperture mass. But since they are FT pairs, I suppose I would like to calculate whichever is easiest and then Fourier transform as necessary.
Sorry, a clarification question, as I may have missed something: Are you trying to infer something from measurements or is this a theoretical analysis? I had thought the former, but your wording suggests the latter. Are you trying to analyze the effect of a mass density distribution (assumed for this analysis, not measured)?
 
JMz said:
Sorry, a clarification question, as I may have missed something: Are you trying to infer something from measurements or is this a theoretical analysis? I had thought the former, but your wording suggests the latter. Are you trying to analyze the effect of a mass density distribution (assumed for this analysis, not measured)?

Sorry, I'm confusing things:

First and foremost, I am trying to analyse the case where I have assumed a mass density distribution. I am lead to believe that this can be done analytically for the SIS profile. No data related to this step.

In addition to this, I have some simulated data that I would like to analyse through the use of some practical estimator for the aperture mass variance.
 
BOAS said:
Sorry, I'm confusing things:

First and foremost, I am trying to analyse the case where I have assumed a mass density distribution. I am lead to believe that this can be done analytically for the SIS profile. No data related to this step.

In addition to this, I have some simulated data that I would like to analyse through the use of some practical estimator for the aperture mass variance.
OK, that makes sense. Let's start with the analytical one: You have a certain density function D, which you know well. You can compute its autocorrelation ACF[D] analytically I think (but I don't know or recall the functional form here). If not, you can certainly approximate it numerically and compute numerically. If the latter, ACF[D] = F-1[|Q|2], where F[.] is the 3-dimensional Fourier transform and Q = F[D]. Note that |Q|2 is, in fact, the PS of D.

Does this make sense so far, or have I missed something about your problem?
 
JMz said:
OK, that makes sense. Let's start with the analytical one: You have a certain density function D, which you know well. You can compute its autocorrelation ACF[D] analytically I think (but I don't know or recall the functional form here). If not, you can certainly approximate it numerically and compute numerically. If the latter, ACF[D] = F-1[|Q|2], where F[.] is the 3-dimensional Fourier transform and Q = F[D]. Note that |Q|2 is, in fact, the PS of D.

Does this make sense so far, or have I missed something about your problem?

I believe that makes sense. So I don't actually need to compute the auto correlation function in order to find the PS of D?

i.e I want to compute the FT of D, and then take it's mod-squared.

Once I have done that, it is then relatively straightforward to compute it's ACF. Do you have any resource recommendations on this subject? It's evidently an important concept I need to understand.
 
BOAS said:
I want to compute the FT of D, and then take it's mod-squared.
Exactly. BTW, what is the functional form of D?

I suggest starting with WP or any text on general signal processing -- though both may focus on one-dim. distributions, especially time series. But one of the useful aspects of the ACF is that it doesn't depend on the direction of "time", which is what makes it equally suitable for multidimensional distributions. You should be able to find 2-dim. discussions in image processing. I don't recall any resources for 3-dim., though.
 
  • #10
JMz said:
Exactly. BTW, what is the functional form of D?

I suggest starting with WP or any text on general signal processing -- though both may focus on one-dim. distributions, especially time series. But one of the useful aspects of the ACF is that it doesn't depend on the direction of "time", which is what makes it equally suitable for multidimensional distributions. You should be able to find 2-dim. discussions in image processing. I don't recall any resources for 3-dim., though.

My density distribution is that of a singular isothermal sphere, so ##\rho(r) = \frac{\sigma^2}{2\pi G r^2}##.

I have calculated the surface mass density (which is what I will be using), ##\kappa(\theta) = \frac{\theta_E}{2 \theta}##, where ##\theta_E## is the Einstein radius for an SIS.

Thank you very much for your help!
 
  • #11
OK. FYI, the singularity will give you spectral components at arbitrarily high frequencies, which could cause you some problems.
 

Similar threads

  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 5 ·
Replies
5
Views
3K
  • · Replies 16 ·
Replies
16
Views
3K
Replies
4
Views
2K
  • · Replies 20 ·
Replies
20
Views
3K
  • · Replies 2 ·
Replies
2
Views
2K
Replies
1
Views
3K
  • · Replies 59 ·
2
Replies
59
Views
12K
Replies
3
Views
2K
  • · Replies 6 ·
Replies
6
Views
2K