TikZ: How to reverse arrow direction without switching start/end point? The Next CEO of Stack OverflowTikz: Arrowheads in the centerspiral spring in tikzHow can I improve the look of an arrowhead at the end of a small-radius arc?tikz - stealth arrow makes a drift in a curved lineRotate a node but not its content: the case of the ellipse decorationHow to define the default vertical distance between nodes?TikZ scaling graphic and adjust node position and keep font sizeNumerical conditional within tikz keys?Why do I get an extra white page before my TikZ picture?How to prevent rounded and duplicated tick labels in pgfplots with fixed precision?Line up nested tikz enviroments or how to get rid of themHow to draw a square and its diagonals with arrows?tikz arrow directionVertical spacing between arrow and caption with unicode-math
Why did the Drakh emissary look so blurred in S04:E11 "Lines of Communication"?
Horror film about a man brought out of cryogenic suspension without a soul, around 1990
Is it possible to create a QR code using text?
How can a day be of 24 hours?
Is it a bad idea to plug the other end of ESD strap to wall ground?
How to unfasten electrical subpanel attached with ramset
What does this strange code stamp on my passport mean?
Does Germany produce more waste than the US?
How to show a landlord what we have in savings?
Could you use a laser beam as a modulated carrier wave for radio signal?
How dangerous is XSS
Find the majority element, which appears more than half the time
What difference does it make matching a word with/without a trailing whitespace?
How to implement Comparable so it is consistent with identity-equality
Salesforce opportunity stages
Is it reasonable to ask other researchers to send me their previous grant applications?
Shortening a title without changing its meaning
Compilation of a 2d array and a 1d array
It it possible to avoid kiwi.com's automatic online check-in and instead do it manually by yourself?
Is it OK to decorate a log book cover?
How can I prove that a state of equilibrium is unstable?
Upgrading From a 9 Speed Sora Derailleur?
Find a path from s to t using as few red nodes as possible
Which acid/base does a strong base/acid react when added to a buffer solution?
TikZ: How to reverse arrow direction without switching start/end point?
The Next CEO of Stack OverflowTikz: Arrowheads in the centerspiral spring in tikzHow can I improve the look of an arrowhead at the end of a small-radius arc?tikz - stealth arrow makes a drift in a curved lineRotate a node but not its content: the case of the ellipse decorationHow to define the default vertical distance between nodes?TikZ scaling graphic and adjust node position and keep font sizeNumerical conditional within tikz keys?Why do I get an extra white page before my TikZ picture?How to prevent rounded and duplicated tick labels in pgfplots with fixed precision?Line up nested tikz enviroments or how to get rid of themHow to draw a square and its diagonals with arrows?tikz arrow directionVertical spacing between arrow and caption with unicode-math
Assumed we have this MWE from user Caramdir:
documentclassarticle
usepackagetikz
usetikzlibraryarrows,calc,decorations.markings,decorations.pathmorphing,arrows.meta
begindocument
begintikzpicture
draw [domain=0:25.1327,variable=t,smooth,samples=75, -Latex]
plot (t r: 0.002*t*t);
endtikzpicture
enddocument
I want to reverse the arrow head position, so that the arrow tip is located at the inner end of the spiral and directs to the center.
How to do so?
tikz-pgf arrows tikz-arrows tikz-node
add a comment |
Assumed we have this MWE from user Caramdir:
documentclassarticle
usepackagetikz
usetikzlibraryarrows,calc,decorations.markings,decorations.pathmorphing,arrows.meta
begindocument
begintikzpicture
draw [domain=0:25.1327,variable=t,smooth,samples=75, -Latex]
plot (t r: 0.002*t*t);
endtikzpicture
enddocument
I want to reverse the arrow head position, so that the arrow tip is located at the inner end of the spiral and directs to the center.
How to do so?
tikz-pgf arrows tikz-arrows tikz-node
instead-Latex
useLatex-
? however, the result be ugly ....
– Zarko
2 days ago
You just place the arrow in the other end in the options:Latex-
-and then you will need to have a look at: tex.stackexchange.com/questions/176779/…
– hpekristiansen
2 days ago
add a comment |
Assumed we have this MWE from user Caramdir:
documentclassarticle
usepackagetikz
usetikzlibraryarrows,calc,decorations.markings,decorations.pathmorphing,arrows.meta
begindocument
begintikzpicture
draw [domain=0:25.1327,variable=t,smooth,samples=75, -Latex]
plot (t r: 0.002*t*t);
endtikzpicture
enddocument
I want to reverse the arrow head position, so that the arrow tip is located at the inner end of the spiral and directs to the center.
How to do so?
tikz-pgf arrows tikz-arrows tikz-node
Assumed we have this MWE from user Caramdir:
documentclassarticle
usepackagetikz
usetikzlibraryarrows,calc,decorations.markings,decorations.pathmorphing,arrows.meta
begindocument
begintikzpicture
draw [domain=0:25.1327,variable=t,smooth,samples=75, -Latex]
plot (t r: 0.002*t*t);
endtikzpicture
enddocument
I want to reverse the arrow head position, so that the arrow tip is located at the inner end of the spiral and directs to the center.
How to do so?
tikz-pgf arrows tikz-arrows tikz-node
tikz-pgf arrows tikz-arrows tikz-node
edited 2 days ago
Dave
asked 2 days ago
DaveDave
1,128619
1,128619
instead-Latex
useLatex-
? however, the result be ugly ....
– Zarko
2 days ago
You just place the arrow in the other end in the options:Latex-
-and then you will need to have a look at: tex.stackexchange.com/questions/176779/…
– hpekristiansen
2 days ago
add a comment |
instead-Latex
useLatex-
? however, the result be ugly ....
– Zarko
2 days ago
You just place the arrow in the other end in the options:Latex-
-and then you will need to have a look at: tex.stackexchange.com/questions/176779/…
– hpekristiansen
2 days ago
instead
-Latex
use Latex-
? however, the result be ugly ....– Zarko
2 days ago
instead
-Latex
use Latex-
? however, the result be ugly ....– Zarko
2 days ago
You just place the arrow in the other end in the options:
Latex-
-and then you will need to have a look at: tex.stackexchange.com/questions/176779/…– hpekristiansen
2 days ago
You just place the arrow in the other end in the options:
Latex-
-and then you will need to have a look at: tex.stackexchange.com/questions/176779/…– hpekristiansen
2 days ago
add a comment |
2 Answers
2
active
oldest
votes
To have arrow's head on opposition side of the spiral curve, you only need to change -Latex
to Latex-
. However result is quite unexpected (read unusable) ...
It might be more acceptable solution to move the arrow head close to the end of the spiral. For this you can exploit the package decorations.markings
:
documentclass[tikz, margin=3mm]standalone
usetikzlibraryarrows.meta, bending, decorations.markings
begindocument
begintikzpicture[
decoration = markings,mark=at position .84 with
arrowreversed[black]Latex[length=1.5mm]
]
draw[postaction=decorate]
plot[domain=0:25,variable=t,smooth,samples=101,
Latex[length=1mm]-]
(t r: 0.002*t*t);
endtikzpicture
enddocument
It would be great if you could mention that you used the position0.84
because it does not work for much smaller values of the position, e.g.... at position .14 with ...
throws adimension too large
error. In fact, any position below.34
has that problem. And then you may want to add that your proposal is, let's say, strongly inspired by tex.stackexchange.com/a/39282/121799.
– marmot
yesterday
Dear @marmot, my solution is based on example from page 639, TikZ and PGF manual, v 3.1) . I was not aware for mentioned answer, thank you for pointed me to it. Value0.84
for arrow head position I determined experimentally, according to my taste (that arrow head is approximately below origin of spiral). Your observation about positioning of harrow head is very good!
– Zarko
yesterday
add a comment |
First of all, I would like to argue that bent arrows look better, also in the original plot. But since the curve becomes singular at 0, this does not immediately work because of dimension too large
errors. However, it does once we approximate the inner-most stretch by an arc.
documentclassarticle
usepackagetikz
usetikzlibraryarrows.meta,bending
begindocument
begintikzpicture[scale=2]
pgfmathsetmacromytpi
draw[Latex[bend,length=2pt]-]
(0: 0.002*myt*myt)
arc(0:180:0.002*myt*myt);
draw plot[domain=pi:25.1327,variable=t,samples=75,smooth]
(t r: 0.002*t*t);
endtikzpicture
enddocument
And here is the original pic with a bent arrow.
documentclassarticle
usepackagetikz
usetikzlibraryarrows.meta,bending
begindocument
begintikzpicture
draw [domain=0:25.1327,variable=t,smooth,samples=75, -Latex[bend]]
plot (t r: 0.002*t*t);
endtikzpicture
enddocument
Note that one should always load bending
when one attaches arrows to curved paths, regardless of whether or not one bends the arrows, since otherwise the paths get distorted. Bending cures the distortion even when not explicitly used.
add a comment |
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%2f482341%2ftikz-how-to-reverse-arrow-direction-without-switching-start-end-point%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
To have arrow's head on opposition side of the spiral curve, you only need to change -Latex
to Latex-
. However result is quite unexpected (read unusable) ...
It might be more acceptable solution to move the arrow head close to the end of the spiral. For this you can exploit the package decorations.markings
:
documentclass[tikz, margin=3mm]standalone
usetikzlibraryarrows.meta, bending, decorations.markings
begindocument
begintikzpicture[
decoration = markings,mark=at position .84 with
arrowreversed[black]Latex[length=1.5mm]
]
draw[postaction=decorate]
plot[domain=0:25,variable=t,smooth,samples=101,
Latex[length=1mm]-]
(t r: 0.002*t*t);
endtikzpicture
enddocument
It would be great if you could mention that you used the position0.84
because it does not work for much smaller values of the position, e.g.... at position .14 with ...
throws adimension too large
error. In fact, any position below.34
has that problem. And then you may want to add that your proposal is, let's say, strongly inspired by tex.stackexchange.com/a/39282/121799.
– marmot
yesterday
Dear @marmot, my solution is based on example from page 639, TikZ and PGF manual, v 3.1) . I was not aware for mentioned answer, thank you for pointed me to it. Value0.84
for arrow head position I determined experimentally, according to my taste (that arrow head is approximately below origin of spiral). Your observation about positioning of harrow head is very good!
– Zarko
yesterday
add a comment |
To have arrow's head on opposition side of the spiral curve, you only need to change -Latex
to Latex-
. However result is quite unexpected (read unusable) ...
It might be more acceptable solution to move the arrow head close to the end of the spiral. For this you can exploit the package decorations.markings
:
documentclass[tikz, margin=3mm]standalone
usetikzlibraryarrows.meta, bending, decorations.markings
begindocument
begintikzpicture[
decoration = markings,mark=at position .84 with
arrowreversed[black]Latex[length=1.5mm]
]
draw[postaction=decorate]
plot[domain=0:25,variable=t,smooth,samples=101,
Latex[length=1mm]-]
(t r: 0.002*t*t);
endtikzpicture
enddocument
It would be great if you could mention that you used the position0.84
because it does not work for much smaller values of the position, e.g.... at position .14 with ...
throws adimension too large
error. In fact, any position below.34
has that problem. And then you may want to add that your proposal is, let's say, strongly inspired by tex.stackexchange.com/a/39282/121799.
– marmot
yesterday
Dear @marmot, my solution is based on example from page 639, TikZ and PGF manual, v 3.1) . I was not aware for mentioned answer, thank you for pointed me to it. Value0.84
for arrow head position I determined experimentally, according to my taste (that arrow head is approximately below origin of spiral). Your observation about positioning of harrow head is very good!
– Zarko
yesterday
add a comment |
To have arrow's head on opposition side of the spiral curve, you only need to change -Latex
to Latex-
. However result is quite unexpected (read unusable) ...
It might be more acceptable solution to move the arrow head close to the end of the spiral. For this you can exploit the package decorations.markings
:
documentclass[tikz, margin=3mm]standalone
usetikzlibraryarrows.meta, bending, decorations.markings
begindocument
begintikzpicture[
decoration = markings,mark=at position .84 with
arrowreversed[black]Latex[length=1.5mm]
]
draw[postaction=decorate]
plot[domain=0:25,variable=t,smooth,samples=101,
Latex[length=1mm]-]
(t r: 0.002*t*t);
endtikzpicture
enddocument
To have arrow's head on opposition side of the spiral curve, you only need to change -Latex
to Latex-
. However result is quite unexpected (read unusable) ...
It might be more acceptable solution to move the arrow head close to the end of the spiral. For this you can exploit the package decorations.markings
:
documentclass[tikz, margin=3mm]standalone
usetikzlibraryarrows.meta, bending, decorations.markings
begindocument
begintikzpicture[
decoration = markings,mark=at position .84 with
arrowreversed[black]Latex[length=1.5mm]
]
draw[postaction=decorate]
plot[domain=0:25,variable=t,smooth,samples=101,
Latex[length=1mm]-]
(t r: 0.002*t*t);
endtikzpicture
enddocument
answered 2 days ago
ZarkoZarko
128k868169
128k868169
It would be great if you could mention that you used the position0.84
because it does not work for much smaller values of the position, e.g.... at position .14 with ...
throws adimension too large
error. In fact, any position below.34
has that problem. And then you may want to add that your proposal is, let's say, strongly inspired by tex.stackexchange.com/a/39282/121799.
– marmot
yesterday
Dear @marmot, my solution is based on example from page 639, TikZ and PGF manual, v 3.1) . I was not aware for mentioned answer, thank you for pointed me to it. Value0.84
for arrow head position I determined experimentally, according to my taste (that arrow head is approximately below origin of spiral). Your observation about positioning of harrow head is very good!
– Zarko
yesterday
add a comment |
It would be great if you could mention that you used the position0.84
because it does not work for much smaller values of the position, e.g.... at position .14 with ...
throws adimension too large
error. In fact, any position below.34
has that problem. And then you may want to add that your proposal is, let's say, strongly inspired by tex.stackexchange.com/a/39282/121799.
– marmot
yesterday
Dear @marmot, my solution is based on example from page 639, TikZ and PGF manual, v 3.1) . I was not aware for mentioned answer, thank you for pointed me to it. Value0.84
for arrow head position I determined experimentally, according to my taste (that arrow head is approximately below origin of spiral). Your observation about positioning of harrow head is very good!
– Zarko
yesterday
It would be great if you could mention that you used the position
0.84
because it does not work for much smaller values of the position, e.g. ... at position .14 with ...
throws a dimension too large
error. In fact, any position below .34
has that problem. And then you may want to add that your proposal is, let's say, strongly inspired by tex.stackexchange.com/a/39282/121799.– marmot
yesterday
It would be great if you could mention that you used the position
0.84
because it does not work for much smaller values of the position, e.g. ... at position .14 with ...
throws a dimension too large
error. In fact, any position below .34
has that problem. And then you may want to add that your proposal is, let's say, strongly inspired by tex.stackexchange.com/a/39282/121799.– marmot
yesterday
Dear @marmot, my solution is based on example from page 639, TikZ and PGF manual, v 3.1) . I was not aware for mentioned answer, thank you for pointed me to it. Value
0.84
for arrow head position I determined experimentally, according to my taste (that arrow head is approximately below origin of spiral). Your observation about positioning of harrow head is very good!– Zarko
yesterday
Dear @marmot, my solution is based on example from page 639, TikZ and PGF manual, v 3.1) . I was not aware for mentioned answer, thank you for pointed me to it. Value
0.84
for arrow head position I determined experimentally, according to my taste (that arrow head is approximately below origin of spiral). Your observation about positioning of harrow head is very good!– Zarko
yesterday
add a comment |
First of all, I would like to argue that bent arrows look better, also in the original plot. But since the curve becomes singular at 0, this does not immediately work because of dimension too large
errors. However, it does once we approximate the inner-most stretch by an arc.
documentclassarticle
usepackagetikz
usetikzlibraryarrows.meta,bending
begindocument
begintikzpicture[scale=2]
pgfmathsetmacromytpi
draw[Latex[bend,length=2pt]-]
(0: 0.002*myt*myt)
arc(0:180:0.002*myt*myt);
draw plot[domain=pi:25.1327,variable=t,samples=75,smooth]
(t r: 0.002*t*t);
endtikzpicture
enddocument
And here is the original pic with a bent arrow.
documentclassarticle
usepackagetikz
usetikzlibraryarrows.meta,bending
begindocument
begintikzpicture
draw [domain=0:25.1327,variable=t,smooth,samples=75, -Latex[bend]]
plot (t r: 0.002*t*t);
endtikzpicture
enddocument
Note that one should always load bending
when one attaches arrows to curved paths, regardless of whether or not one bends the arrows, since otherwise the paths get distorted. Bending cures the distortion even when not explicitly used.
add a comment |
First of all, I would like to argue that bent arrows look better, also in the original plot. But since the curve becomes singular at 0, this does not immediately work because of dimension too large
errors. However, it does once we approximate the inner-most stretch by an arc.
documentclassarticle
usepackagetikz
usetikzlibraryarrows.meta,bending
begindocument
begintikzpicture[scale=2]
pgfmathsetmacromytpi
draw[Latex[bend,length=2pt]-]
(0: 0.002*myt*myt)
arc(0:180:0.002*myt*myt);
draw plot[domain=pi:25.1327,variable=t,samples=75,smooth]
(t r: 0.002*t*t);
endtikzpicture
enddocument
And here is the original pic with a bent arrow.
documentclassarticle
usepackagetikz
usetikzlibraryarrows.meta,bending
begindocument
begintikzpicture
draw [domain=0:25.1327,variable=t,smooth,samples=75, -Latex[bend]]
plot (t r: 0.002*t*t);
endtikzpicture
enddocument
Note that one should always load bending
when one attaches arrows to curved paths, regardless of whether or not one bends the arrows, since otherwise the paths get distorted. Bending cures the distortion even when not explicitly used.
add a comment |
First of all, I would like to argue that bent arrows look better, also in the original plot. But since the curve becomes singular at 0, this does not immediately work because of dimension too large
errors. However, it does once we approximate the inner-most stretch by an arc.
documentclassarticle
usepackagetikz
usetikzlibraryarrows.meta,bending
begindocument
begintikzpicture[scale=2]
pgfmathsetmacromytpi
draw[Latex[bend,length=2pt]-]
(0: 0.002*myt*myt)
arc(0:180:0.002*myt*myt);
draw plot[domain=pi:25.1327,variable=t,samples=75,smooth]
(t r: 0.002*t*t);
endtikzpicture
enddocument
And here is the original pic with a bent arrow.
documentclassarticle
usepackagetikz
usetikzlibraryarrows.meta,bending
begindocument
begintikzpicture
draw [domain=0:25.1327,variable=t,smooth,samples=75, -Latex[bend]]
plot (t r: 0.002*t*t);
endtikzpicture
enddocument
Note that one should always load bending
when one attaches arrows to curved paths, regardless of whether or not one bends the arrows, since otherwise the paths get distorted. Bending cures the distortion even when not explicitly used.
First of all, I would like to argue that bent arrows look better, also in the original plot. But since the curve becomes singular at 0, this does not immediately work because of dimension too large
errors. However, it does once we approximate the inner-most stretch by an arc.
documentclassarticle
usepackagetikz
usetikzlibraryarrows.meta,bending
begindocument
begintikzpicture[scale=2]
pgfmathsetmacromytpi
draw[Latex[bend,length=2pt]-]
(0: 0.002*myt*myt)
arc(0:180:0.002*myt*myt);
draw plot[domain=pi:25.1327,variable=t,samples=75,smooth]
(t r: 0.002*t*t);
endtikzpicture
enddocument
And here is the original pic with a bent arrow.
documentclassarticle
usepackagetikz
usetikzlibraryarrows.meta,bending
begindocument
begintikzpicture
draw [domain=0:25.1327,variable=t,smooth,samples=75, -Latex[bend]]
plot (t r: 0.002*t*t);
endtikzpicture
enddocument
Note that one should always load bending
when one attaches arrows to curved paths, regardless of whether or not one bends the arrows, since otherwise the paths get distorted. Bending cures the distortion even when not explicitly used.
answered yesterday
marmotmarmot
113k5145275
113k5145275
add a comment |
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%2f482341%2ftikz-how-to-reverse-arrow-direction-without-switching-start-end-point%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
instead
-Latex
useLatex-
? however, the result be ugly ....– Zarko
2 days ago
You just place the arrow in the other end in the options:
Latex-
-and then you will need to have a look at: tex.stackexchange.com/questions/176779/…– hpekristiansen
2 days ago