Coordinate position not precise












3















documentclass{standalone}
usepackage{tikz}
usetikzlibrary{calc,intersections}
usepackage{amsmath}

begin{document}

begin{tikzpicture}[scale=0.5]
draw[<->] (0,12) node[above]{$w$} |- (12,0) node[right]{$q_L$};

draw[dotted, name path = ACL] (0,0) plot [domain=0.7:9] (x,0.75*x + 0.8) node[label=right:{AC$_L$ = S$_L$}](A1){};
coordinate (H) at ($({5.6/0.75},5.6) - ({0.8/0.75},0)$);
draw[thick, blue, name path = ACLt] let p1 = (H) in (0,y1) node[left, red]{$w_u$} -- (x1,y1) --(A1);
end{tikzpicture}

end{document}


My problem is as follows:




  • I have attempted to define a coordinate (A1) at the end of the first line (name path ACL).

  • I then use this coordinate (A1) as the last coordinate in the second line (name path ACLt).


It seems that the coordinate is not truly at the end of the line, since the dotted line is extending slightly beyond the thick blue line:



enter image description here



Why is this occurring?










share|improve this question


















  • 1





    Node's have finite size and you can simply say draw[thick, blue, name path = ACLt] (0,0|-H)-- (H) --(A1); which will work fine when A1 is a coordinate.

    – marmot
    14 hours ago
















3















documentclass{standalone}
usepackage{tikz}
usetikzlibrary{calc,intersections}
usepackage{amsmath}

begin{document}

begin{tikzpicture}[scale=0.5]
draw[<->] (0,12) node[above]{$w$} |- (12,0) node[right]{$q_L$};

draw[dotted, name path = ACL] (0,0) plot [domain=0.7:9] (x,0.75*x + 0.8) node[label=right:{AC$_L$ = S$_L$}](A1){};
coordinate (H) at ($({5.6/0.75},5.6) - ({0.8/0.75},0)$);
draw[thick, blue, name path = ACLt] let p1 = (H) in (0,y1) node[left, red]{$w_u$} -- (x1,y1) --(A1);
end{tikzpicture}

end{document}


My problem is as follows:




  • I have attempted to define a coordinate (A1) at the end of the first line (name path ACL).

  • I then use this coordinate (A1) as the last coordinate in the second line (name path ACLt).


It seems that the coordinate is not truly at the end of the line, since the dotted line is extending slightly beyond the thick blue line:



enter image description here



Why is this occurring?










share|improve this question


















  • 1





    Node's have finite size and you can simply say draw[thick, blue, name path = ACLt] (0,0|-H)-- (H) --(A1); which will work fine when A1 is a coordinate.

    – marmot
    14 hours ago














3












3








3








documentclass{standalone}
usepackage{tikz}
usetikzlibrary{calc,intersections}
usepackage{amsmath}

begin{document}

begin{tikzpicture}[scale=0.5]
draw[<->] (0,12) node[above]{$w$} |- (12,0) node[right]{$q_L$};

draw[dotted, name path = ACL] (0,0) plot [domain=0.7:9] (x,0.75*x + 0.8) node[label=right:{AC$_L$ = S$_L$}](A1){};
coordinate (H) at ($({5.6/0.75},5.6) - ({0.8/0.75},0)$);
draw[thick, blue, name path = ACLt] let p1 = (H) in (0,y1) node[left, red]{$w_u$} -- (x1,y1) --(A1);
end{tikzpicture}

end{document}


My problem is as follows:




  • I have attempted to define a coordinate (A1) at the end of the first line (name path ACL).

  • I then use this coordinate (A1) as the last coordinate in the second line (name path ACLt).


It seems that the coordinate is not truly at the end of the line, since the dotted line is extending slightly beyond the thick blue line:



enter image description here



Why is this occurring?










share|improve this question














documentclass{standalone}
usepackage{tikz}
usetikzlibrary{calc,intersections}
usepackage{amsmath}

begin{document}

begin{tikzpicture}[scale=0.5]
draw[<->] (0,12) node[above]{$w$} |- (12,0) node[right]{$q_L$};

draw[dotted, name path = ACL] (0,0) plot [domain=0.7:9] (x,0.75*x + 0.8) node[label=right:{AC$_L$ = S$_L$}](A1){};
coordinate (H) at ($({5.6/0.75},5.6) - ({0.8/0.75},0)$);
draw[thick, blue, name path = ACLt] let p1 = (H) in (0,y1) node[left, red]{$w_u$} -- (x1,y1) --(A1);
end{tikzpicture}

end{document}


