I searched here on Math.SE and haven't found anything that was exactly what I was looking for, so I'm posting it here. If there is anything, pardon my ignorance. I thought it was my first post here, but it is not, sorry for the missunderstanding.
I was trying to generate vectors acording to a given density/distribution. The idea is an extension of the following:
If X is a random variable $X$, and $F(x) = P(X\leq x) $ is it acumulated probability density function, and $F^{-1}$ is it pseudo-inverse, I can use the pseudo inverse to generate points that distributes acording to $F(x)$. What I need to do is to use an PRNG to generate $y_n\in (0,1]$ uniform, $x_n = F^{-1}(y_n)$ is going to have the same distribution as $X$
As to the N-Dimensional analog of this idea, I thought it would be something like this:
let $X$ be a n-dimensional real random vector, and $x=(x_1,x_2,...,x_n)$, its acumulated distribution function is given by $F(x)=P(X\leq x)$. Just for practical reasons, I'll restrict myself to continuous random vectors, so $F(x)=\int_{-\infty}^{x_1}\int_{-\infty}^{x_2} ... \int_{-\infty}^{x_n} dx_1' dx_2' ... dx_n'\ f(x')$
The i-th marginal distribution is given by $g_i(x) = \lim_{h\downarrow 0}\frac{F(x+h e_i)-F(x)}{h}$ the right derivative (which i'm aware that it may not always exists). In the continuous case it would give me
$M_i(x)=\int_{-\infty}^{x_1}... \int_{-\infty}^{x_{i-1}}\int_{-\infty}^{x_{i+1}} ... \int_{-\infty}^{x_n} dx_1' ... dx_n'\ f(\tilde x)$
with $\tilde x=(x_1',x_2',...,x_{i-1}',x_i,x_{i+1}',...,x_n)$ the integration variable with the $i$-th component subtituted by $x_i$. This gives us a map $M:\mathbb{R}^n \rightarrow [0,1]^n$ by putting $M(x)=(M_1(x),M_2(x),...,M_n(x))$
So, here is my idea. If i could have a pseudo inverse $M^{-1}$ for $M$, and use the same algorithm as I used for the 1 dimensional case, it would be awesome, but I'm don't how to prove it would work.
I would like to make the following:
1) Generate a $n$-dimensional vector sequence $y^i=(y_1^i,y_2^i,...,y_n^i)$ with an uniform PRNG
2) Calculate $x^i$ through $x^i = M^{-1}(y^i)$, if $y^i$ don't have pseudo-inverse, discard it.
My interest is not only only to generate random numbers, but also regular grids. If $y^i$ is a regular $n$-dimensional grid in $[0,1]^n$, either cubic, tetraedrical, etc, I would like to use $M^{-1}$ to give me a 'decently' regular (I know it's vague, but I don't know how to put it better) grid with the average point density beeing similar to $f(x)$
I don't know if this is a valid method, nor I know how to prove it, so, I would like to ask if someone have any similar problems in the past and/or could help me with it.
Thanks in Advance