How to represent reflection of a particle inside a standard simplex?












1












$begingroup$


I am trying to simulate the trajectory of an evolutionary system represented by a vector of probabilities $vec p = [p_1, p_2,...] $. Values are restricted between 0 and 1. As a result we can think the system is contained in a standard simplex.



So far, so good. However, I would like to have the system to reflect every time it reach one of the borders of the simplex, i.e. $p_i =0$ for any $i$. By reflection I mean something similar to physical reflection of a light beam: to leave the border in the same angle and the same distance as the source, but in a different direction.



I found a somewhat simple rule in wikipedia:



${displaystyle operatorname {Ref} _{a}(v)=v-2{frac {vcdot a}{acdot a}}a,}$



However, it seems it requires the plane $a$ passing by origin, plus its describe the behavior of vector instead of a point. I searched for other formulas, but I must admit, got a little lost in the diversity of solutions.



Assuming there I have all positions of the system was up to the point it reaches the border, is there a more direct formula I can use?










share|cite|improve this question









$endgroup$












  • $begingroup$
    To clarify, you want the vector of reflection ?
    $endgroup$
    – T. Fo
    Dec 17 '18 at 20:45










  • $begingroup$
    Also, the values are restricted between $0$ and $1$, and their sum is $1$, or their sum is $le 1$? Just trying to work out exactly what simplex you're referring to.
    $endgroup$
    – jgon
    Dec 17 '18 at 20:47










  • $begingroup$
    I want to know the position the system (particle) will be after it reflects. However, if it is easier I can work with just the vector of reflection. And jgon is correct. It is restricted to 0 and 1 and their sum to 1.
    $endgroup$
    – JMenezes
    Dec 18 '18 at 15:46
















1












$begingroup$


I am trying to simulate the trajectory of an evolutionary system represented by a vector of probabilities $vec p = [p_1, p_2,...] $. Values are restricted between 0 and 1. As a result we can think the system is contained in a standard simplex.



So far, so good. However, I would like to have the system to reflect every time it reach one of the borders of the simplex, i.e. $p_i =0$ for any $i$. By reflection I mean something similar to physical reflection of a light beam: to leave the border in the same angle and the same distance as the source, but in a different direction.



I found a somewhat simple rule in wikipedia:



${displaystyle operatorname {Ref} _{a}(v)=v-2{frac {vcdot a}{acdot a}}a,}$



However, it seems it requires the plane $a$ passing by origin, plus its describe the behavior of vector instead of a point. I searched for other formulas, but I must admit, got a little lost in the diversity of solutions.



Assuming there I have all positions of the system was up to the point it reaches the border, is there a more direct formula I can use?










share|cite|improve this question









$endgroup$












  • $begingroup$
    To clarify, you want the vector of reflection ?
    $endgroup$
    – T. Fo
    Dec 17 '18 at 20:45










  • $begingroup$
    Also, the values are restricted between $0$ and $1$, and their sum is $1$, or their sum is $le 1$? Just trying to work out exactly what simplex you're referring to.
    $endgroup$
    – jgon
    Dec 17 '18 at 20:47










  • $begingroup$
    I want to know the position the system (particle) will be after it reflects. However, if it is easier I can work with just the vector of reflection. And jgon is correct. It is restricted to 0 and 1 and their sum to 1.
    $endgroup$
    – JMenezes
    Dec 18 '18 at 15:46














1












1








1





$begingroup$


I am trying to simulate the trajectory of an evolutionary system represented by a vector of probabilities $vec p = [p_1, p_2,...] $. Values are restricted between 0 and 1. As a result we can think the system is contained in a standard simplex.



So far, so good. However, I would like to have the system to reflect every time it reach one of the borders of the simplex, i.e. $p_i =0$ for any $i$. By reflection I mean something similar to physical reflection of a light beam: to leave the border in the same angle and the same distance as the source, but in a different direction.



I found a somewhat simple rule in wikipedia:



${displaystyle operatorname {Ref} _{a}(v)=v-2{frac {vcdot a}{acdot a}}a,}$



However, it seems it requires the plane $a$ passing by origin, plus its describe the behavior of vector instead of a point. I searched for other formulas, but I must admit, got a little lost in the diversity of solutions.



Assuming there I have all positions of the system was up to the point it reaches the border, is there a more direct formula I can use?










share|cite|improve this question









$endgroup$