My problem is as follows:




  • I have attempted to define a coordinate (A1) at the end of the first line (name path ACL).

  • I then use this coordinate (A1) as the last coordinate in the second line (name path ACLt).


It seems that the coordinate is not truly at the end of the line, since the dotted line is extending slightly beyond the thick blue line:



enter image description here



Why is this occurring?







tikz-pgf coordinates






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked 14 hours ago









Thevesh ThevaThevesh Theva

524114




524114








  • 1





    Node's have finite size and you can simply say draw[thick, blue, name path = ACLt] (0,0|-H)-- (H) --(A1); which will work fine when A1 is a coordinate.

    – marmot
    14 hours ago














  • 1





    Node's have finite size and you can simply say draw[thick, blue, name path = ACLt] (0,0|-H)-- (H) --(A1); which will work fine when A1 is a coordinate.

    – marmot
    14 hours ago








1




1





Node's have finite size and you can simply say draw[thick, blue, name path = ACLt] (0,0|-H)-- (H) --(A1); which will work fine when A1 is a coordinate.

– marmot
14 hours ago





Node's have finite size and you can simply say draw[thick, blue, name path = ACLt] (0,0|-H)-- (H) --(A1); which will work fine when A1 is a coordinate.

– marmot
14 hours ago










2 Answers
2






active

oldest

votes


















5














Well, Zarko has turned my comment into "his" answer, but here it is again: use coordinate instead of node because the latter has a finite size (by default). And my answer and comment come with an arguably simpler construction of the path.



documentclass{standalone}
usepackage{tikz}
usetikzlibrary{calc,intersections}
usepackage{amsmath}

begin{document}

begin{tikzpicture}[scale=0.5]
draw[<->] (0,12) node[above]{$w$} |- (12,0) node[right]{$q_L$};

draw[dotted, name path = ACL] (0,0) plot [domain=0.7:9] (x,0.75*x + 0.8)
coordinate[label=right:{AC$_L$ = S$_L$}] (A1);
coordinate (H) at ($({5.6/0.75},5.6) - ({0.8/0.75},0)$);
draw[thick, blue, name path = ACLt] (0,0|-H) node[left, red]{$w_u$} -- (H) --(A1);
end{tikzpicture}

end{document}


enter image description here






