I need a mapping from the unit Hypercube [0,1]^n to a given simplex

In summary, the conversation discusses the need for a mapping from a unit hypercube ##C^n:= \left[ 0,1\right] ^n## to a given simplex ##S^n:=\left\{ \vec{x} \in\mathbb{R}^n |0\leq x_1\leq 1, 0\leq x_{k}\leq x_{k-1}\text{ for } k=2,3,\ldots , n\right\}##. The moderator asks for any known mappings, and the conversation explores different possibilities, with the final solution being a mapping using the Hadamard Left Fractional Integral Operator.
  • #1
benorin
Homework Helper
Insights Author
1,435
186
I need a mapping from the unit Hypercube ##C^n:= \left[ 0,1\right] ^n## to a given simplex, namely ##S^n:=\left\{ \vec{x} \in\mathbb{R}^n |0\leq x_1\leq 1, 0\leq x_{k}\leq x_{k-1}\text{ for } k=2,3,\ldots , n\right\}##. Anybody know one? I have other requirements I need satisfy, so if you know more than one such mapping (transformation equations) please do post them.

Moderator: I’m not 100% certain that this is the appropriate sub-forum in which to post this question, so please feel free to move it. Thanks!
 
Physics news on Phys.org
  • #2
You should probably indicate any requirements like continuity, onto, 1-1, etc.
Without those requirements, one mapping that comes to mind is ##f(x_1,x_2,...,x_n) = [x_1/2, x_2/4+1/2, x_3/8+3/4, ... , x_n/(2^n)+(2^{n-1}-1)/2^{n-1}]##
It is continuous but not onto or 1-1. I suspect that this is not what you want.
 
  • #3
I need it for change of variables in an integral, so continuous, differentiable, non-zero Jacobian. Also I require that the integrand times the Jacobian is expressible as a function of one variable,

$$\frac{dx_n dx_{n-1}\dots dx_1}{1-\prod_{k=1}^{n}x_k}\cdot \left|\frac{\partial (x_1,x_2,\ldots , x_n)}{\partial (u_1, u_2, \ldots,u_n)}\right|:=g(u_n)$$

Laundry list I know, but this should allow me to represent the integral over the hypercube as an iterated integral so I can generalize the integral to complex values of n. I hoping to get some ideas and maybe tweak them to work. This is just a practice problem. I may equivalently solve the fractional-integral equation

$$I_{\alpha}g(z)=\zeta (z)$$

where ##\zeta (\cdot )## is the Riemann Zeta function--which may well be easier but I wanted to try it this way to make use of my earlier work.
 
Last edited:
  • #4
CORRECTION: THIS POST AND POST #6 ARE WRONG. I THINK THAT POST #7 IS CORRECT.
How about this:
##f(x_1,x_2, ... , x_n) = [y_1, y_2, ... , y_n],##
where
##y_1=x_1;##
## y_2=y_1+x_2*y_1+(1-x_2);##
## y_3=y_2+x_3*y_2+(1-x_3);##
## y_4=y_3+x_4*y_3+(1-x_4);##
## ... ##
##y_n=y_{n-1}+x_n*y_{n-1}+(1-x_n);##

The idea here is that each ##y_i## has the value between ##y_{i-1}## and 1, which is the weighted average of those two points with weights ##x_i## and ##(1-x_i)##.
 
Last edited:
  • Like
Likes benorin
  • #5
Is * multiplication? Or some other operator? Thanks for your help!
 
  • #6
benorin said:
Is * multiplication? Or some other operator? Thanks for your help!
CORRECTION: THIS POST IS WRONG. I THINK THAT POST #7 IS CORRECT.
Yes, it is multiplication. I think that I made an error on the equations. A corrected version would be:
##f(x_1,x_2,...,x_n)=[y_1,y_2,...,y_n],##
where
## y_1=x_1;##
##y_2=(1-x_2)y_1 +x_2;##
##y_3=(1-x_3)y_2 +x_3;##
##y_4=(1-x_4)y_3 +x_4;##
...
##y_n=(1-x_n)y_{n-1} +x_n;##

Sorry for the confusion.
 
Last edited:
  • #7
I misread your definition of ##S^n## and made ##y_i \ge y_{i-1}## where it should have been ##y_i \le y_{i-1}##.

