Intersection of ray with plane given in homogeneous coordinates
$begingroup$
Given
- a plane $pinmathbb{P}^3$ expressed in homogeneous coordinates ($p_x$, $p_y$, $p_z$, $p_w$)
- a ray expressed as
- a source point $sinmathbb{P^3}$ expressed in homogeneous coordinates ($s_x$, $s_y$, $s_z$, $s_w$)
- a direction $din S^2$ expressed in coordinates ($d_x$, $d_y$, $d_z$)
how can I find the point at which the ray intersects the plane?
I can sometimes work out efficient algorithms with cross products in $mathbb{P^2}$ but I battle with $mathbb{P^3}$ due to having to visualize 4 dimensions.
projective-geometry
$endgroup$
add a comment |
$begingroup$
Given
- a plane $pinmathbb{P}^3$ expressed in homogeneous coordinates ($p_x$, $p_y$, $p_z$, $p_w$)
- a ray expressed as
- a source point $sinmathbb{P^3}$ expressed in homogeneous coordinates ($s_x$, $s_y$, $s_z$, $s_w$)
- a direction $din S^2$ expressed in coordinates ($d_x$, $d_y$, $d_z$)
how can I find the point at which the ray intersects the plane?
I can sometimes work out efficient algorithms with cross products in $mathbb{P^2}$ but I battle with $mathbb{P^3}$ due to having to visualize 4 dimensions.
projective-geometry
$endgroup$
add a comment |
$begingroup$
Given
- a plane $pinmathbb{P}^3$ expressed in homogeneous coordinates ($p_x$, $p_y$, $p_z$, $p_w$)
- a ray expressed as
- a source point $sinmathbb{P^3}$ expressed in homogeneous coordinates ($s_x$, $s_y$, $s_z$, $s_w$)
- a direction $din S^2$ expressed in coordinates ($d_x$, $d_y$, $d_z$)
how can I find the point at which the ray intersects the plane?
I can sometimes work out efficient algorithms with cross products in $mathbb{P^2}$ but I battle with $mathbb{P^3}$ due to having to visualize 4 dimensions.
projective-geometry
$endgroup$
Given
- a plane $pinmathbb{P}^3$ expressed in homogeneous coordinates ($p_x$, $p_y$, $p_z$, $p_w$)
- a ray expressed as
- a source point $sinmathbb{P^3}$ expressed in homogeneous coordinates ($s_x$, $s_y$, $s_z$, $s_w$)
- a direction $din S^2$ expressed in coordinates ($d_x$, $d_y$, $d_z$)
how can I find the point at which the ray intersects the plane?
I can sometimes work out efficient algorithms with cross products in $mathbb{P^2}$ but I battle with $mathbb{P^3}$ due to having to visualize 4 dimensions.
projective-geometry
projective-geometry
asked Sep 26 '18 at 21:44
MusefulMuseful
1839
1839
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
$begingroup$
One way to represent a line in $mathbb P^3$ is via its Plücker matrix: if $mathbf p$ and $mathbf q$ are two distinct points on the line, then its Plücker matrix is $L=mathbf pmathbf q^T-mathbf qmathbf p^T$. It’s an easy exercise to verify that $L$ is, up to a scale factor, independent of the choice of the two points. A handy feature of this representation is that if $mathbfpi$ is a homogeneous vector that represents a plane, its intersection with the line is simply $Lmathbfpi$.
Applying this to your problem, you have the two points $mathbf s = (s_x,s_y,s_z,s_w)^T$ and $mathbf d = (d_x,d_y,d_z,0)^T$ that define the line, and the plane $mathbfpi = (p_x,p_y,p_z,p_w)^T$, so $$Lmathbfpi = (mathbf smathbf d^T-mathbf dmathbf s^T)mathbfpi = (mathbfpi^Tmathbf d)mathbf s - (mathbfpi^Tmathbf s)mathbf d,tag{*}$$ i.e., two dot products, two multiplications of a vector by a scalar, a vector addition, and three divisions to dehomogenize. If this expression vanishes, then the line lies on the plane. If you’re specifically interested in the intersection of a ray with the plane, you’ll also need to test that this point lies on the correct side of the line from $s$, or equivalently, that $d$ points toward the plane from $s$.
The expression (*) can also be derived directly: The line through $mathbf s$ and $mathbf d$ consists of all nontrivial linear combinations $lambdamathbf s+mumathbf d$ of the two points, and the intersection of the line with $mathbfpi$ can therefore be found by solving $$mathbfpi^T(lambdamathbf s+mumathbf d) = begin{bmatrix}mathbfpi^Tmathbf s&mathbfpi^Tmathbf dend{bmatrix} begin{bmatrix}lambda\muend{bmatrix}=0$$ for $lambda$ and $mu$, which is obviously satisfied by $lambda=mathbfpi^Tmathbf d$, $mu=-mathbfpi^Tmathbf s$. It can also be viewed as a special case of a principle known as Plücker’s mu.
The formula (*) is the three-dimensional analogue of using cross products to find the intersection of the line $mathbf l$ with the line defined by $mathbf s$ and $mathbf d$ in $mathbb P^2$, since we have the identity $$mathbf ltimes(mathbf stimesmathbf d) = (mathbf l^Tmathbf d)mathbf s - (mathbf l^Tmathbf s)mathbf d.$$
$endgroup$
add a comment |
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
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f2932258%2fintersection-of-ray-with-plane-given-in-homogeneous-coordinates%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
$begingroup$
One way to represent a line in $mathbb P^3$ is via its Plücker matrix: if $mathbf p$ and $mathbf q$ are two distinct points on the line, then its Plücker matrix is $L=mathbf pmathbf q^T-mathbf qmathbf p^T$. It’s an easy exercise to verify that $L$ is, up to a scale factor, independent of the choice of the two points. A handy feature of this representation is that if $mathbfpi$ is a homogeneous vector that represents a plane, its intersection with the line is simply $Lmathbfpi$.
Applying this to your problem, you have the two points $mathbf s = (s_x,s_y,s_z,s_w)^T$ and $mathbf d = (d_x,d_y,d_z,0)^T$ that define the line, and the plane $mathbfpi = (p_x,p_y,p_z,p_w)^T$, so $$Lmathbfpi = (mathbf smathbf d^T-mathbf dmathbf s^T)mathbfpi = (mathbfpi^Tmathbf d)mathbf s - (mathbfpi^Tmathbf s)mathbf d,tag{*}$$ i.e., two dot products, two multiplications of a vector by a scalar, a vector addition, and three divisions to dehomogenize. If this expression vanishes, then the line lies on the plane. If you’re specifically interested in the intersection of a ray with the plane, you’ll also need to test that this point lies on the correct side of the line from $s$, or equivalently, that $d$ points toward the plane from $s$.
The expression (*) can also be derived directly: The line through $mathbf s$ and $mathbf d$ consists of all nontrivial linear combinations $lambdamathbf s+mumathbf d$ of the two points, and the intersection of the line with $mathbfpi$ can therefore be found by solving $$mathbfpi^T(lambdamathbf s+mumathbf d) = begin{bmatrix}mathbfpi^Tmathbf s&mathbfpi^Tmathbf dend{bmatrix} begin{bmatrix}lambda\muend{bmatrix}=0$$ for $lambda$ and $mu$, which is obviously satisfied by $lambda=mathbfpi^Tmathbf d$, $mu=-mathbfpi^Tmathbf s$. It can also be viewed as a special case of a principle known as Plücker’s mu.
The formula (*) is the three-dimensional analogue of using cross products to find the intersection of the line $mathbf l$ with the line defined by $mathbf s$ and $mathbf d$ in $mathbb P^2$, since we have the identity $$mathbf ltimes(mathbf stimesmathbf d) = (mathbf l^Tmathbf d)mathbf s - (mathbf l^Tmathbf s)mathbf d.$$
$endgroup$
add a comment |
$begingroup$
One way to represent a line in $mathbb P^3$ is via its Plücker matrix: if $mathbf p$ and $mathbf q$ are two distinct points on the line, then its Plücker matrix is $L=mathbf pmathbf q^T-mathbf qmathbf p^T$. It’s an easy exercise to verify that $L$ is, up to a scale factor, independent of the choice of the two points. A handy feature of this representation is that if $mathbfpi$ is a homogeneous vector that represents a plane, its intersection with the line is simply $Lmathbfpi$.
Applying this to your problem, you have the two points $mathbf s = (s_x,s_y,s_z,s_w)^T$ and $mathbf d = (d_x,d_y,d_z,0)^T$ that define the line, and the plane $mathbfpi = (p_x,p_y,p_z,p_w)^T$, so $$Lmathbfpi = (mathbf smathbf d^T-mathbf dmathbf s^T)mathbfpi = (mathbfpi^Tmathbf d)mathbf s - (mathbfpi^Tmathbf s)mathbf d,tag{*}$$ i.e., two dot products, two multiplications of a vector by a scalar, a vector addition, and three divisions to dehomogenize. If this expression vanishes, then the line lies on the plane. If you’re specifically interested in the intersection of a ray with the plane, you’ll also need to test that this point lies on the correct side of the line from $s$, or equivalently, that $d$ points toward the plane from $s$.
The expression (*) can also be derived directly: The line through $mathbf s$ and $mathbf d$ consists of all nontrivial linear combinations $lambdamathbf s+mumathbf d$ of the two points, and the intersection of the line with $mathbfpi$ can therefore be found by solving $$mathbfpi^T(lambdamathbf s+mumathbf d) = begin{bmatrix}mathbfpi^Tmathbf s&mathbfpi^Tmathbf dend{bmatrix} begin{bmatrix}lambda\muend{bmatrix}=0$$ for $lambda$ and $mu$, which is obviously satisfied by $lambda=mathbfpi^Tmathbf d$, $mu=-mathbfpi^Tmathbf s$. It can also be viewed as a special case of a principle known as Plücker’s mu.
The formula (*) is the three-dimensional analogue of using cross products to find the intersection of the line $mathbf l$ with the line defined by $mathbf s$ and $mathbf d$ in $mathbb P^2$, since we have the identity $$mathbf ltimes(mathbf stimesmathbf d) = (mathbf l^Tmathbf d)mathbf s - (mathbf l^Tmathbf s)mathbf d.$$
$endgroup$
add a comment |
$begingroup$
One way to represent a line in $mathbb P^3$ is via its Plücker matrix: if $mathbf p$ and $mathbf q$ are two distinct points on the line, then its Plücker matrix is $L=mathbf pmathbf q^T-mathbf qmathbf p^T$. It’s an easy exercise to verify that $L$ is, up to a scale factor, independent of the choice of the two points. A handy feature of this representation is that if $mathbfpi$ is a homogeneous vector that represents a plane, its intersection with the line is simply $Lmathbfpi$.
Applying this to your problem, you have the two points $mathbf s = (s_x,s_y,s_z,s_w)^T$ and $mathbf d = (d_x,d_y,d_z,0)^T$ that define the line, and the plane $mathbfpi = (p_x,p_y,p_z,p_w)^T$, so $$Lmathbfpi = (mathbf smathbf d^T-mathbf dmathbf s^T)mathbfpi = (mathbfpi^Tmathbf d)mathbf s - (mathbfpi^Tmathbf s)mathbf d,tag{*}$$ i.e., two dot products, two multiplications of a vector by a scalar, a vector addition, and three divisions to dehomogenize. If this expression vanishes, then the line lies on the plane. If you’re specifically interested in the intersection of a ray with the plane, you’ll also need to test that this point lies on the correct side of the line from $s$, or equivalently, that $d$ points toward the plane from $s$.
The expression (*) can also be derived directly: The line through $mathbf s$ and $mathbf d$ consists of all nontrivial linear combinations $lambdamathbf s+mumathbf d$ of the two points, and the intersection of the line with $mathbfpi$ can therefore be found by solving $$mathbfpi^T(lambdamathbf s+mumathbf d) = begin{bmatrix}mathbfpi^Tmathbf s&mathbfpi^Tmathbf dend{bmatrix} begin{bmatrix}lambda\muend{bmatrix}=0$$ for $lambda$ and $mu$, which is obviously satisfied by $lambda=mathbfpi^Tmathbf d$, $mu=-mathbfpi^Tmathbf s$. It can also be viewed as a special case of a principle known as Plücker’s mu.
The formula (*) is the three-dimensional analogue of using cross products to find the intersection of the line $mathbf l$ with the line defined by $mathbf s$ and $mathbf d$ in $mathbb P^2$, since we have the identity $$mathbf ltimes(mathbf stimesmathbf d) = (mathbf l^Tmathbf d)mathbf s - (mathbf l^Tmathbf s)mathbf d.$$
$endgroup$
One way to represent a line in $mathbb P^3$ is via its Plücker matrix: if $mathbf p$ and $mathbf q$ are two distinct points on the line, then its Plücker matrix is $L=mathbf pmathbf q^T-mathbf qmathbf p^T$. It’s an easy exercise to verify that $L$ is, up to a scale factor, independent of the choice of the two points. A handy feature of this representation is that if $mathbfpi$ is a homogeneous vector that represents a plane, its intersection with the line is simply $Lmathbfpi$.
Applying this to your problem, you have the two points $mathbf s = (s_x,s_y,s_z,s_w)^T$ and $mathbf d = (d_x,d_y,d_z,0)^T$ that define the line, and the plane $mathbfpi = (p_x,p_y,p_z,p_w)^T$, so $$Lmathbfpi = (mathbf smathbf d^T-mathbf dmathbf s^T)mathbfpi = (mathbfpi^Tmathbf d)mathbf s - (mathbfpi^Tmathbf s)mathbf d,tag{*}$$ i.e., two dot products, two multiplications of a vector by a scalar, a vector addition, and three divisions to dehomogenize. If this expression vanishes, then the line lies on the plane. If you’re specifically interested in the intersection of a ray with the plane, you’ll also need to test that this point lies on the correct side of the line from $s$, or equivalently, that $d$ points toward the plane from $s$.
The expression (*) can also be derived directly: The line through $mathbf s$ and $mathbf d$ consists of all nontrivial linear combinations $lambdamathbf s+mumathbf d$ of the two points, and the intersection of the line with $mathbfpi$ can therefore be found by solving $$mathbfpi^T(lambdamathbf s+mumathbf d) = begin{bmatrix}mathbfpi^Tmathbf s&mathbfpi^Tmathbf dend{bmatrix} begin{bmatrix}lambda\muend{bmatrix}=0$$ for $lambda$ and $mu$, which is obviously satisfied by $lambda=mathbfpi^Tmathbf d$, $mu=-mathbfpi^Tmathbf s$. It can also be viewed as a special case of a principle known as Plücker’s mu.
The formula (*) is the three-dimensional analogue of using cross products to find the intersection of the line $mathbf l$ with the line defined by $mathbf s$ and $mathbf d$ in $mathbb P^2$, since we have the identity $$mathbf ltimes(mathbf stimesmathbf d) = (mathbf l^Tmathbf d)mathbf s - (mathbf l^Tmathbf s)mathbf d.$$
edited Dec 6 '18 at 0:53
answered Sep 27 '18 at 0:08
amdamd
29.8k21050
29.8k21050
add a comment |
add a comment |
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.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f2932258%2fintersection-of-ray-with-plane-given-in-homogeneous-coordinates%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
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