share|improve this answer



















  • 1





    Upvoted both answers; accepted yours because your comment was sufficient for me to solve my problem before I saw either answer (I hadn't realised that nodes had a finite size even when I left the label empty). Thanks!

    – Thevesh Theva
    13 hours ago








  • 3





    I think that Zarko do not need your comment to see the difference between node and coordinate. TeX.SX is not a competition site "who will answer first" and we are not here to claim paternity of "greate" ideas, but just to help, IMHO.

    – Kpym
    12 hours ago











  • @Kpym This is IMHO not the question. The question is whether or not one should acknowledge an earlier post saying the same thing. If you acknowledge this, it does not mean you didn't know that. It is just fair play.

    – marmot
    11 hours ago



















8














calculation of coordinate is sufficient accurate, problem is that for it you use node, replace node with coordinate and result will become as you wish:



enter image description here



documentclass{standalone}
usepackage{tikz}
usetikzlibrary{calc,intersections}
usepackage{amsmath}

begin{document}

begin{tikzpicture}[scale=0.5]
draw[<->] (0,12) node[above]{$w$} |- (12,0) node[right]{$q_L$};

draw[dotted, name path = ACL]
plot [domain=0.7:9] (x,0.75*x + 0.8) coordinate[label=right:{AC$_L$ = S$_L$}] (A1);
coordinate (H) at ($({5.6/0.75},5.6) - ({0.8/0.75},0)$);
draw[thick, blue, name path = ACLt] let p1 = (H) in (0,y1) node[left, red]{$w_u$} -- (x1,y1) --(A1);
end{tikzpicture}

end{document}


difference between node and coordinate arise since node has some width regardless if it is empty. it is determined by default value of inner sep. if you set it to zero: inner sep=0pt the result will be the same.



off-topic: in your diagram you not use intersections library, so you can remove line names from code (as i do in aboveo mwe)






share|improve this answer

























    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
    });


    }
    });














    draft saved

    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f481586%2fcoordinate-position-not-precise%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









    5














    Well, Zarko has turned my comment into "his" answer, but here it is again: use coordinate instead of node because the latter has a finite size (by default). And my answer and comment come with an arguably simpler construction of the path.



    documentclass{standalone}
    usepackage{tikz}
    usetikzlibrary{calc,intersections}
    usepackage{amsmath}

    begin{document}

    begin{tikzpicture}[scale=0.5]
    draw[<->] (0,12) node[above]{$w$} |- (12,0) node[right]{$q_L$};

    draw[dotted, name path = ACL] (0,0) plot [domain=0.7:9] (x,0.75*x + 0.8)
    coordinate[label=right:{AC$_L$ = S$_L$}] (A1);
    coordinate (H) at ($({5.6/0.75},5.6) - ({0.8/0.75},0)$);
    draw[thick, blue, name path = ACLt] (0,0|-H) node[left, red]{$w_u$} -- (H) --(A1);
    end{tikzpicture}

    end{document}


    enter image description here






    share|improve this answer



















    • 1





      Upvoted both answers; accepted yours because your comment was sufficient for me to solve my problem before I saw either answer (I hadn't realised that nodes had a finite size even when I left the label empty). Thanks!

      – Thevesh Theva
      13 hours ago








    • 3





      I think that Zarko do not need your comment to see the difference between node and coordinate. TeX.SX is not a competition site "who will answer first" and we are not here to claim paternity of "greate" ideas, but just to help, IMHO.

      – Kpym
      12 hours ago











    • @Kpym This is IMHO not the question. The question is whether or not one should acknowledge an earlier post saying the same thing. If you acknowledge this, it does not mean you didn't know that. It is just fair play.

      – marmot
      11 hours ago
















    5














    Well, Zarko has turned my comment into "his" answer, but here it is again: use coordinate instead of node because the latter has a finite size (by default). And my answer and comment come with an arguably simpler construction of the path.



    documentclass{standalone}
    usepackage{tikz}
    usetikzlibrary{calc,intersections}
    usepackage{amsmath}

    begin{document}

    begin{tikzpicture}[scale=0.5]
    draw[<->] (0,12) node[above]{$w$} |- (12,0) node[right]{$q_L$};

    draw[dotted, name path = ACL] (0,0) plot [domain=0.7:9] (x,0.75*x + 0.8)
    coordinate[label=right:{AC$_L$ = S$_L$}] (A1);
    coordinate (H) at ($({5.6/0.75},5.6) - ({0.8/0.75},0)$);
    draw[thick, blue, name path = ACLt] (0,0|-H) node[left, red]{$w_u$} -- (H) --(A1);
    end{tikzpicture}

    end{document}


    enter image description here






    share|improve this answer



















    • 1





      Upvoted both answers; accepted yours because your comment was sufficient for me to solve my problem before I saw either answer (I hadn't realised that nodes had a finite size even when I left the label empty). Thanks!

      – Thevesh Theva
      13 hours ago








    • 3





      I think that Zarko do not need your comment to see the difference between node and coordinate. TeX.SX is not a competition site "who will answer first" and we are not here to claim paternity of "greate" ideas, but just to help, IMHO.

      – Kpym
      12 hours ago











    • @Kpym This is IMHO not the question. The question is whether or not one should acknowledge an earlier post saying the same thing. If you acknowledge this, it does not mean you didn't know that. It is just fair play.

      – marmot
      11 hours ago














    5












    5








    5







    Well, Zarko has turned my comment into "his" answer, but here it is again: use coordinate instead of node because the latter has a finite size (by default). And my answer and comment come with an arguably simpler construction of the path.



    documentclass{standalone}
    usepackage{tikz}
    usetikzlibrary{calc,intersections}
    usepackage{amsmath}

    begin{document}

    begin{tikzpicture}[scale=0.5]
    draw[<->] (0,12) node[above]{$w$} |- (12,0) node[right]{$q_L$};

    draw[dotted, name path = ACL] (0,0) plot [domain=0.7:9] (x,0.75*x + 0.8)
    coordinate[label=right:{AC$_L$ = S$_L$}] (A1);
    coordinate (H) at ($({5.6/0.75},5.6) - ({0.8/0.75},0)$);
    draw[thick, blue, name path = ACLt] (0,0|-H) node[left, red]{$w_u$} -- (H) --(A1);
    end{tikzpicture}

    end{document}


    enter image description here






    share|improve this answer













    Well, Zarko has turned my comment into "his" answer, but here it is again: use coordinate instead of node because the latter has a finite size (by default). And my answer and comment come with an arguably simpler construction of the path.



    documentclass{standalone}
    usepackage{tikz}
    usetikzlibrary{calc,intersections}
    usepackage{amsmath}

    begin{document}

    begin{tikzpicture}[scale=0.5]
    draw[<->] (0,12) node[above]{$w$} |- (12,0) node[right]{$q_L$};

    draw[dotted, name path = ACL] (0,0) plot [domain=0.7:9] (x,0.75*x + 0.8)
    coordinate[label=right:{AC$_L$ = S$_L$}] (A1);
    coordinate (H) at ($({5.6/0.75},5.6) - ({0.8/0.75},0)$);
    draw[thick, blue, name path = ACLt] (0,0|-H) node[left, red]{$w_u$} -- (H) --(A1);
    end{tikzpicture}

    end{document}


    enter image description here







    share|improve this answer












    share|improve this answer



    share|improve this answer










    answered 13 hours ago









    marmotmarmot

    112k5141267




    112k5141267








    • 1





      Upvoted both answers; accepted yours because your comment was sufficient for me to solve my problem before I saw either answer (I hadn't realised that nodes had a finite size even when I left the label empty). Thanks!

      – Thevesh Theva
      13 hours ago








    • 3





      I think that Zarko do not need your comment to see the difference between node and coordinate. TeX.SX is not a competition site "who will answer first" and we are not here to claim paternity of "greate" ideas, but just to help, IMHO.

      – Kpym
      12 hours ago











    • @Kpym This is IMHO not the question. The question is whether or not one should acknowledge an earlier post saying the same thing. If you acknowledge this, it does not mean you didn't know that. It is just fair play.

      – marmot
      11 hours ago














    • 1





      Upvoted both answers; accepted yours because your comment was sufficient for me to solve my problem before I saw either answer (I hadn't realised that nodes had a finite size even when I left the label empty). Thanks!

      – Thevesh Theva
      13 hours ago








    • 3





      I think that Zarko do not need your comment to see the difference between node and coordinate. TeX.SX is not a competition site "who will answer first" and we are not here to claim paternity of "greate" ideas, but just to help, IMHO.

      – Kpym
      12 hours ago











    • @Kpym This is IMHO not the question. The question is whether or not one should acknowledge an earlier post saying the same thing. If you acknowledge this, it does not mean you didn't know that. It is just fair play.

      – marmot
      11 hours ago








    1




    1





    Upvoted both answers; accepted yours because your comment was sufficient for me to solve my problem before I saw either answer (I hadn't realised that nodes had a finite size even when I left the label empty). Thanks!

    – Thevesh Theva
    13 hours ago







    Upvoted both answers; accepted yours because your comment was sufficient for me to solve my problem before I saw either answer (I hadn't realised that nodes had a finite size even when I left the label empty). Thanks!

    – Thevesh Theva
    13 hours ago






    3




    3





    I think that Zarko do not need your comment to see the difference between node and coordinate. TeX.SX is not a competition site "who will answer first" and we are not here to claim paternity of "greate" ideas, but just to help, IMHO.

    – Kpym
    12 hours ago





    I think that Zarko do not need your comment to see the difference between node and coordinate. TeX.SX is not a competition site "who will answer first" and we are not here to claim paternity of "greate" ideas, but just to help, IMHO.

    – Kpym
    12 hours ago













    @Kpym This is IMHO not the question. The question is whether or not one should acknowledge an earlier post saying the same thing. If you acknowledge this, it does not mean you didn't know that. It is just fair play.

    – marmot
    11 hours ago





    @Kpym This is IMHO not the question. The question is whether or not one should acknowledge an earlier post saying the same thing. If you acknowledge this, it does not mean you didn't know that. It is just fair play.

    – marmot
    11 hours ago











    8














    calculation of coordinate is sufficient accurate, problem is that for it you use node, replace node with coordinate and result will become as you wish:



    enter image description here



    documentclass{standalone}
    usepackage{tikz}
    usetikzlibrary{calc,intersections}
    usepackage{amsmath}

    begin{document}

    begin{tikzpicture}[scale=0.5]
    draw[<->] (0,12) node[above]{$w$} |- (12,0) node[right]{$q_L$};

    draw[dotted, name path = ACL]
    plot [domain=0.7:9] (x,0.75*x + 0.8) coordinate[label=right:{AC$_L$ = S$_L$}] (A1);
    coordinate (H) at ($({5.6/0.75},5.6) - ({0.8/0.75},0)$);
    draw[thick, blue, name path = ACLt] let p1 = (H) in (0,y1) node[left, red]{$w_u$} -- (x1,y1) --(A1);
    end{tikzpicture}

    end{document}


    difference between node and coordinate arise since node has some width regardless if it is empty. it is determined by default value of inner sep. if you set it to zero: inner sep=0pt the result will be the same.



    off-topic: in your diagram you not use intersections library, so you can remove line names from code (as i do in aboveo mwe)






    share|improve this answer






























      8














      calculation of coordinate is sufficient accurate, problem is that for it you use node, replace node with coordinate and result will become as you wish:



      enter image description here



      documentclass{standalone}
      usepackage{tikz}
      usetikzlibrary{calc,intersections}
      usepackage{amsmath}

      begin{document}

      begin{tikzpicture}[scale=0.5]
      draw[<->] (0,12) node[above]{$w$} |- (12,0) node[right]{$q_L$};

      draw[dotted, name path = ACL]
      plot [domain=0.7:9] (x,0.75*x + 0.8) coordinate[label=right:{AC$_L$ = S$_L$}] (A1);
      coordinate (H) at ($({5.6/0.75},5.6) - ({0.8/0.75},0)$);
      draw[thick, blue, name path = ACLt] let p1 = (H) in (0,y1) node[left, red]{$w_u$} -- (x1,y1) --(A1);
      end{tikzpicture}

      end{document}


      difference between node and coordinate arise since node has some width regardless if it is empty. it is determined by default value of inner sep. if you set it to zero: inner sep=0pt the result will be the same.



      off-topic: in your diagram you not use intersections library, so you can remove line names from code (as i do in aboveo mwe)






      share|improve this answer




























        8












        8








        8







        calculation of coordinate is sufficient accurate, problem is that for it you use node, replace node with coordinate and result will become as you wish:



        enter image description here



        documentclass{standalone}
        usepackage{tikz}
        usetikzlibrary{calc,intersections}
        usepackage{amsmath}

        begin{document}

        begin{tikzpicture}[scale=0.5]
        draw[<->] (0,12) node[above]{$w$} |- (12,0) node[right]{$q_L$};

        draw[dotted, name path = ACL]
        plot [domain=0.7:9] (x,0.75*x + 0.8) coordinate[label=right:{AC$_L$ = S$_L$}] (A1);
        coordinate (H) at ($({5.6/0.75},5.6) - ({0.8/0.75},0)$);
        draw[thick, blue, name path = ACLt] let p1 = (H) in (0,y1) node[left, red]{$w_u$} -- (x1,y1) --(A1);
        end{tikzpicture}

        end{document}


        difference between node and coordinate arise since node has some width regardless if it is empty. it is determined by default value of inner sep. if you set it to zero: inner sep=0pt the result will be the same.



        off-topic: in your diagram you not use intersections library, so you can remove line names from code (as i do in aboveo mwe)






        share|improve this answer















        calculation of coordinate is sufficient accurate, problem is that for it you use node, replace node with coordinate and result will become as you wish:



        enter image description here



        documentclass{standalone}
        usepackage{tikz}
        usetikzlibrary{calc,intersections}
        usepackage{amsmath}

        begin{document}

        begin{tikzpicture}[scale=0.5]
        draw[<->] (0,12) node[above]{$w$} |- (12,0) node[right]{$q_L$};

        draw[dotted, name path = ACL]
        plot [domain=0.7:9] (x,0.75*x + 0.8) coordinate[label=right:{AC$_L$ = S$_L$}] (A1);
        coordinate (H) at ($({5.6/0.75},5.6) - ({0.8/0.75},0)$);
        draw[thick, blue, name path = ACLt] let p1 = (H) in (0,y1) node[left, red]{$w_u$} -- (x1,y1) --(A1);
        end{tikzpicture}

        end{document}


        difference between node and coordinate arise since node has some width regardless if it is empty. it is determined by default value of inner sep. if you set it to zero: inner sep=0pt the result will be the same.



        off-topic: in your diagram you not use intersections library, so you can remove line names from code (as i do in aboveo mwe)







        share|improve this answer














        share|improve this answer



        share|improve this answer








        edited 13 hours ago

























        answered 14 hours ago









        ZarkoZarko

        128k868167




        128k868167






























            draft saved

            draft discarded




















































            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.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f481586%2fcoordinate-position-not-precise%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

            He _____ here since 1970 . Answer needed [closed]What does “since he was so high” mean?Meaning of “catch birds for”?How do I ensure “since” takes the meaning I want?“Who cares here” meaningWhat does “right round toward” mean?the time tense (had now been detected)What does the phrase “ring around the roses” mean here?Correct usage of “visited upon”Meaning of “foiled rail sabotage bid”It was the third time I had gone to Rome or It is the third time I had been to Rome

            Bunad

            Færeyskur hestur Heimild | Tengill | Tilvísanir | LeiðsagnarvalRossið - síða um færeyska hrossið á færeyskuGott ár hjá færeyska hestinum