How to specify a point belong to an ellipse?
documentclass[border=15pt,pstricks,12pt]{standalone}
usepackage{pst-eucl,pst-calculate}
begin{document}
degrees[36]
begin{pspicture}[showgrid](-3,-3)(4,4)
defa{2}
defxa{pscalculate{a*cos(5)}}
defya{pscalculate{(a/4)*sin(5)}}
psellipse(0,0)(+a,a/4)
pstGeonode[PosAngle=-45](xa,ya){A}
pscircle{2}
multido{i=0+1}{36}{psdot(2;i)}
end{pspicture}
end{document}

Question: How to specify a point belong to an ellipse? Ps: The syntax (r;angle) help to specify a point belong to a circle.
pstricks
add a comment |
documentclass[border=15pt,pstricks,12pt]{standalone}
usepackage{pst-eucl,pst-calculate}
begin{document}
degrees[36]
begin{pspicture}[showgrid](-3,-3)(4,4)
defa{2}
defxa{pscalculate{a*cos(5)}}
defya{pscalculate{(a/4)*sin(5)}}
psellipse(0,0)(+a,a/4)
pstGeonode[PosAngle=-45](xa,ya){A}
pscircle{2}
multido{i=0+1}{36}{psdot(2;i)}
end{pspicture}
end{document}

Question: How to specify a point belong to an ellipse? Ps: The syntax (r;angle) help to specify a point belong to a circle.
pstricks
add a comment |
documentclass[border=15pt,pstricks,12pt]{standalone}
usepackage{pst-eucl,pst-calculate}
begin{document}
degrees[36]
begin{pspicture}[showgrid](-3,-3)(4,4)
defa{2}
defxa{pscalculate{a*cos(5)}}
defya{pscalculate{(a/4)*sin(5)}}
psellipse(0,0)(+a,a/4)
pstGeonode[PosAngle=-45](xa,ya){A}
pscircle{2}
multido{i=0+1}{36}{psdot(2;i)}
end{pspicture}
end{document}

Question: How to specify a point belong to an ellipse? Ps: The syntax (r;angle) help to specify a point belong to a circle.
pstricks
documentclass[border=15pt,pstricks,12pt]{standalone}
usepackage{pst-eucl,pst-calculate}
begin{document}
degrees[36]
begin{pspicture}[showgrid](-3,-3)(4,4)
defa{2}
defxa{pscalculate{a*cos(5)}}
defya{pscalculate{(a/4)*sin(5)}}
psellipse(0,0)(+a,a/4)
pstGeonode[PosAngle=-45](xa,ya){A}
pscircle{2}
multido{i=0+1}{36}{psdot(2;i)}
end{pspicture}
end{document}

Question: How to specify a point belong to an ellipse? Ps: The syntax (r;angle) help to specify a point belong to a circle.
pstricks
pstricks
edited Feb 23 at 9:29
chishimutoji
asked Feb 23 at 9:22
chishimutojichishimutoji
8251320
8251320
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
x = a cos t
y = b sin t
is the parameterization of an ellipse but the t does not correspond to the angle of position vector (x,y). Let Θ be the angle of position vector.
It is easy to show that tan t = (a sin Θ) / (b cos Θ).
The remaining will be self-explanatory. :-)
documentclass[border=15pt,pstricks,12pt]{standalone}
usepackage{pst-eucl,pst-calculate}
begin{document}
foreach THETA in {60,150,240,330}{%
begin{pspicture}[showgrid](-4,-4)(4,4)
psline[linecolor=red](3;THETA)
psellipse(0,0)(3,2)
qdisk(!3 2 2 copy exch THETAspace sin mul exch THETAspace cos mul atan PtoCab){2pt}
end{pspicture}}
end{document}