To get that corrected:
##f(x_1,x_2,...,x_n)=[y_1,y_2,...,y_n],##
where
## y_1=x_1;##
##y_2=x_2y_1;##
##y_3=x_3y_2;##
##y_4=x_4y_3;##
...
##y_n=x_ny_{n-1};##

Sorry again for the confusion.
 
Last edited:
  • Like
Likes benorin
  • #8
@FactChecker It's really nice of you to, in the process of self-correcting a slightly incorrect explanation, go loud on yourself having earlier slightly erred; tip of the hat to you on that Sir.
 
  • Like
Likes benorin and FactChecker
  • #9
sysprog said:
@FactChecker It's really nice of you to, in the process of self-correcting a slightly incorrect explanation, go loud on yourself having earlier slightly erred; tip of the hat to you on that Sir.
Thanks. I just wish I could be more accurate the first time. It's a problem I have even on subjects that I should be much sharper at.
 
  • Like
Likes benorin and sysprog
  • #10
Moi aussi -- I think that I'm ok at fixing bugs -- and I think that it would better if I didn't write bug-inclusive code in the first place, but whenever I wake out of laziness, I got to code, it's just a thing.
 
  • Love
Likes benorin
  • #11
FactChecker said:
I misread your definition of ##S^n## and made ##y_i \ge y_{i-1}## where it should have been ##y_i \le y_{i-1}##.

To get that corrected:
##f(x_1,x_2,...,x_n)=[y_1,y_2,...,y_n],##
where
## y_1=x_1;##
##y_2=x_2y_1;##
##y_3=x_3y_2;##
##y_4=x_4y_3;##
...
##y_n=x_ny_{n-1};##

Sorry again for the confusion.

Thanks, that’s much easier to work with.
 
  • Like
Likes sysprog
  • #12
I get that ##y_1=x_1## and for ##y_{k-1}\neq 0## we have ##x_k=\frac{y_k}{y_{k-1}}## for ##k=2,3,\ldots , n##. So we have that

$$\frac{\partial x_i}{\partial y_j}=
\begin{cases} 1, & i=j=1 \\ \frac{1}{y_{i-1}}, & i=j\neq 1 \\ -\frac{y_i}{y_{i-1}^2}, & i=j+1 \\ 0, & \text{otherwise} \end{cases}$$

So the Jacobian determinant is just the product along the diagonal, correct? So it's ##J=\frac{1}{y_1 y_2\cdots y_{n-1}}##?
 
  • #13
So you are looking at the inverse function of ##f##, right? Each ##y_i## is a function of all ##y_j, j\lt i##, so I think that makes it more complicated. Since you are talking about the inverse of the function ##f##, I don't think that you can consider the ##y_i##s as being independent variables. I think that this is getting beyond my comfort level and I will leave it to others to help you further.
 
  • Like
Likes benorin
  • #14
Now I see that I made a mistake and the integral equation that I could alternatively solve should have been

$$\lim_{x\to \alpha} I_{\alpha}f(x)=\zeta (\alpha )$$

Whereas I had not included the limit and also had ##\zeta (z)## on the right hand side back in post #3.
 
Last edited:
  • #15
So I solved the fractional-Integral equation but with the Hadamard Left Fractional Integral Operator instead of the R-L fractional integral operator, and it turns out that post #12 has the Jacobian determinant correct. I arrived at this conclusion in a round about way. Beginning with the well known integral

$$\Gamma (z) \zeta (z)=\int_{u=0}^{\infty} \frac{u^{z-1}}{e^u-1}\, du, \, \, \Re\left[ z\right] >1$$

Make the substitution ##u= \log \frac{x}{t}\Rightarrow du=-\frac{dt}{t}## and use the negative from du to flip the bounds of integration to get

$$\zeta (z)=\frac{1}{\Gamma (z)}\int_{t=0}^{x} \log ^{z-1}\left( \frac{x}{t}\right) \frac{1}{\frac{x}{t}-1}\, \frac{dt}{t}, \, \, \Re\left[ z\right] >1$$

which, after setting ##x=1## in the factor of the integrand following the log factor, is exactly the Hadamard fractional integral of ##\frac{t}{1-t}## of order z and, get this, the Hadamard FI operator interpolates the n-fold integral