I am trying to simulate the trajectory of an evolutionary system represented by a vector of probabilities $vec p = [p_1, p_2,...] $. Values are restricted between 0 and 1. As a result we can think the system is contained in a standard simplex.



So far, so good. However, I would like to have the system to reflect every time it reach one of the borders of the simplex, i.e. $p_i =0$ for any $i$. By reflection I mean something similar to physical reflection of a light beam: to leave the border in the same angle and the same distance as the source, but in a different direction.



I found a somewhat simple rule in wikipedia:



${displaystyle operatorname {Ref} _{a}(v)=v-2{frac {vcdot a}{acdot a}}a,}$



However, it seems it requires the plane $a$ passing by origin, plus its describe the behavior of vector instead of a point. I searched for other formulas, but I must admit, got a little lost in the diversity of solutions.



Assuming there I have all positions of the system was up to the point it reaches the border, is there a more direct formula I can use?







linear-algebra geometry simplex reflection






share|cite|improve this question













share|cite|improve this question











share|cite|improve this question




share|cite|improve this question










asked Dec 17 '18 at 20:39









JMenezesJMenezes

1336




1336












  • $begingroup$
    To clarify, you want the vector of reflection ?
    $endgroup$
    – T. Fo
    Dec 17 '18 at 20:45










  • $begingroup$
    Also, the values are restricted between $0$ and $1$, and their sum is $1$, or their sum is $le 1$? Just trying to work out exactly what simplex you're referring to.
    $endgroup$
    – jgon
    Dec 17 '18 at 20:47










  • $begingroup$
    I want to know the position the system (particle) will be after it reflects. However, if it is easier I can work with just the vector of reflection. And jgon is correct. It is restricted to 0 and 1 and their sum to 1.
    $endgroup$
    – JMenezes
    Dec 18 '18 at 15:46


















  • $begingroup$
    To clarify, you want the vector of reflection ?
    $endgroup$
    – T. Fo
    Dec 17 '18 at 20:45










  • $begingroup$
    Also, the values are restricted between $0$ and $1$, and their sum is $1$, or their sum is $le 1$? Just trying to work out exactly what simplex you're referring to.
    $endgroup$
    – jgon
    Dec 17 '18 at 20:47










  • $begingroup$
    I want to know the position the system (particle) will be after it reflects. However, if it is easier I can work with just the vector of reflection. And jgon is correct. It is restricted to 0 and 1 and their sum to 1.
    $endgroup$
    – JMenezes
    Dec 18 '18 at 15:46
















$begingroup$
To clarify, you want the vector of reflection ?
$endgroup$
– T. Fo
Dec 17 '18 at 20:45




$begingroup$
To clarify, you want the vector of reflection ?
$endgroup$
– T. Fo
Dec 17 '18 at 20:45












$begingroup$
Also, the values are restricted between $0$ and $1$, and their sum is $1$, or their sum is $le 1$? Just trying to work out exactly what simplex you're referring to.
$endgroup$
– jgon
Dec 17 '18 at 20:47




$begingroup$
Also, the values are restricted between $0$ and $1$, and their sum is $1$, or their sum is $le 1$? Just trying to work out exactly what simplex you're referring to.
$endgroup$
– jgon
Dec 17 '18 at 20:47












$begingroup$
I want to know the position the system (particle) will be after it reflects. However, if it is easier I can work with just the vector of reflection. And jgon is correct. It is restricted to 0 and 1 and their sum to 1.
$endgroup$
– JMenezes
Dec 18 '18 at 15:46




$begingroup$
I want to know the position the system (particle) will be after it reflects. However, if it is easier I can work with just the vector of reflection. And jgon is correct. It is restricted to 0 and 1 and their sum to 1.
$endgroup$
– JMenezes
Dec 18 '18 at 15:46










1 Answer
1






active

oldest

votes


















0












$begingroup$

Angle measurement requires you to introduce metrics, which can be done differently resulting in different embeddings of the simplex into $mathbf R^{k}$ ($k$ is the size of probability vector). However, let's discuss the most symmetric one (the one that creates a regular simplex as an embedding).



We will embed the simplex into $mathbf R^{k}$ with vertices at the end of basis unit vectors. Thus, our simplex lies on a hyperplane $sum p_i=1$. Its normal is:
$$n=frac1{sqrt k}(1,ldots,1)^T$$