Explanation
3 2 2 copyproduces3 2 3 2exchproduces3 2 2 3THETAspace sin mulproduces3 2 2 3*sin(Θ)exchproduces3 2 3*sin(Θ) 2THETAspace cos mulproduces3 2 3*sin(Θ) 2*cos(Θ)atanproduces3 2 tPtoCabproducesx yPtoCabneeds 3 operandsa b tthat will be converted toa*cos(t) b*sin(t).atanneeds 2 operandsy xto produces a quadrant-dependent angle.
Final Release
documentclass[border=15pt,pstricks]{standalone}
usepackage{pst-eucl}
pstVerb{/P2EC {3 copy sin 3 -1 roll mul 3 -1 roll cos 3 -1 roll mul atan PtoCab} bind def}
begin{document}
foreach THETA in {60,150,240,330}{%
begin{pspicture}[showgrid](-4,-4)(4,4)
psline[linecolor=red](3;THETA)
psellipse(0,0)(3,2)
qdisk(!3 2 THETAspace P2EC){2pt}
end{pspicture}}
end{document}
I introduce a new macro P2EC (Polar to Elliptical Cartesian) that will convert a b Θ to a*b*cos Θ/sqrt(a^2 * sin^2 Θ + b^2 * cos^2 Θ) a*b*sin Θ/sqrt(a^2 * sin^2 Θ + b^2 * cos^2 Θ).
Yes, I see. Thanks for your explanation about PS language...
– chishimutoji
Feb 23 at 12:44
Hi, with your final code, what is the roll and bind? :-)
– chishimutoji
Feb 23 at 14:31
@chishimotoji:a b c d e 3 1 rollproducesa b e c d.a b c d e 3 -1 rollproducesa b d e c.a b c d e 3 2 rollproducesa b d e c.
– The Inventor of God
Feb 23 at 14:59
Yes, I will consider it carefully.
– chishimutoji
Feb 23 at 15:06
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "85"
};
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: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
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
},
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%2ftex.stackexchange.com%2fquestions%2f476293%2fhow-to-specify-a-point-belong-to-an-ellipse%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
x = a cos t
y = b sin t
is the parameterization of an ellipse but the t does not correspond to the angle of position vector (x,y). Let Θ be the angle of position vector.
It is easy to show that tan t = (a sin Θ) / (b cos Θ).
The remaining will be self-explanatory. :-)
documentclass[border=15pt,pstricks,12pt]{standalone}
usepackage{pst-eucl,pst-calculate}
begin{document}
foreach THETA in {60,150,240,330}{%
begin{pspicture}[showgrid](-4,-4)(4,4)
psline[linecolor=red](3;THETA)
psellipse(0,0)(3,2)
qdisk(!3 2 2 copy exch THETAspace sin mul exch THETAspace cos mul atan PtoCab){2pt}
end{pspicture}}
end{document}

Explanation
3 2 2 copyproduces3 2 3 2exchproduces3 2 2 3THETAspace sin mulproduces3 2 2 3*sin(Θ)exchproduces3 2 3*sin(Θ) 2THETAspace cos mulproduces3 2 3*sin(Θ) 2*cos(Θ)atanproduces3 2 tPtoCabproducesx yPtoCabneeds 3 operandsa b tthat will be converted toa*cos(t) b*sin(t).atanneeds 2 operandsy xto produces a quadrant-dependent angle.
Final Release
documentclass[border=15pt,pstricks]{standalone}
usepackage{pst-eucl}
pstVerb{/P2EC {3 copy sin 3 -1 roll mul 3 -1 roll cos 3 -1 roll mul atan PtoCab} bind def}
begin{document}
foreach THETA in {60,150,240,330}{%
begin{pspicture}[showgrid](-4,-4)(4,4)
psline[linecolor=red](3;THETA)
psellipse(0,0)(3,2)
qdisk(!3 2 THETAspace P2EC){2pt}
end{pspicture}}
end{document}
I introduce a new macro P2EC (Polar to Elliptical Cartesian) that will convert a b Θ to a*b*cos Θ/sqrt(a^2 * sin^2 Θ + b^2 * cos^2 Θ) a*b*sin Θ/sqrt(a^2 * sin^2 Θ + b^2 * cos^2 Θ).
Yes, I see. Thanks for your explanation about PS language...
– chishimutoji
Feb 23 at 12:44
Hi, with your final code, what is the roll and bind? :-)
– chishimutoji
Feb 23 at 14:31
@chishimotoji:a b c d e 3 1 rollproducesa b e c d.a b c d e 3 -1 rollproducesa b d e c.a b c d e 3 2 rollproducesa b d e c.
– The Inventor of God
Feb 23 at 14:59
Yes, I will consider it carefully.
– chishimutoji
Feb 23 at 15:06
add a comment |
x = a cos t
y = b sin t
is the parameterization of an ellipse but the t does not correspond to the angle of position vector (x,y). Let Θ be the angle of position vector.
It is easy to show that tan t = (a sin Θ) / (b cos Θ).
The remaining will be self-explanatory. :-)
documentclass[border=15pt,pstricks,12pt]{standalone}
usepackage{pst-eucl,pst-calculate}
begin{document}
foreach THETA in {60,150,240,330}{%
begin{pspicture}[showgrid](-4,-4)(4,4)
psline[linecolor=red](3;THETA)
psellipse(0,0)(3,2)
qdisk(!3 2 2 copy exch THETAspace sin mul exch THETAspace cos mul atan PtoCab){2pt}
end{pspicture}}
end{document}