$$\int_{0}^{x_0}\int_{0}^{x_1}\cdots\int_{0}^{x_{n-1}}f(x_n)\frac{dx_n\ldots dx_1}{x_n \cdots x_1} = \frac{1}{\Gamma (n) }\int_0^{x_0}\log ^{n-1}\left( \frac{x_0}{t}\right) f(t) \frac{dt}{t}$$

Hence the integral we were looking at in this thread should have been

$$\int_{0}^{y_0}\int_{0}^{y_1}\cdots\int_{0}^{y_{n-1}}\frac{y_n}{1-y_n}\frac{dy_n\ldots dy_1}{y_{n}\cdots y_1} $$

so the Jacobian determinant of post #12 was correct after multiplying by a factor of ##\tfrac{y_n}{y_n}##.
 
Last edited:
  • Like
Likes sysprog
  • #16
One way to conceive of such a mapping is: First map one vertex v of the cube [0,1]n to some vertex f(v) of the simplex ∆n. Then extend this to the n edges of [0,1]n emanating from v ... to the n edges of ∆n emanating from f(p) — just map each of them linearly.

Now consider the far vertices of those n edges of the cube — call them v1, ..., vn. Now each line from the original vertex v that heads into the cube will pass through a unique convex combination of the vj's. (That is, a linear combination of the vj's whose coefficients are non-negative real numbers whose sum equals 1.) For each such convex combination (call it w), send the line in the cube from v through w until it exits the cube to the corresponding line from f(v) through the corresponding convex combination of the f(vj)'s until it exits the simplex. Again, just map the first interval linearly onto the second for each convex combination.

It shouldn't be hard to derive a formula from this. But don't expect it to be a diffeomorphism (differentiable homeomorphism with differentiable inverse) from the entire closed cube to the entire closed simplex, because that will not exist.
 
  • Like
Likes benorin and sysprog
  • #17
Very interesting problem. I'm having trouble piecing together the solution suggested but would like to.

Meanwhile I can share a draft of an article I'm writing on precisely this problem here.
 
  • Like
Likes benorin
  • #18
If you want to include the interior, you may use the idea of a space-filling curve. There may also be conditions so that the map is a simplicial map.
 
  • Like
Likes benorin

1. How can I map a unit Hypercube to a given simplex?

To map a unit Hypercube [0,1]^n to a given simplex, you can use a technique called barycentric coordinates. This involves finding the barycentric coordinates of each point in the Hypercube and then using those coordinates to map the points onto the simplex. This mapping preserves the relative distances and angles between points in the Hypercube.

2. What is a unit Hypercube?

A unit Hypercube is a geometric shape that has n dimensions and all of its sides are equal in length. In n-dimensional space, it can be represented as a cube with sides of length 1. It is often used in mathematical and scientific calculations as a simplified way to represent complex shapes and spaces.

3. What is a simplex?

A simplex is a geometric shape that has n+1 vertices, where n is the number of dimensions it exists in. In two dimensions, a simplex is a triangle, in three dimensions it is a tetrahedron, and so on. It is a fundamental shape in geometry and is often used in mathematical models and simulations.

4. Why is mapping from a unit Hypercube to a simplex useful?

Mapping from a unit Hypercube to a simplex is useful because it allows for a simplified representation of complex shapes and spaces. It also preserves the relative distances and angles between points, making it useful in mathematical and scientific calculations. Additionally, it can be used to transform data from one coordinate system to another, which can be helpful in data analysis and visualization.

5. Are there any limitations to mapping from a unit Hypercube to a simplex?

Yes, there are some limitations to mapping from a unit Hypercube to a simplex. One limitation is that the dimensions of the Hypercube and the simplex must be the same, otherwise the mapping will not be possible. Additionally, the mapping may not be accurate for complex shapes or in cases where the Hypercube and simplex have significantly different shapes. It is important to carefully consider the specific application and limitations before using this mapping technique.

Similar threads

Replies
2
Views
120
Replies
4
Views
353
Replies
4
Views
1K
Replies
32
Views
1K
Replies
1
Views
698
Replies
2
Views
1K
Replies
1
Views
2K
  • Topology and Analysis
2
Replies
44
Views
5K
Replies
0
Views
332
  • Sticky
  • Topology and Analysis
Replies
9
Views
5K
Back
Top