To get the normal to the border lying at the hyperplane, we project the normal, for example, $e_1=(1,0,ldots,0)$ to the hyperplane:
$$v_1'=e_1-n(e_1,v),qquad v_1=frac{v_1'}{|v_1'|}=frac1{sqrt{k(k-1)}}Big((k-1),-1,ldots,-1Big)^T$$
This vector is what we use in formula you have found.






share|cite|improve this answer











$endgroup$













  • $begingroup$
    I am still a little confused with the $n$ in this formulae. In a 3D case, from your first equation I get it $n={1,1,1}$, since $n*sqrt{n} = {1,1,1}$. But I am not quite getting how it becomes a function on $v_1'$ part or what this part is representing. Can you clarify, please? Thanks.
    $endgroup$
    – JMenezes
    Dec 18 '18 at 18:05












  • $begingroup$
    Sorry, it was a letter collision. I have changed the number of $p$-s to be $k$.
    $endgroup$
    – Vasily Mitch
    Dec 18 '18 at 18:13











Your Answer





StackExchange.ifUsing("editor", function () {
return StackExchange.using("mathjaxEditing", function () {
StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix) {
StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
});
});
}, "mathjax-editing");

StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "69"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
noCode: true, onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3044418%2fhow-to-represent-reflection-of-a-particle-inside-a-standard-simplex%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









0












$begingroup$

Angle measurement requires you to introduce metrics, which can be done differently resulting in different embeddings of the simplex into $mathbf R^{k}$ ($k$ is the size of probability vector). However, let's discuss the most symmetric one (the one that creates a regular simplex as an embedding).



We will embed the simplex into $mathbf R^{k}$ with vertices at the end of basis unit vectors. Thus, our simplex lies on a hyperplane $sum p_i=1$. Its normal is:
$$n=frac1{sqrt k}(1,ldots,1)^T$$