Explanation
3 2 2 copyproduces3 2 3 2exchproduces3 2 2 3THETAspace sin mulproduces3 2 2 3*sin(Θ)exchproduces3 2 3*sin(Θ) 2THETAspace cos mulproduces3 2 3*sin(Θ) 2*cos(Θ)atanproduces3 2 tPtoCabproducesx yPtoCabneeds 3 operandsa b tthat will be converted toa*cos(t) b*sin(t).atanneeds 2 operandsy xto produces a quadrant-dependent angle.
Final Release
documentclass[border=15pt,pstricks]{standalone}
usepackage{pst-eucl}
pstVerb{/P2EC {3 copy sin 3 -1 roll mul 3 -1 roll cos 3 -1 roll mul atan PtoCab} bind def}
begin{document}
foreach THETA in {60,150,240,330}{%
begin{pspicture}[showgrid](-4,-4)(4,4)
psline[linecolor=red](3;THETA)
psellipse(0,0)(3,2)
qdisk(!3 2 THETAspace P2EC){2pt}
end{pspicture}}
end{document}
I introduce a new macro P2EC (Polar to Elliptical Cartesian) that will convert a b Θ to a*b*cos Θ/sqrt(a^2 * sin^2 Θ + b^2 * cos^2 Θ) a*b*sin Θ/sqrt(a^2 * sin^2 Θ + b^2 * cos^2 Θ).
Yes, I see. Thanks for your explanation about PS language...
– chishimutoji
Feb 23 at 12:44
Hi, with your final code, what is the roll and bind? :-)
– chishimutoji
Feb 23 at 14:31
@chishimotoji:a b c d e 3 1 rollproducesa b e c d.a b c d e 3 -1 rollproducesa b d e c.a b c d e 3 2 rollproducesa b d e c.
– The Inventor of God
Feb 23 at 14:59
Yes, I will consider it carefully.
– chishimutoji
Feb 23 at 15:06
add a comment |
x = a cos t
y = b sin t
is the parameterization of an ellipse but the t does not correspond to the angle of position vector (x,y). Let Θ be the angle of position vector.
It is easy to show that tan t = (a sin Θ) / (b cos Θ).
The remaining will be self-explanatory. :-)
documentclass[border=15pt,pstricks,12pt]{standalone}
usepackage{pst-eucl,pst-calculate}
begin{document}
foreach THETA in {60,150,240,330}{%
begin{pspicture}[showgrid](-4,-4)(4,4)
psline[linecolor=red](3;THETA)
psellipse(0,0)(3,2)
qdisk(!3 2 2 copy exch THETAspace sin mul exch THETAspace cos mul atan PtoCab){2pt}
end{pspicture}}
end{document}

Explanation
3 2 2 copyproduces3 2 3 2exchproduces3 2 2 3THETAspace sin mulproduces3 2 2 3*sin(Θ)exchproduces3 2 3*sin(Θ) 2THETAspace cos mulproduces3 2 3*sin(Θ) 2*cos(Θ)atanproduces3 2 tPtoCabproducesx yPtoCabneeds 3 operandsa b tthat will be converted toa*cos(t) b*sin(t).atanneeds 2 operandsy xto produces a quadrant-dependent angle.
Final Release
documentclass[border=15pt,pstricks]{standalone}
usepackage{pst-eucl}
pstVerb{/P2EC {3 copy sin 3 -1 roll mul 3 -1 roll cos 3 -1 roll mul atan PtoCab} bind def}
begin{document}
foreach THETA in {60,150,240,330}{%
begin{pspicture}[showgrid](-4,-4)(4,4)
psline[linecolor=red](3;THETA)
psellipse(0,0)(3,2)
qdisk(!3 2 THETAspace P2EC){2pt}
end{pspicture}}
end{document}
I introduce a new macro P2EC (Polar to Elliptical Cartesian) that will convert a b Θ to a*b*cos Θ/sqrt(a^2 * sin^2 Θ + b^2 * cos^2 Θ) a*b*sin Θ/sqrt(a^2 * sin^2 Θ + b^2 * cos^2 Θ).
x = a cos t
y = b sin t
is the parameterization of an ellipse but the t does not correspond to the angle of position vector (x,y). Let Θ be the angle of position vector.
It is easy to show that tan t = (a sin Θ) / (b cos Θ).
The remaining will be self-explanatory. :-)
documentclass[border=15pt,pstricks,12pt]{standalone}
usepackage{pst-eucl,pst-calculate}
begin{document}
foreach THETA in {60,150,240,330}{%
begin{pspicture}[showgrid](-4,-4)(4,4)
psline[linecolor=red](3;THETA)
psellipse(0,0)(3,2)
qdisk(!3 2 2 copy exch THETAspace sin mul exch THETAspace cos mul atan PtoCab){2pt}
end{pspicture}}
end{document}

