I apologies if this is off topic for this site, but I am trying to figure out (and not having much luck) how to get an empirical distribution function of a sum of two random variables given two samples of equal length (say 256) from their respective distributions. I understand that the distribution is given by a convolutions of their distributions, which can be computed as a product of their characteristic functions.
So, to test, I take two time series of length 256 each from standard normal distribution, compute their Fourier transforms using Fourier transform tool from Data Analysis toolpack in Excel, multiply the results using complex multiplication function IMPRODUCT, and then apply inverse Fourier transform. However, the resulting time series does not have a variance of 2 (it is more like ~240) which should be the case for the sum of two standard normal RVs. It might be some normalization issue, but I am not sure how and why it comes up.
Also, I am not sure if I am supposed to be doing zero-padding of the two original time series (say +256 zeros for each). I have read that if one wants to perform regular convolutions (instead of a "circular" one, whatever that is), one have to do this padding with zeros. This padding, however, seems to make the final result also double the length, but I would like to get the estimated distribution of the sum of the same length as the inputs, so not sure what needs to be done here.
Add 1
For example, given two identical samples of size 9 from uniform distribution
$(0,0.125,0.250,0.375,0.50,0.625,0.750,0.875,1.0)$,
their convolution would produce 81 pairs with values
$(0,0.125,0.250,0.375,0.50,0.625,0.750,0.875,1.0,1.125,1.250,1.375,1.50,1.625,1.750,1.875,2.0)$
with respective counts
$(1,2,3,4,5,6,7,8,9,8,7,6,5,4,3,2,1)$
which gives the triangular distribution. What I am looking to do, is to produce this without doing these convolution sums, but by using Fourier transform.
Add 2
This is what Wikipedia says on the calculation of empirical characteristic function.
If $X_{i},i=1,2,\ldots ,n$ are i.i.d. observations, then the empirical characteristic function $\varphi _{n}(t)$ is defined as
$$\varphi _{n}(t)={\frac {1}{n}}\sum _{j=1}^{n}\exp(itX_{j}).\tag{1}$$
And this is what it says about application of the characteristic function to sums of random variables.
In particular, $\varphi _{X+Y}(t) = \varphi _{X}(t) \varphi _{X}(t)$, i.e. the characteristic function of the sum of RVs is the product of their respective characteristic functions.
So, from the above two, it seems that one can construct characteristic functions directly from the samples and multiply them together to get a characteristic function of the sums. The only bit left is to get back into the "sample space". That was my understanding.
Add 3
A discreet Fourier transform (DFT) of a sequence is
$$\hat f_k=\sum _{j=0}^{n-1} f_j \exp(i2\pi k j/n).\tag{2}$$
So, if we take the probability of observing each value in the sample on $n$ observations the same, ie $f_j = 1/n$, then the difference between empirical characteristic function and DFT is that $X_j$ in the former is replaced with $2\pi j /n$ in the latter, so the characteristic function looks like some kind of "non-uniform" DFT. And this is where I seem to get stuck, I don't know how to compute this non-uniform DFT. Also, the discreet $t$ points of the transform need to be the same for both samples as I would need to take the product of the two empirical characteristic functions at those points.