To get the normal to the border lying at the hyperplane, we project the normal, for example, $e_1=(1,0,ldots,0)$ to the hyperplane:
$$v_1'=e_1-n(e_1,v),qquad v_1=frac{v_1'}{|v_1'|}=frac1{sqrt{k(k-1)}}Big((k-1),-1,ldots,-1Big)^T$$
This vector is what we use in formula you have found.






share|cite|improve this answer











$endgroup$













  • $begingroup$
    I am still a little confused with the $n$ in this formulae. In a 3D case, from your first equation I get it $n={1,1,1}$, since $n*sqrt{n} = {1,1,1}$. But I am not quite getting how it becomes a function on $v_1'$ part or what this part is representing. Can you clarify, please? Thanks.
    $endgroup$
    – JMenezes
    Dec 18 '18 at 18:05












  • $begingroup$
    Sorry, it was a letter collision. I have changed the number of $p$-s to be $k$.
    $endgroup$
    – Vasily Mitch
    Dec 18 '18 at 18:13
















0












$begingroup$

Angle measurement requires you to introduce metrics, which can be done differently resulting in different embeddings of the simplex into $mathbf R^{k}$ ($k$ is the size of probability vector). However, let's discuss the most symmetric one (the one that creates a regular simplex as an embedding).



We will embed the simplex into $mathbf R^{k}$ with vertices at the end of basis unit vectors. Thus, our simplex lies on a hyperplane $sum p_i=1$. Its normal is:
$$n=frac1{sqrt k}(1,ldots,1)^T$$



To get the normal to the border lying at the hyperplane, we project the normal, for example, $e_1=(1,0,ldots,0)$ to the hyperplane:
$$v_1'=e_1-n(e_1,v),qquad v_1=frac{v_1'}{|v_1'|}=frac1{sqrt{k(k-1)}}Big((k-1),-1,ldots,-1Big)^T$$
This vector is what we use in formula you have found.






share|cite|improve this answer











$endgroup$













  • $begingroup$
    I am still a little confused with the $n$ in this formulae. In a 3D case, from your first equation I get it $n={1,1,1}$, since $n*sqrt{n} = {1,1,1}$. But I am not quite getting how it becomes a function on $v_1'$ part or what this part is representing. Can you clarify, please? Thanks.
    $endgroup$
    – JMenezes
    Dec 18 '18 at 18:05












  • $begingroup$
    Sorry, it was a letter collision. I have changed the number of $p$-s to be $k$.
    $endgroup$
    – Vasily Mitch
    Dec 18 '18 at 18:13














0












0








0





$begingroup$

Angle measurement requires you to introduce metrics, which can be done differently resulting in different embeddings of the simplex into $mathbf R^{k}$ ($k$ is the size of probability vector). However, let's discuss the most symmetric one (the one that creates a regular simplex as an embedding).



We will embed the simplex into $mathbf R^{k}$ with vertices at the end of basis unit vectors. Thus, our simplex lies on a hyperplane $sum p_i=1$. Its normal is:
$$n=frac1{sqrt k}(1,ldots,1)^T$$



To get the normal to the border lying at the hyperplane, we project the normal, for example, $e_1=(1,0,ldots,0)$ to the hyperplane:
$$v_1'=e_1-n(e_1,v),qquad v_1=frac{v_1'}{|v_1'|}=frac1{sqrt{k(k-1)}}Big((k-1),-1,ldots,-1Big)^T$$
This vector is what we use in formula you have found.






share|cite|improve this answer











$endgroup$



Angle measurement requires you to introduce metrics, which can be done differently resulting in different embeddings of the simplex into $mathbf R^{k}$ ($k$ is the size of probability vector). However, let's discuss the most symmetric one (the one that creates a regular simplex as an embedding).



We will embed the simplex into $mathbf R^{k}$ with vertices at the end of basis unit vectors. Thus, our simplex lies on a hyperplane $sum p_i=1$. Its normal is:
$$n=frac1{sqrt k}(1,ldots,1)^T$$



To get the normal to the border lying at the hyperplane, we project the normal, for example, $e_1=(1,0,ldots,0)$ to the hyperplane:
$$v_1'=e_1-n(e_1,v),qquad v_1=frac{v_1'}{|v_1'|}=frac1{sqrt{k(k-1)}}Big((k-1),-1,ldots,-1Big)^T$$
This vector is what we use in formula you have found.







share|cite|improve this answer














share|cite|improve this answer



share|cite|improve this answer








edited Dec 18 '18 at 18:11

























answered Dec 17 '18 at 21:28









Vasily MitchVasily Mitch

2,3141311




2,3141311












  • $begingroup$
    I am still a little confused with the $n$ in this formulae. In a 3D case, from your first equation I get it $n={1,1,1}$, since $n*sqrt{n} = {1,1,1}$. But I am not quite getting how it becomes a function on $v_1'$ part or what this part is representing. Can you clarify, please? Thanks.
    $endgroup$
    – JMenezes
    Dec 18 '18 at 18:05












  • $begingroup$
    Sorry, it was a letter collision. I have changed the number of $p$-s to be $k$.
    $endgroup$
    – Vasily Mitch
    Dec 18 '18 at 18:13


















  • $begingroup$
    I am still a little confused with the $n$ in this formulae. In a 3D case, from your first equation I get it $n={1,1,1}$, since $n*sqrt{n} = {1,1,1}$. But I am not quite getting how it becomes a function on $v_1'$ part or what this part is representing. Can you clarify, please? Thanks.
    $endgroup$
    – JMenezes
    Dec 18 '18 at 18:05












  • $begingroup$
    Sorry, it was a letter collision. I have changed the number of $p$-s to be $k$.
    $endgroup$
    – Vasily Mitch
    Dec 18 '18 at 18:13
















$begingroup$
I am still a little confused with the $n$ in this formulae. In a 3D case, from your first equation I get it $n={1,1,1}$, since $n*sqrt{n} = {1,1,1}$. But I am not quite getting how it becomes a function on $v_1'$ part or what this part is representing. Can you clarify, please? Thanks.
$endgroup$
– JMenezes
Dec 18 '18 at 18:05






$begingroup$
I am still a little confused with the $n$ in this formulae. In a 3D case, from your first equation I get it $n={1,1,1}$, since $n*sqrt{n} = {1,1,1}$. But I am not quite getting how it becomes a function on $v_1'$ part or what this part is representing. Can you clarify, please? Thanks.
$endgroup$
– JMenezes
Dec 18 '18 at 18:05














$begingroup$
Sorry, it was a letter collision. I have changed the number of $p$-s to be $k$.
$endgroup$
– Vasily Mitch
Dec 18 '18 at 18:13




$begingroup$
Sorry, it was a letter collision. I have changed the number of $p$-s to be $k$.
$endgroup$
– Vasily Mitch
Dec 18 '18 at 18:13


















draft saved

draft discarded




















































Thanks for contributing an answer to Mathematics Stack Exchange!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


Use MathJax to format equations. MathJax reference.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3044418%2fhow-to-represent-reflection-of-a-particle-inside-a-standard-simplex%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Wiesbaden

Marschland

Dieringhausen