Explanation
3 2 2 copyproduces3 2 3 2exchproduces3 2 2 3THETAspace sin mulproduces3 2 2 3*sin(Θ)exchproduces3 2 3*sin(Θ) 2THETAspace cos mulproduces3 2 3*sin(Θ) 2*cos(Θ)atanproduces3 2 tPtoCabproducesx yPtoCabneeds 3 operandsa b tthat will be converted toa*cos(t) b*sin(t).atanneeds 2 operandsy xto produces a quadrant-dependent angle.
Final Release
documentclass[border=15pt,pstricks]{standalone}
usepackage{pst-eucl}
pstVerb{/P2EC {3 copy sin 3 -1 roll mul 3 -1 roll cos 3 -1 roll mul atan PtoCab} bind def}
begin{document}
foreach THETA in {60,150,240,330}{%
begin{pspicture}[showgrid](-4,-4)(4,4)
psline[linecolor=red](3;THETA)
psellipse(0,0)(3,2)
qdisk(!3 2 THETAspace P2EC){2pt}
end{pspicture}}
end{document}
I introduce a new macro P2EC (Polar to Elliptical Cartesian) that will convert a b Θ to a*b*cos Θ/sqrt(a^2 * sin^2 Θ + b^2 * cos^2 Θ) a*b*sin Θ/sqrt(a^2 * sin^2 Θ + b^2 * cos^2 Θ).
edited Feb 23 at 13:28
answered Feb 23 at 12:18
The Inventor of GodThe Inventor of God
4,93211041
4,93211041
Yes, I see. Thanks for your explanation about PS language...
– chishimutoji
Feb 23 at 12:44
Hi, with your final code, what is the roll and bind? :-)
– chishimutoji
Feb 23 at 14:31
@chishimotoji:a b c d e 3 1 rollproducesa b e c d.a b c d e 3 -1 rollproducesa b d e c.a b c d e 3 2 rollproducesa b d e c.
– The Inventor of God
Feb 23 at 14:59
Yes, I will consider it carefully.
– chishimutoji
Feb 23 at 15:06
add a comment |
Yes, I see. Thanks for your explanation about PS language...
– chishimutoji
Feb 23 at 12:44
Hi, with your final code, what is the roll and bind? :-)
– chishimutoji
Feb 23 at 14:31
@chishimotoji:a b c d e 3 1 rollproducesa b e c d.a b c d e 3 -1 rollproducesa b d e c.a b c d e 3 2 rollproducesa b d e c.
– The Inventor of God
Feb 23 at 14:59
Yes, I will consider it carefully.
– chishimutoji
Feb 23 at 15:06
Yes, I see. Thanks for your explanation about PS language...
– chishimutoji
Feb 23 at 12:44
Yes, I see. Thanks for your explanation about PS language...
– chishimutoji
Feb 23 at 12:44
Hi, with your final code, what is the roll and bind? :-)
– chishimutoji
Feb 23 at 14:31
Hi, with your final code, what is the roll and bind? :-)
– chishimutoji
Feb 23 at 14:31
@chishimotoji:
a b c d e 3 1 roll produces a b e c d. a b c d e 3 -1 roll produces a b d e c. a b c d e 3 2 roll produces a b d e c.– The Inventor of God
Feb 23 at 14:59
@chishimotoji:
a b c d e 3 1 roll produces a b e c d. a b c d e 3 -1 roll produces a b d e c. a b c d e 3 2 roll produces a b d e c.– The Inventor of God
Feb 23 at 14:59
Yes, I will consider it carefully.
– chishimutoji
Feb 23 at 15:06
Yes, I will consider it carefully.
– chishimutoji
Feb 23 at 15:06
add a comment |
Thanks for contributing an answer to TeX - LaTeX 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.
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%2ftex.stackexchange.com%2fquestions%2f476293%2fhow-to-specify-a-point-belong-to-an-ellipse%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